View Full Version : show the full path
alaios
04-03-2003, 08:04 PM
I have some related paths like <img src="/images/hello.gif">
How i can produce the full path?
<img src="<% =Something in asp %>/images/hello.gif">
The result must be
<img src="http://www.ineedit.com/images/hello.gif">
Thank u!
Morgoth
04-03-2003, 08:17 PM
Really depends on what hosting you are using...
In your case I think, the domain name...
So try: <="http://" & Request.ServerVariables("SERVER_NAME") & "/images/hello.gif"%>
OR
<="http://" & Request.ServerVariables("HTTP_HOST") & "/images/hello.gif"%>
They pretty much do the same thing...
SERVER_NAME = domain.com or www.domain.com or subdomain.domain.com
HTTP_HOST = domain.com or www.domain.com or subdomain.domain.com
Does this help?
And remember, it really depends who is hosting the page..
If it's brinkster, or something, then you might have a little more varibles you need to deal with...
If you have the exact page location (or an example of what it looks like) then I can give you the exact code.
Roelf
04-03-2003, 08:18 PM
<img src="<% =Request.ServerVariables("HTTP_HOST") %>/images/hello.gif">
i think, at least
Roelf
04-03-2003, 08:18 PM
darn, you beat me to it
Morgoth
04-03-2003, 08:19 PM
Thanks Roelf, I had no clue. :p
vBulletin® v3.8.2, Copyright ©2000-2012, Jelsoft Enterprises Ltd.