Solved

redirect parent page from an iframe (based in DotNetNuke)

Posted on 2007-04-05
3
577 Views
Last Modified: 2010-05-18
hi all,

our main site runs on DotNetNuke so the application i'm writing works within a viva.iframe within one of the pages.

I have set the timeout to 30 mins but when this expires (ie. session variables blank) i want to redirect the main page to the login page.

Is there an easy way to redirect the parent of an iframe, also has anyone had any knowledge working this with DotNetNuke as i tried a little test using a javascript function (parent.location.href='page.asp') but this didn't work.

I've managed to get it to detect when the session has timed out but my initial obvious redirect opened the entire site within the iframe (like it would).

Thank you
0
Comment
Question by:bhendrick
  • 2
3 Comments
 
LVL 11

Accepted Solution

by:
flipz earned 500 total points
ID: 18856776
If you want to redirect the topmost frame then use top.location.href='page.asp'.
0
 

Author Comment

by:bhendrick
ID: 18856839
thats exactly what i was looking for, brilliant thankyou.... something so simple yet so effective
0
 
LVL 11

Expert Comment

by:flipz
ID: 18857393
No problem - glad to be of help.
0

Featured Post

MS Dynamics Made Instantly Simpler

Make Your Microsoft Dynamics Investment Count  & Drastically Decrease Training Time by Providing Intuitive Step-By-Step WalkThru Tutorials.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question