I created a website where i passes url like this:
<base href="http://localhost:5423/" />
it all working fine for local.
but now i am deploying on host and problem arises here:
On the same index.vbhtml i have used menues like this:
<li><a class="home" href="Home/Index">Home</a></li>
<li class="wish"><a class="wishlist" href="Products/Index" id="wishlist-total">Products</a></li>
<li><a class="account" href="Home/Contact">Contact Us</a></li>
Now if i am trying with
HttpContext.Current.Request.Url
then its added root path everytime like if i click on Home,it shows correct first time:
http://192.168.1.100/Home/Index
But now if i am clicking again on same link,its adding Home again:
http://192.168.1.100/Home/Home/Index
what should be the solution for this.
Regards,
"/Home/Index". But don't hard code your url's. Use the helpers so they are always generated correctly.