host name retrieving

  • Thread starter Thread starter Daniel
  • Start date Start date
D

Daniel

Hi guys, I have a web aplicaction that sends an email of type html. I have
an image displayed in the message, but the name and path of the file
appearently should be something like www.site.com/ap and not the server name
that could be mywebserver. Because if not the picture isn't showed.

How can I get the name www.site.com instead of the server name?
PS:The issue is that the web site is dinamically and we supose that the name
of publication of the website could be whatever, so we don't control it.
 
Request.ServerVariables["HTTP_HOST"]

I suppose this is what you are looking for.
 
Thanks so much it worked and it's just what I was looking for.

Manit Chanthavong said:
Request.ServerVariables["HTTP_HOST"]

I suppose this is what you are looking for.


Daniel said:
Hi guys, I have a web aplicaction that sends an email of type html. I have
an image displayed in the message, but the name and path of the file
appearently should be something like www.site.com/ap and not the server name
that could be mywebserver. Because if not the picture isn't showed.

How can I get the name www.site.com instead of the server name?
PS:The issue is that the web site is dinamically and we supose that the name
of publication of the website could be whatever, so we don't control it.
 
Back
Top