开发者

Refresh other frame, from another frame. Jquery

Is it possible to reload the page, where the user came from or, even better, reload the frame the user came from, if it matches an URL?

I have a link. The user clicks it, and it opens in a new window, a new url. A form will run in that new window. What I want, is a function to reload the fi开发者_如何学编程rst window (Where the user came from)

Is that possible?


Alright. Here is what you do (just an example, tested, works):

test.html

<frameset cols="50%, 50%">
<frame name="f1" src="frame1.html">
<frame name="f2" src="frame2.html">
</frameset>

frame1.html

<input type="button" name="test" value="Refresh" onclick="parent.f2.location.reload()"> 

frame2.html

<span>Hello World</span>

variable parent is the parent of the current frame.

Read this page. its really helpful

Hope that helps


I think it is not possible if you open another window It would however be possible if you just use some kind of overlaying frame like jqmodal

the README should give you the necessary instructions: http://dev.iceburg.net/jquery/jqModal/README


How about loading the hyperlink url in the same page and redirect the user to the parent page after the form update is done.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜