Suppose I have a resource located in ~/Resources/R1.png
This resource's relative URL will vary depending on the current address.
For instance:
If I'm at www.foo.com/A/B/C/D.aspx
and the www.foo.com/A
is the root path including Virtual Directory, then the path relative to the current address of ~/Resources/R1.png
is ../../../Resources/R1.png
How can I get this relative path?
EDIT:
I want a web path that I can use in a web page, not a server path.