Solved

Redirect Page from within Iframe

Posted on 2006-06-16
6
232 Views
Last Modified: 2012-06-27
Hey there, I have a page with an iframe inside.  Within the IFrame page there is a button which I want to do a "Response.Redirect" in it's OnClick method, only problem is I want it to redirect the entire page instead of just the page within the iframe.  Is this possible? Thanks.
0
Comment
Question by:belikemike121
  • 3
  • 3
6 Comments
 
LVL 7

Expert Comment

by:pradeepsudharsan
ID: 16925229
document.frames.if1.location.href="webform1.aspx";
0
 
LVL 7

Expert Comment

by:pradeepsudharsan
ID: 16925411
Hi,
sorry the previous one is wrong.
add the following script

<script language="javascript">
            function test()
            {
              window.open("MainForm.aspx");
            }
            
            </script>

<INPUT id="Button1" style="Z-INDEX: 103; LEFT: 312px; POSITION: absolute; TOP: 152px" type="button"
                        value="Button" name="Button1" onclick="test();">
This will display the full web form.

Regards
Pradeep
0
 
LVL 7

Accepted Solution

by:
pradeepsudharsan earned 250 total points
ID: 16925507
Hi,
prevoius one opens the new window.
window.open('MainForm.aspx','_parent'); -opens the form in the current window

Regards
Pradeep
0
Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 

Author Comment

by:belikemike121
ID: 16925601
the problem is I'm running a .NET script so I am using a .NET ImageButton control with a _Click method to capture its event.  I am running certain .NET code then after that executes i need it to redirect...
0
 

Author Comment

by:belikemike121
ID: 16925618
nvm, answered my own question, just doing a "Response.Write('<Script>')",....and so on...thanx
0
 

Author Comment

by:belikemike121
ID: 16925652
actually, problem with the script....it doesnt refresh, it will redirect but the page it redirects to is dynamic so it just displays whatever is in cache...doesnt actually display the right content, please help.
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

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

One of the pain points with developing AJAX, JavaScript, JQuery, and other client-side behaviors is that JavaScript doesn’t allow for cross domain request for pulling content. For example, JavaScript code on www.johnchapman.name could not pull conte…
Introduction This article shows how to use the open source plupload control to upload multiple images. The images are resized on the client side before uploading and the upload is done in chunks. Background I had to provide a way for user…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

808 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