On Sun, 16 Nov 2003, kirun wrote:
> As part of my 404, I want to offer a link back to the referring page.
> Doing this makes no sense if there wasn't one.
>
> Currently, I have:
>
> <!--#if expr="$HTTP_REFERRER = '(none)'" -->
^
Misspelled (you spelled it correctly, but it's supposed to be misspelled).
There's also the matter of what you're comparing to: "(none)" is produced only
when an empty variable is printed.
I looked at my own script and noted that one only need test to see if there's
ANY value set - i.e.:
<!--#if expr="$HTTP_REFERER" -->
was sufficient....
> You appear to have typed this URL directly.</P>
> <!--#else -->
> Or maybe you'd like the <a href="<!--#echo var="HTTP_REFERER"
> -->">referring page</a>?</P>
> <!--#endif -->
>
> This doesn't work, I always get the referring page text.
>
> Any ideas?<!-- ~MESSAGE_AFTER~ -->
>> Stay informed about: referring page in custom 404