...

View Full Version : need to refresh on redirect...



parallon
04-09-2007, 07:47 PM
Hello all. I have a page (Update.asp) which updates a database and now I want it to go back to the previous page (Info.asp) and then refresh that page. The problem is that the previous page is populated through various recordsets and not through the URL, so obviously I can't redirect to it.

Here is what I am using to go back to that page:


javascript:history.go(-2);

Normally, I used popups for edit pages and would return with the following:


opener.location.reload(true);self.close()

... but I wanted to get away from using the popups because of the delay to open a new browser.

Is there a way to accomplish what I am seeking? I hope this makes sense.

Thanks in advance,

Parallon

parallon
04-09-2007, 07:54 PM
Ok, I got what I was looking for using the following:


javascript:history.go(-2);
document.location.reload(true);

...but now when that page goes to reload, I get the message that Internet Explorer needs to resend the information previously submitted. Is there any way to get around this message?

Also, how come some dynamic pages get this message on reload and others reload without this message displaying?

Thanks,

Parallon

degsy
04-18-2007, 02:35 PM
It's doing that because the page has already been submitted and you are now tyring to reload (resubmit) it.

The best way around this is to store the query in a session or querystring variables and redirect to it and have it repopulate.

parallon
04-18-2007, 03:44 PM
You're right. I ended up changing the form method to "Get" and all is well.

Thank you for your time,

Parallon



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum