Documentation >> Conditionals >> Web Server >> requestPageType
Conditional Macro: requestPageType
Operators:
- == (equal to)
- != (not equal to)
Usage Notes
- Tests the type of page that is currently being rendered/served (the page that contains the macro) against the value provided.
- The current list of page types on servers in the Free-Conversant hosting network include (note: other installations of Conversant will have additional page types, contact Macrobyte Resources for details):
- Advanced Query Page
- Bound Message
- DG Calendar Page
- Event Calendar
- FullThread Page
- MailForm Page
- Query Page
- Redirect Page
- Topics Page
- Weblog II
- Weblog
- WeblogView
- Weblog II
- WebOutline
- signup
- logon
- logoff
- Message (This one's used for all message viewing/creating/replying/editing pages.)
- This conditional macro could be useful for consolidating your page templates, because it allows you to put all of your pagetype-specific features into a single template, and hide them from any page that they don't belong to. See the example.
Examples
This example would use line 1 on a weblog, line 2 on an Bound Message (a 'traditional web page'), and line 3 on any Message page (any viewing of a discussion group message).
<!--#if condition="requestPageType=='Weblog'"-->
1. The text and macros listed here will only be used on a weblog page.
<!--#elseif condition="requestPageType=='Bound Message'"-->
2. Anything here is used only on Bound Message pages (that is, discussion group messages which have been published to traditional URL's)
<!--#elseif condition="requestPageType=='Message'"-->
3. Anything on this line would be seen on the message viewing/replying/editing pages.
<!--#endIf-->
See the above code in action, here:
2. Anything here is used only on Bound Message pages (that is, discussion group messages which have been published to traditional URL's)
View in DG
|