I am using 2 Iframe in my index page. If any action is preferred from any Iframe, it must reload that Iframe alone. But it overrides my index page as one of the Iframe URL. Can any one help me to fix this issue.
My expected result is working in Chrome but it not working in Internet explorer
Note: Iframe id and name generated automatically
I used the below command to refresh the Iframe window
window.location.reload(true)
window.top.location.reload(true)
Try to reload the specific Iframe element because you're probably reloading the whole page (window) right now.
1- First you must take the name for each Iframe with the name
attribute.
2- Later try to use the javascript function document.getElementsByName("IframeName")
to retrieve the specific Iframe. After that you can take the resulting object (the Iframe) to apply the changes you need (to change the src
attribute).
IMPORTANT: Remember that iframes are neither supported by every browsers nor HTML5.
Hope it helps you...
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.