Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Sep 03, 2011 02:48 AM by MtheK
Sep 01, 2011 12:55 AM|LINK
I have been fighting with links on my site. I have a root directory with my default.aspx page and my login.aspx page. I then have a /store file with all the rest of my pages save a few which are in their own directories. I have a /about directory and a /faq
directory. I have a button that does this:
ShoppingCart.aspx is in my /store directory, so usually this redirects fine. However whenever I'm on any other page and click this button (it's a master page button) I get this error:
Cannot use a leading .. to exit above the top directory. Obviously it says this because it can't search through the sub-directories (namely shop) when I set it to ../ but i'd like it to. I just don't know how. Can I get help?
Sep 01, 2011 01:49 AM|LINK
How about Response.Redirect("~/store/ShoppingCart.aspx")
Sep 03, 2011 02:48 AM|LINK
SWEET IT WORKED!
I see how that works now. I never understood it. the ~/filename/file points directly to the file in THAT directory. I never understood that.