Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8691795
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T00:11:46+00:00 2026-06-13T00:11:46+00:00

I am using an iframe in a page where the iframe looks like a

  • 0

I am using an iframe in a page where the iframe looks like a div on the main asp.net page. In the Iframe page i have got a close button and when i click on close button i am calling a javascript function in iframe page which is having the code as:

window.location.href = “Pagename.aspx”;

this line closes the Iframe but the main page which contains Iframe refreshes after closing the iframe so…. I tried in many ways to close the iframe without refres like

window.close();

but it is not working. The main problem to close the iframe is that the close btn is in the iframe page it self so if i write the code to close iframe in iframe page that does not work…..

The main issue being that the iframe close btn should work like a div close btn that means when i click the close btn div can be made as dislay none but iframe how can i make it close when the iframe value can be accessed in the main page that contains iframe but that iframe page cannot get the iframe name….

So, can u please help me solve this issue .. that is closing of iframe without refreshing main page that contains iframe. Thanking you in advance!!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T00:11:47+00:00Added an answer on June 13, 2026 at 12:11 am

    Do you control the parent page? You could put the script to close the iframe in the parent. So, in the parent page you have

    function myCloseIframeFunction(){
      /*close iframescript*/
    }
    

    and then call parent.myCloseIframeFunction() from the iframed page.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm making a very simple ad button system using ASP.NET 2.0 The advertisment is
I have an iframe that looks like this: <iframe src=http://www.google.com height=1000 width=500 id=myiframe></iframe> I
I have a form (which happens to be in an iframe) that looks like
I am using iframe to open new .aspx page from parent page. child page
I am using a hidden iframe to print page contents generated by php, this
I have a script on jquery that load some site in iframe using: $(#demo_frame).attr('src',
I am using chrome version 18.0.1025.162 m I have html file with iframe within
I have a website that consists of one parent page. Using the lightbox-style jQuery
I have a DIV on my page. Within the DIV I have other DIVs
I have an Iframe inside of a page that has the src set to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.