Open link in parent from child window or iframe using javascript

If you want to control parent window’s URL from the child frame or child window you can use “window.parent” to control the parent window.

The complete solution is:

<script type=”text/javascript”>
function check(url){
window.parent.location.href=url;
}
</script>

This is the small function to solve this problem.

Bansal Sumit

To seek challenging roles and to achieve excellence in the field of Open Source Web Technology with a profound spirit of commitment and dedication.

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.