Rev CGI scripts
andre at andregarzia.com
Mon Aug 11 21:22:03 CDT 2008
instead of linking with URLs like
why don't you use root relative paths without the server, like:
if so, the server part will be assumed to be the same one serving the page.
On Mon, Aug 11, 2008 at 11:11 PM, Sarah Reichelt
<sarah.reichelt at gmail.com> wrote:
> Hi All,
> I'm writing a Rev-based CGI stack and one of it's functions is to
> return a web page containing a set of links that the CGI stack has
> This web page is not saved anywhere, it just gets sent back to the
> calling browser, so the links in it need to be absolute links, not
> relative links.
> For this to work, the CGI stack needs to be able to know it's own address.
> e.g. if I am running it on my own computer for testing, the address
> will be http://localhost:8888/.....
> and if on another computer on the network, it might be
> and the first part of these addresses needs to be the first part of
> any links in the returned web data.
> Based on a post by Ken Ray
> I have been trying to use the system globals, but while I can get
> $SERVER_PORT, I don't have a global that gives me the address.
> $SERVER_NAME and $SERVER_ADDR do not exist, whether I call the CGI
> from within Rev or from a browser.
> Does anyone have any ideas, as I really don't want to hard-wire this in.
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://www.andregarzia.com All We Do Is Code.
More information about the use-livecode