[ic] using __SERVER_NAME__ vs. softlink

Ron Phipps rphipps at reliant-solutions.com
Mon Jan 19 00:17:40 EST 2004

> From: interchange-users-bounces at icdevgroup.org
> bounces at icdevgroup.org] On Behalf Of Nicholas Cook
> I have noticed that making softlinks don't always work in interchange.
> In other words, <a
> href="http://__SERVER_NAME__/cgi-bin/cat/somepage.html">Some Page</a>
> and <a href="somepage.html">Some Page</a> don't neccessarily both go
> http://www.someserver.com/cgi-bin/cat/somepage.html.  The link that
> just sompage.html, without the url and catalog information sometimes
> (less than 1% of users on my sites) will take you to
> http://www.someserver.com/cgi-bin/somepage.html.  Notice that the
> catalog (cat) portion of the url is missing.  Has anybody tied
> why this happens and under what circumstances?  Should we just always
> using full links, or is there something I have missed someplace?
> IC version is 4.9.  Apache version is 2.0.40.
> Thank you,
> Nicholas Cook

Unless I'm missing something, the correct way to write all your links

<a href="[area somepage]">Click here</a>

the [area] tag generates the server name, catalog program and the
session id (which is required when someone has cookies turned off).
There really should not be a need to build the links by hand.  Also the
cool thing about this is you can move your catalog to a new domain or
change the link program name and none of your links will break.  Look at
the [area] tag in the docs to see the options you can pass to is, like
cgi/form variables.


More information about the interchange-users mailing list