网络营销电子商务研究中心  
How to buy the best prescription safety glasses in Canada? Let's study!
Go Back   网络营销电子商务研究中心 > 网站建设 > X-Cart
User Name
Password
 
FAQ Members List Calendar Cheap Glasses

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1   IP: 112.84.243.160
Old 2014-03-23, 01:29 AM
topvip topvip is offline
超级版主
 
Join Date: 2006-01-04
Posts: 1206
topvip 正向着好的方向发展
Default Common Smarty statements for X-Cart development

Home Page
Code:
{if $main eq "catalog" AND $current_category.categoryid ne ""}
I am on the home page.
{/if}
Any Category
Code:
{if $main eq "catalog" AND $current_category.categoryid gt 0}
I am on a category listing page.
{/if}
Specific Category (replace X with the numeric categoryid)
Code:
{if $current_category.categoryid eq X}
I am on category X.
{/if}
Any Product
Code:
{if $main eq "product"}
I am on the product details page.
{/if}
Specific Product (replace X with the numeric productid)
Code:
{if $product.productid eq X}
I am on product X.
{/if}
Any Static Page
Code:
{if $main eq "pages"}
I am on a static page.
{/if}
Specific Static Page (replace X with the numeric pageid)
Code:
{if $page_data.pageid eq X}
I am on page X.
{/if}

Manufacturer Listing
Code:
{if $main eq "manufacturers"}
I am on the manufacturers listing page.
{/if}

Any Manufacturer
Code:
{if $main eq "manufacturer"}
I am on the page of a specific manufacturer.
{/if}

Specific Manufacturer Page (replace X with the numeric manufacturerid)
Code:
{if $manufacturer.manufacturerid eq X}
I am on manufacturer X.
{/if}

Shopping Cart
Code:
{if $main eq "cart" OR $main eq "checkout" OR $main eq "order_message"}
I am in the checkout process.
{/if}

Checkout Process
Code:
{if $main eq "checkout" OR $smarty.get.mode eq "checkout" OR $main eq "order_message" OR $smarty.get.mode eq "order_message"}
I am in the checkout process.
{/if}

Anywhere Except Checkout
Code:
{if $main ne "cart" AND $main ne "checkout" AND $smarty.get.mode ne "checkout" AND $main ne "order_message" AND $smarty.get.mode ne "order_message"}
I am in not in the checkout process.
{/if}

Only If Logged In
Code:
{if $login ne ""}
The user is logged in.
{/if}

Only If Logged Out
Code:
{if $login eq ""}
The user is logged out.
{/if}
Reply With Quote
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
有关Zen Cart的一些常用操作 yahoo ZenCart 0 2009-12-01 09:36 PM
How to Install an Zen Cart Template topvip ZenCart 0 2009-08-23 05:35 PM
zen cart定制 zen cart二次开发 car ZenCart 0 2009-08-21 01:11 AM
X-Cart Multiple Input Validation Holes Permit SQL Injection and Cross-Site Scripting topvip X-Cart 0 2009-07-21 10:03 AM
x-cart Template Editing Guide for 4.1.x topvip X-Cart 0 2009-04-15 11:42 PM

Prescription-glasses.com offers prescription glasses online at discount prices.
All times are GMT +8. The time now is 11:08 AM.


Powered by vBulletin Version 3.8.7
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.