Forums / Templates, Stylesheets, Page Layout / VARIABLE / CONSTANT that displays page name?

VARIABLE / CONSTANT that displays page name?

Locked

Started by edwardtilbury on 5 Apr 2009, 7:34 PM · Views: 1,163

Results 1 to 5 of 5
This thread is locked. New replies are disabled.
5 Apr 2009, 7:34 PM
#1
edwardtilbury avatar

edwardtilbury

Zen Follower

Join Date:
Sep 2007
Posts:
169
Plugin Contributions:
0

VARIABLE / CONSTANT that displays page name?

What's the variable or constant that displays the name of the page?

Like main_page , product_info etc..

thanks!

AIM edwardtilbury
GoogleTalk edwardtilbury

5 Apr 2009, 7:41 PM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,515
Plugin Contributions:
176

Re: VARIABLE / CONSTANT that displays page name?

Depends what you're trying to do with the information, and where ...

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

5 Apr 2009, 7:52 PM
#3
edwardtilbury avatar

edwardtilbury

Zen Follower

Join Date:
Sep 2007
Posts:
169
Plugin Contributions:
0

Re: VARIABLE / CONSTANT that displays page name?

I would like to build some swith / else if statements so that some of my menu items will appear on certain levels of the catalog.

AIM edwardtilbury
GoogleTalk edwardtilbury

5 Apr 2009, 8:11 PM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,515
Plugin Contributions:
176

Re: VARIABLE / CONSTANT that displays page name?

In v1.3.x, you can usually use $current_page_base to get the value of the "main_page=" setting on the URL. If you're trying to access it from inside a function/class you'll need to global that variable to access it.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

5 Apr 2009, 8:15 PM
#5
edwardtilbury avatar

edwardtilbury

Zen Follower

Join Date:
Sep 2007
Posts:
169
Plugin Contributions:
0

Re: VARIABLE / CONSTANT that displays page name?

Thanks! I'll give it a shot!:clap:

AIM edwardtilbury
GoogleTalk edwardtilbury