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

  • Home
  • SEARCH
  • 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 7433697
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T09:42:50+00:00 2026-05-29T09:42:50+00:00

Basically I have an IFRAME that contains a given page – I want to

  • 0

Basically I have an IFRAME that contains a given page – I want to be able to remove all anchor links and form targets so that the user is not able to navigate to other pages within the IFRAME. Is this possible to do?

<iframe src="<?php echo $url; ?>"></iframe>

EDIT: RobinUS2 has provided a solution below, however how do I now remove all JavaScript events on the page?

  • 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-05-29T09:42:51+00:00Added an answer on May 29, 2026 at 9:42 am

    If you insist on using PHP for doing this you should fetch the page and process it. Use a function like “file_get_contents()” and a regex to modify the HTML output.

    However you might also consider using something like jQuery to dynamically manipulate the iframe.

    In jQuery you can do something like:

    $('#my-iframe').contents().find('a').click(function() { return false; });
    $('#my-iframe').contents().find('form').submit(function() { return false; });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Basically I have an IFRAME that displays a given page. I want to position
I have an iframe that contains a page that is constantly updating (basically a
Basically I have an IFRAME that displays a given page. I am using jQuery
Basically, I have an iframe of a page from another domain, and I want
Basically I have a page that launched a fancybox iframe. In that iframe I
I have a page that contains a dynamically loaded <iframe> . This iframe contains
Basically, I have an iframe embedded in a page and the iframe has some
Basically I have an iframe loaded that is accessed from the parent whenever it
I'm trying to create a widget (which is basically an iframe) that would have
What a mouthful. Basically I have a parent <div> and inside that an <iframe>

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.