Re: Resolve site url
From: CJF (chrisf_at_unr.edu)
Date: 03/10/04
- Next message: Steven Cheng[MSFT]: "Re: aspnet_wp.exe hanging"
- Previous message: Steve C. Orr [MVP, MCSD]: "Re: registerhiddenfield question"
- In reply to: George Ter-Saakov: "Re: Resolve site url"
- Next in thread: George Ter-Saakov: "Re: Resolve site url"
- Messages sorted by: [ date ] [ thread ]
Date: Tue, 9 Mar 2004 16:30:47 -0800
It means the tilde is set literally into the property.
img1.imageurl = "~/images/img.gif"
View the html source of the resulting page and the image's property reads
"~/images/img.gif" and not http://mysite.com/images/img.gif.
Thanks for the info.
"George Ter-Saakov" <nospam@hotmail.com> wrote in message
news:uFUnhfiBEHA.2768@tk2msftngp13.phx.gbl...
> Not sure what you mean by "sometimes the ~ does not work"
>
> Anyway you can use
> Request.ApplicationPath to get the path.
>
> George.
>
> "CJF" <chrisf@unr.edu> wrote in message
> news:Oq0YRlhBEHA.684@tk2msftngp13.phx.gbl...
> > Sometimes the tilde ~ won't work to resolve the url of the asp.net site,
> > such as when I need to set the path to an image property in vb.net.
When
> > this is the case how can I get the URL to the project's site?
> >
> > Thanks, Chris
> >
> >
>
>
- Next message: Steven Cheng[MSFT]: "Re: aspnet_wp.exe hanging"
- Previous message: Steve C. Orr [MVP, MCSD]: "Re: registerhiddenfield question"
- In reply to: George Ter-Saakov: "Re: Resolve site url"
- Next in thread: George Ter-Saakov: "Re: Resolve site url"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|