X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Template mod (https://forum.x-cart.com/showthread.php?t=34211)

jwilkers 09-27-2007 11:01 AM

Template mod
 
Hello,

Just want some input from xcarters:

for my registration area I've changed the line in register.php

func_display("customer/home.tpl",$smarty)

to:

func_display("customer/register.tpl",$smarty)

for a new "register.tpl" I created in order to customize the look, and to lose the left menu portion of the page. Worked fine, haven't noticed any problem.

WHAT I"M really wondering is, now I'm considering it for product.php as well, in order to customize the product page, lose the left menu and create a better layuout. Is this a good idea, or ok to do for the most part?

Input appreciated.

JW

jwilkers 09-27-2007 01:05 PM

Re: Template mod
 
anyone?

jwilkers 09-27-2007 01:09 PM

Re: Template mod
 
oh, and here is the site: http://www.thehomeloft.com

jwilkers 09-28-2007 12:33 PM

Re: Template mod
 
Is anyone aware of any threads about this?

balinor 09-28-2007 01:10 PM

Re: Template mod
 
Why not just use an {if} statement around the left menu to hide if for certain areas?

jwilkers 09-28-2007 01:18 PM

Re: Template mod
 
ok, I may be able to figure out the syntax for that

think there is anything bad about the way I was thinking of doing it? or just that I may be doing too much work?!!

thanks for your input

balinor 09-28-2007 03:55 PM

Re: Template mod
 
The {if} statement is MUCH easier, and it is always better to edit the templates than mess with the PHP :)

To hide the left column for the product detail page, you would use this:

{if $main ne "product"}
column code here
{/if}

You can use multiple {if} statements to hide it from different pages...for example, if you want to also hide it from the cart:

{if $main ne "cart" and $main ne "product"}
column code
{/if}

jwilkers 10-03-2007 05:54 PM

Re: Template mod
 
what do I put in the "column code" portion of that statement, just the template I want to eliminate, or do I surround the code for that column with the if statement you've showed me?

thanks!

balinor 10-03-2007 05:56 PM

Re: Template mod
 
You put the code you want to be affected by the if statement in that area. So for the first example, the code in the statement would be hidden on the product page, but visible on all other pages. So you would put the whole table cell of the left column if you want to hide the left column.

jwilkers 10-03-2007 05:58 PM

Re: Template mod
 
answered my own question by testing it out surrounding the <TD>...works great, I luuuuuv it. Thank you so much!


All times are GMT -8. The time now is 01:14 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.