| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
help changing navigation tabs based on current page | |||
|
|
Thread Tools | Search this Thread |
#1
|
|||||||
|
|||||||
help changing navigation tabs based on current page
Hello,
I need some help with my navigation tabs. They can be seen here: http://toybuyandsell.com/store/customer/home.php Basically, I want them to change based on what page the user is on. If they click the home page, the "home" tab will be selected. I was able to make this happen for the home, buy and help tabs by using the following if statements: Code:
A simple if statement will provide the results of a "main" section but I haven't found out how to make it happen for a section under main. Example...contactus is under help. I've tried the following but it doesn't work: Code:
Can anyone help? I think it's just a smarty command that I don't know of.
__________________
~zilker uummm...perhaps you should tell me again. http://www.designertrends.com Version 4.0.6 Unix |
|||||||
#2
|
|||||||||
|
|||||||||
The section variable gets passed when the help.tpl is called through the common_templates.tpl so it won't be available globally. You can't then use it on your other templates.
You can try: Code:
|
|||||||||
#3
|
|||||||
|
|||||||
Thanks for the reply. I took what you gave me and rearranged the if statements. Just incase anyone else wants to use this idea, here's the code.
Code:
Works great!!
__________________
~zilker uummm...perhaps you should tell me again. http://www.designertrends.com Version 4.0.6 Unix |
|||||||
#4
|
|||||||
|
|||||||
Thanks for sharing this code, it was looking for this same thing. Just one questions, what file do you edit for this code?
Thanks again and BTW your site you are developing looks great.
__________________
Cheers from Melanie ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Xcart V4.0.4 (Unix) - LIVE AOM, Fancy Categories Marketing Manager, Reward Points & Refer Rewards Advanced Site Map Easy Checkout Gift & Homeware House www.giftandhomewarehouse.com.au |
|||||||
#5
|
|||||||
|
|||||||
I inserted that into the head.tpl file although it can be placed in any file. Let me know if I can do anything else to help you.
__________________
~zilker uummm...perhaps you should tell me again. http://www.designertrends.com Version 4.0.6 Unix |
|||||||
|
|||
X-Cart forums © 2001-2020
|