Forums

This topic is locked

Optional Regions

Posted 31 Mar 2004 07:35:48
1
has voted
31 Mar 2004 07:35:48 Carol Greenberg posted:
I'm trying to set up an optional region on a template that does the following:
- If the name of the document is "index.htm" then don't display the text link to the home page.
- if the page name is anything else, then do display the text link to the home page.
Can someone show me the example code for this? I can't find any simple examples of something similar.

Replies

Replied 31 Mar 2004 14:09:48
31 Mar 2004 14:09:48 Phil Shevlin replied:
<pre id=code><font face=courier size=2 id=code>&lt;% if (Request.ServerVariables("SCRIPT_NAME" &lt;&gt; "/index.asp" then %&gt;
&lt;a href="/index.asp"&gt;HOME&lt;/a&gt;
&lt;% end if %&gt; </font id=code></pre id=code>

I'm going by memory. Research script_name if this throws errors.

Edited by - wdglide on 31 Mar 2004 14:10:28

Reply to this topic