Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Forcing A page to reload

Status
Not open for further replies.

Ramjet

Programmer
Nov 1, 2000
21
US
Hello all,

I have a javascript that works in Netscape 4.x and 6 but
not in IE. A different variation I tried worked in IE 5.0
only, so I think I probably am missing something.

Anyway when a user clicks on a form element a page in a frame is loaded displaying help information. What happens is that as they change focus so does the value of the variable (which is the corresponding html page). So I have tried the following to force an update everytime the variable changes: Any ideas why this doesn't work on all browsers would be great and I am also open to any ideas of
possibly incorporating all files into one page then just loading the appropriate html string.


function RLoad(HlpLoc)

{
location.href = " + HlpLoc;
location.reload
}
 
try : location.reload(true) to actually force the reload
 
Well,

I still don't understand java enough to get it to work.
Here are the results of these 2 lines of code.

On IE 5.5 no errors but page doesn't change according to variable value.

On IE 5.0 I get Object does not support this property or method.

On Netscape 4.x same as IE 5.5 no errors but page doesn't
change.

On Netscape 6 no error but it doesn't load either.

Take a look at the page if you want and you can see what
I am trying to do. The onlt radio button that works right now is the New button.

You can get my script from page source.

Thank you very much for helping with this
 
Well,

I still don't understand java enough to get it to work.
Here are the results of these 2 lines of code.

On IE 5.5 no errors but page doesn't change according to variable value.

On IE 5.0 I get Object does not support this property or method.

On Netscape 4.x same as IE 5.5 no errors but page doesn't
change.


On Netscape 6 no error but it doesn't load either.

Take a look at the page if you want and you can see what
I am trying to do. The onlt radio button that works right now is the New button.

You can get my script from page source.

Thank you very much for helping with this
 
there was another tthread on the same subject
it ended up saying that the best way is to add a random value in the parameters so the page is always refreshed

anyway why don't you display the help in an help frame or something (pop up, tooltip, status bar..), it's much easier and logical
because what you're trynig to do is to reload the WHOLE form anytime a user changes the focus just to show help ??
 
ok, I did this:

Page A bottom frame had a open text window button and also displays current text messages with date and time. User opens text window and types in a message and clicks a save button. Text window closes and Page A refreshes using these lines.

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

This works great on my PC, but everybody else with the same IE version browser gets a permission denied error. What's up with that?
 
it's a security problem : you can't close the main window (at least without an alert, it depends on the browser settings)
 
If you are familar with how or what security setting needs to be enabled or disabled in IE 5+, it would be very beneficial. I am not closing the main window, I am just refreshing.
 
Dunno whether this is what you are looking for, i used this in a page that needed to be automatically refreshed every five seconds in order to keep an eye on printer queue sizes via an intranet, the time frame though is up to you, ( a maximum of about 7 days i believe )

Place the following in your HTML header,

<meta HTTP-EQUIV=&quot;REFRESH&quot; CONTENT=&quot;Time In Seconds Before Refresh; URL=Your Address Here&quot;> DeltaFlyer ;-)

DeltaFlyer - The Only Programmer To Crash With Style.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top