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)
-   -   Hide left col on home, checkout, and cart (https://forum.x-cart.com/showthread.php?t=67270)

taponitrof 07-03-2013 03:38 PM

Hide left col on home, checkout, and cart
 
I'm using the xcart two column template and I want to hide the column on the home page x-cart 4.4. The code in template already hides that column on checkout and cart page.
Here is the original code that hides <div id="left-bar"> on checkout and cart page:

Code:

{if ($main neq 'cart' or $cart_empty) and $main neq 'checkout'}

Here's the code I tried but it doesn't work. I've tried many variation of this but nothing works.

Code:

{if ($main neq 'catalog' or $current_category.category neq "") or $main neq 'checkout' and ($main neq 'cart' or $cart_empty) }

Any ideas.

Thanks

philrisk 07-05-2013 06:27 AM

Re: Hide left col on home, checkout, and cart
 
Wrap {if ($main neq 'cart' or $cart_empty) and $main neq 'checkout'} round your left bar div and also you will have to modify the centre section to remove the left margin from the page.

taponitrof 07-05-2013 11:34 AM

Re: Hide left col on home, checkout, and cart
 
Thanks for the reply. I figured out how to do it. If I read your message right, you suggest the same way
Anyway, code below works.

{if ($main neq 'cart' or $cart_empty) and $main neq 'checkout'}
{if $main neq 'catalog' or $current_category.category neq ""}
<div id="left-bar">
{include file="customer/left_bar.tpl"}
</div>
{/if}
{/if}

cherie 07-05-2013 05:06 PM

Re: Hide left col on home, checkout, and cart
 
Or:

{if ($main neq "cart" or $cart_empty) and $main neq "checkout" and ($main neq "catalog" or $current_category.category neq "")}

Or better:

{if ($main neq "cart" or $cart_empty) and $main neq "checkout" and not ($main eq "catalog" and $current_category.category eq "")}


All times are GMT -8. The time now is 08:17 AM.

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