I'm trying to retrieve the value of myID from my URL. I'm testing this using <%=Request.QueryString["hotelid"] %>.
It only works the first time the page is loaded either in a new browser, or if my project has been rebuild.
My URL string is typical: http://my/path/to/site/?hotelid=2.
If I try <%=Request.QueryString %>, I'm also getting other values as well. Values I do not see inthe URL string.
What am I missing here?
Update:
Using <%=Request.RawUrl%>, I get the following results:
/Util/NotFound.aspx?404;http://localhost/en/Tjenester/Hotellguiden-2/Hotel-informasjon/?hotelid=3
I have NO idea what the /Util/NotFound.aspx?404 is or where it comes from.
My URL looks like this:
http://localhost/en/Tjenester/Hotellguiden-2/Hotel-informasjon/?hotelid=2
Update 2: I'm currently investigating if it is EPiServer CMS that is using some kind of caching.
Update 3: I have solved it. EPiServer is using EPnCachePolicyTimeout which isset to 1 hour. Setting this to 0 (zero) solved my problem.
Sometimes is really helps just writing aboutthe problem here, talking "aloud" about it and voila :)