rgrne Posted January 15, 2007 Share Posted January 15, 2007 Is there some way to do the following:?I want to have a script running in iframe A that does a <META http-equivalent...> refresh every 10 seconds to to check the status of a text file on the server (using a PHP script serverside). When the information in the file changes, I want the information in a second iframe B, handled by a different script, to change. For various reasons I don’t want to do the <META http-equivalent...> refresh in iframe B itself, because I don’t want that information to be constantly refreshing itself. Is there such a thing as a “target” statement for <META http-equivalent…. > like there is for links? I found references to something called “Window-Target” and tried it but that didn’t do anything (at least in Firefox) - it just refreshed frame A no matter what I told it the target was.If there is no way to do this in HTML, can it be done with Javascript? Quote Link to comment Share on other sites More sharing options...
Soarchrist Posted January 15, 2007 Share Posted January 15, 2007 If I understand your question correctly, you want one script constantly checking on a status of something, and then when that item meets your criteria, more information opens up?No way both items can be in the same frame? I'll think about ways to do this while you direct me in your question...S. Quote Link to comment Share on other sites More sharing options...
rgrne Posted January 15, 2007 Author Share Posted January 15, 2007 Sort of. One script constantly checks a simple .txt file to see if it has changed (the change will come from an external source, which will change the .txt file). When a change occurs, the value of that change is used to change the information being displayed in iframe B. Most importantly, the constant checking must be done in a way that does not cause the information in iframe B to keep refreshing every ten seconds. That would cause the processes that are going on in iframe B to start over at the beginning every ten seconds. I only want it to refresh when the change is detected, which will probably only happen, on the average, every half hour or so. Otherwise I could just do a <META...> refresh in iframe B every ten seconds and be done with it. I don't really care if this is all going on in the same frame or different frames or no frames at all, as long as I can check the file in the server without constantly refreshing the information that is being displayed. Thats why I started experimenting with a <META...> refresh being performed in a second iframe. Quote Link to comment Share on other sites More sharing options...
fenway Posted January 15, 2007 Share Posted January 15, 2007 Well, you're going to have to hit the server somehow to "check"... obviously, AJAX is an option here. Quote Link to comment Share on other sites More sharing options...
Daniel0 Posted January 16, 2007 Share Posted January 16, 2007 I only read the title (sorry, I was lazy), so sorry if this doesn't answer it.Now we say frame a has the name frame_a and frame b has frame_b. You can do it using javascript: [code]frame_a.location.reload(true);[/code](I think) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.