How to make an html page to display content from another url

I want to make an html page that acts like a google cache.

Say on my HOME homepage, I have a link A to website B, and when I click on A, the page that exits displays the contents of another page with a floating bar at the top, which has some features of my own choice.

For example, I want my link to show google.com, but I also want to add a button (floating panel, whatever) to this google.com, which allows me to return to my own web page when I click.

Can someone provide me with some useful resources for me to look at or even a better solution template? :)

Thanks!

+4
source share
4 answers

The IFrame sounds like it might be what you need, but I'm not 100% sure after reading your description. The iframe will display content from a different URL on your page. Once you have all you have to do is style the page and use CSS / JavaScript to add to your functionality as described.

Check this out: http://www.w3schools.com/tags/tag_iframe.asp

+3
source

You can use <iframe> to display an external web page on your web page. Just put the URL of the webpage you want to display inside the quotes of the src attribute.

 <iframe src="http://www.webpage.com" width="400" height="400"></iframe> 
+2
source

Here's a general idea:

HTML:

 <a href="#" id="link">Click Here</a> <iframe id="frame" src="http://www.w3schools.com" scrolling="yes"></iframe> 

Some jQuery (not tested):

 $(document).ready(function() { $('#frame').hide(); $('#link').click(function () { $('#frame').show(); }) }) 

Use style if necessary

Note - this answer in no way supports w3schools.com :-). See w3fools.com /

+1
source

Either you use an iframe, or load the site via AJAX into a div (for example, using the jQuerys load() method).

+1
source

All Articles