| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
Best way to edit pages_menu.tpl and pages.php | |||
|
|
Thread Tools | Search this Thread |
#1
|
|||||||||
|
|||||||||
Best way to edit pages_menu.tpl and pages.php
Hi,
I have 5 different static pages. But I only want to list 4 of them throughout the pages_menu.tpl. The fifth one I only want to accessible through a hyperlink like: pages.php?pageid=5 As I use different languages that page 5 will probably have a different pageid in the different languages. So whats the best way to tackle this ? Change pages.php and create an extra extra php-file for extracting only page 5 (this I know how to do) OR Change pages_menu.tpl (this I dont know how tod do) so that it doesn't list page 5 and create an extra template for page 5 only. Some advise and help would be much appreciated. Thanks in advance, Gijs |
|||||||||
#2
|
|||||||||
|
|||||||||
Hi,
Anybody who could point me to the right direction ? Thanks, Gijs |
|||||||||
#3
|
|||||||||
|
|||||||||
wrap edit pages_menu.tpl as follows... (4.0.5 code)
Code:
then add your link to page 5 where ever you need to
__________________
Looking for a reliable X-cart host ? You wont go wrong with either of these. EWD Hosting Hands On Hosting |
|||||||||
#4
|
|||||||||
|
|||||||||
Hi shan,
Thanks very much ! I'll give it a try. Correct me if I'm wrong, but through smarty-templates you can ad conditional statements (WHERE clauses) in stead of perfoming it them php. Best regards, Gijs |
|||||||||
#5
|
|||||||||
|
|||||||||
doh, corrected my post
__________________
Looking for a reliable X-cart host ? You wont go wrong with either of these. EWD Hosting Hands On Hosting |
|||||||||
#6
|
|||||||||
|
|||||||||
Pages inside X-cart menu and layout structure
Hi all
As a newbie, I found a different solution to this problem of displaying special pages inside the x-cart frame work and not appearing on the menu listing. I have normal Pages listed on the menu, Hidden pages not shown on the menu but you can call up via links to these pages, and Test pages that you can view but are not available to the public until you enable them (eg. xmas specials). All the pages can be edited through Admin or you can edit the HTML file directly /yoursite/skin1/pages/US. If you are interested, I will send you the files. They are a bit long to list here. The mods are to V4.0.5 but you can make them work on any version. Regards Stephen Hatton email: stephen_hatton1959@yahoo.com.au
__________________
Apache Linux V1.3.33 PERL version: 5.8.0 PHP version: 4.3.11 MySQL version: 4.0.22-standard X-cart V4.0.17: Addons: X-PConfig, X-Giftreg, X-Fancycat, X-AOM |
|||||||||
#7
|
|||||||||
|
|||||||||
Hi Shan,
Code works fine. As a use different languages i have work around the fact that the pageid in the pages table is auto_increment. Found a solution: Code:
I use the $lng.lbl_select as a criterium. I'm not happy with that at all. I would prefer to use language-values like US and NL. Question: is there a $variable language that could be called ? This way i could use {if $language eq "US"} |
|||||||||
#8
|
|||||||||
|
|||||||||
should be
edit xcart/smarty.php find Code:
change to Code:
now you see a better list of vars when u use the debug window
__________________
Looking for a reliable X-cart host ? You wont go wrong with either of these. EWD Hosting Hands On Hosting |
|||||||||
#9
|
|||||||||
|
|||||||||
thanks shan,
Great tip Found it: Code:
|
|||||||||
|
|||
X-Cart forums © 2001-2020
|