R
Rob Meade
Hi all,
I have the need to write a meta tag to the page BEFORE it loads...
My page does 3 things based on whats passed through in the query string:
1. Receive a file id and check its valid, display "Retrieving file...please
wait.", redirect to same page with altered querystring
2. Based on new querystring value retrieve document details and check its ok
to allow the user to download the file,, display a message to the user
depending on outcome of check either "sorry" and then nothing else happens,
or "Document ready to download" - redirect to same page with altered
querystring
3. Based on new querystring value, transfer file via SA-FileUp..
I did this in old ASP, each "page" was in between the if...then's etc, and
each "page" could have its own "meta refresh" if needed, 2 of them do, one
doesn't....
Now I'm trying to recreate this in a dot net page, I have panels for the
relevant sections, they get turned on/off depending on the
querystring/checks etc, but the meta refresh is a problem as if I add it to
the page in the HTML its therefore all 3 steps and the last one will keep
redirecting, so I need to be able to programmatically write this:
<meta http-equiv="refresh" content="--my duration, page and querstring
would be in here--">
to 2 of my steps based on the querstring values etc...and not on the
last...I managed to do this with a javascript function being called (or not)
with onLoad="" in the html being written based on criteria by setting the
body tag to runat="server" and then adding/removing an attribute but I
cannot do this for the meta tag...
I'm guessing these need to be written before the page renders? But have no
idea how to go about it...
Any help would be appreciated.
Regards
Rob
I have the need to write a meta tag to the page BEFORE it loads...
My page does 3 things based on whats passed through in the query string:
1. Receive a file id and check its valid, display "Retrieving file...please
wait.", redirect to same page with altered querystring
2. Based on new querystring value retrieve document details and check its ok
to allow the user to download the file,, display a message to the user
depending on outcome of check either "sorry" and then nothing else happens,
or "Document ready to download" - redirect to same page with altered
querystring
3. Based on new querystring value, transfer file via SA-FileUp..
I did this in old ASP, each "page" was in between the if...then's etc, and
each "page" could have its own "meta refresh" if needed, 2 of them do, one
doesn't....
Now I'm trying to recreate this in a dot net page, I have panels for the
relevant sections, they get turned on/off depending on the
querystring/checks etc, but the meta refresh is a problem as if I add it to
the page in the HTML its therefore all 3 steps and the last one will keep
redirecting, so I need to be able to programmatically write this:
<meta http-equiv="refresh" content="--my duration, page and querstring
would be in here--">
to 2 of my steps based on the querstring values etc...and not on the
last...I managed to do this with a javascript function being called (or not)
with onLoad="" in the html being written based on criteria by setting the
body tag to runat="server" and then adding/removing an attribute but I
cannot do this for the meta tag...
I'm guessing these need to be written before the page renders? But have no
idea how to go about it...
Any help would be appreciated.
Regards
Rob