Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

How about an alternative home.php for integrating xCart/non-xCart?

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 10-17-2006, 08:59 PM
 
fogelka fogelka is offline
 

Advanced Member
  
Join Date: Jun 2006
Posts: 83
 

Default How about an alternative home.php for integrating xCart/non-xCart?

I've been taking bits and pieces from different threads, and creating what seems almost like a Frankenstein monster. Now, I have run into a wall, and can't finish. So far...

Within home.tpl, I have succeeded in eliminating all xCart content below the header, and inserting a "entry.tpl" home page there. This is by placing this before the tables in home.tpl :

{if $main eq "catalog" and $current_category.category eq ""}
{include file="entry.tpl"}
{else}

I have moved and re-formatted the authbox into the header, so I still have an active page for logging in, etc. I also have pulldowns in the header, which link to the xCart categories. That works great.

Here's where I'm stuck. I cannot find a way to bring other non-xCart pages into home.tpl to replace "entry.tpl", while keeping the active header, and no xCart stuff below. I've tried $menu ideas, and several other things. Is there a way to have an alternative home.tpl or create an "entry.php" that I can use as a non-xcart alternative to home.php? I thought I could set $main there, as, say, $smarty assign->("main", "content"), and go from there.

Please help, if you can! (I've been on this for days on end.) Thanks!
__________________
xcart v4.0.18 [linux]

Loyalty Points, DSEFU, Easy Checkout, Featured Product Manager, Remember Me, Relevant Search, Vertical Flyouts, Multiple Category Templates. Loads of other tweaks and mods learned in forums.
Reply With Quote
  #2  
Old 10-17-2006, 10:18 PM
  Jon's Avatar 
Jon Jon is offline
 

X-Guru
  
Join Date: Oct 2002
Location: Vancouver, Canada
Posts: 4,200
 

Default Re: How about an alternative home.php for integrating xCart/non-xCart?

You can create an entry page using index.php. Create a new index.php with this content:

Code:
<?php require "./auth.php"; func_display("customer/entry.tpl",$smarty); ?>

Then create a skin1/customer/entry.tpl file and put whatever you want in it.
Reply With Quote
  #3  
Old 10-18-2006, 09:45 PM
 
fogelka fogelka is offline
 

Advanced Member
  
Join Date: Jun 2006
Posts: 83
 

Default Re: How about an alternative home.php for integrating xCart/non-xCart?

Thanks again, Jon. With your help I was able to get the non-xCart page integrated correctly.

In doing so, I also finally realized what I needed to do to pull all the other non-cart pages in. I simply created a new "index.php" , a new "index.tpl", and a new "index_main.tpl". Then, I used them just like the home.php, home.tpl, and home_main.tpl for xCart. Only this way, I could have whatever formats, content, etc. I wanted in the main section, and no xCart stuff. Everything links back and forth seamlessly.

The nice thing is that the entire site is tied together very nicely by the similar (though different) header, which is active in both sides of the site. I have the "authbox" reformatted and re-laid out, and pulled into the header, along with pulldowns for the categories. That way, throughout all of the xCart and non-xCart pages, there is a consistent log-in/log-out, plus you can jump to a product at any time.

I'm nearly home now! Thanks again.
__________________
xcart v4.0.18 [linux]

Loyalty Points, DSEFU, Easy Checkout, Featured Product Manager, Remember Me, Relevant Search, Vertical Flyouts, Multiple Category Templates. Loads of other tweaks and mods learned in forums.
Reply With Quote
  #4  
Old 10-19-2006, 06:24 AM
  Jon's Avatar 
Jon Jon is offline
 

X-Guru
  
Join Date: Oct 2002
Location: Vancouver, Canada
Posts: 4,200
 

Default Re: How about an alternative home.php for integrating xCart/non-xCart?

Glad to hear
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 03:36 PM.

   

 
X-Cart forums © 2001-2020