CGI - Page Serving Problem
Posted: Tue Apr 15, 2003 4:04 am
Hi,
I have just created a script that logs the page hit and then serves up the main web page for a site, however when I serve the main page directly from the script all of the relative links become relative to my cgi-bin directory instead of to where the page is originally stored, this affects the images as well, they do not show up because their location is given to the page as a relative address to my cgi-bin.
Any ideas on how to solve this.
I am currently using an intermediate page that redirects automatically to the main page using a meta refresh, but I would really like to intergrate the logging seemlessly into my site so that the user doesn't even realise it has happened.
thanks.
I have just created a script that logs the page hit and then serves up the main web page for a site, however when I serve the main page directly from the script all of the relative links become relative to my cgi-bin directory instead of to where the page is originally stored, this affects the images as well, they do not show up because their location is given to the page as a relative address to my cgi-bin.
Any ideas on how to solve this.
I am currently using an intermediate page that redirects automatically to the main page using a meta refresh, but I would really like to intergrate the logging seemlessly into my site so that the user doesn't even realise it has happened.
thanks.