Hi,
I have an ASP.NET 1.1 website with as ASCX control for the header which includes a link to a page. Why is it that when i upload my site, i have to manually change the absolute URL paths?
After much messing i've discovered that locally they have to be...
but on the web they need to be just...
I have looked all over the net for an answer to this but found very little. Neither of these suggestions seems to work...
or
Does anyone know of a common method that would work both locally and on the host server? Surely I don't have to manually change my code every time i want to upload, then back again when i want to test locally?
Any help would be greatly appreciated.
Silo4
I have an ASP.NET 1.1 website with as ASCX control for the header which includes a link to a page. Why is it that when i upload my site, i have to manually change the absolute URL paths?
After much messing i've discovered that locally they have to be...
Code:
/MyWeb/MyPage.aspx
but on the web they need to be just...
Code:
/MyPage.aspx
I have looked all over the net for an answer to this but found very little. Neither of these suggestions seems to work...
Code:
~/MyPage.aspx
or
Code:
<%ResolveUrl("~/MyPage")%>"
Does anyone know of a common method that would work both locally and on the host server? Surely I don't have to manually change my code every time i want to upload, then back again when i want to test locally?
Any help would be greatly appreciated.
Silo4