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)
-   -   No right bar when Product Details are shown (https://forum.x-cart.com/showthread.php?t=65132)

ManuelaT 10-16-2012 06:50 AM

No right bar when Product Details are shown
 
Hello everyone,

I hope this great community is able to help me.

I am trying to accomplish the following:

If the product details page is shown, then the right bar should be "turned off".
Otherwise the right bar should be included.

is there anyone, who can help me how to do that?

XCart 4.5.0

thanks a lot in advance!

Manuela

PhilJ 10-16-2012 07:27 AM

Re: No right bar when Product Details are shown
 
Smarty logic is...

Quote:

{if $main ne "product"}
{include file="customer/right_bar.tpl"}
{/if}

ManuelaT 10-16-2012 07:33 AM

Re: No right bar when Product Details are shown
 
Hello PhilJ,

thanks a lot for your answer.

I already tried:

{if $main ne 'product'}
<div id="right-bar">
{include file="customer/right_bar.tpl"}
</div>
{/if}

- when added this way I get no bar , but also no other content. Only a white "box" in the middle"..

Did I do anything wrong in those few lines?

Thanks a lot!

Best wishes

Manuela

PhilJ 10-16-2012 07:36 AM

Re: No right bar when Product Details are shown
 
It depends which skin you're using...

ManuelaT 10-16-2012 07:37 AM

Re: No right bar when Product Details are shown
 
My skin is a modified ideal_comfort

PhilJ 10-16-2012 07:44 AM

Re: No right bar when Product Details are shown
 
Attach your skin/ideal_comfort/customer/content.tpl file.

According to my files for that skin, there is no right_bar.tpl

You're going to have to update the CSS in altskin.css, or possibly put in some inline CSS to compensate, due to the way QT have coded the columns.

ManuelaT 10-16-2012 07:48 AM

Re: No right bar when Product Details are shown
 
1 Attachment(s)
that is correct - I manualy added one.
That's why I said "modified".

I works as long as I put both into the same if clause (the one for right bar).
Like this:

PHP Code:

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


But it won't work the way, as shown on this content.tpl

PhilJ 10-16-2012 07:54 AM

Re: No right bar when Product Details are shown
 
You could try adding, before the closing {/if} in your newly added code...

Quote:

{literal}
<style type="text/css">
#center-main { margin: 0 -270px 0 0; }
</style>
{/literal}

Or something along those lines... Hard to judge without knowing the URL.

JacksmithxD 10-18-2012 02:29 PM

Re: No right bar when Product Details are shown
 
[Edit]

ManuelaT 10-18-2012 11:06 PM

Re: No right bar when Product Details are shown
 
Worked like a charm!

Thanks for your help, PhilJ! :-)

Best wishes

Manuela


All times are GMT -8. The time now is 10:09 PM.

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