HTML load two urls in two frames in one page - html

it is simple enough as an idea but i never tried it and attempted with the following code:
<html>
<frameset cols="30%,70%">
<frame src="www.google.com" name="frame1">
<frame src="www.yahoo.com" name="frame2">
</frameset>
</html>
example what am trying to load is google.com and yahoo.com in one page in two different frames. Any idea how?
Thanks,

use iframes!
<iframe src="url" alt="circa1990browser" />
<iframe src="url2" alt="circa1990browser" />
but i agree with the poster below. what you posted is technically correct and should work, as far as i know...

HTML5 has depreciated the use of frameset and frame tags.
Browsers like Google Chrome (which are widely used) are switching completely to HTML5.
Hence, using frameset and frame tags for public apps would be dangerous.
About the question:
The pages you are trying to load i.e. Yahoo and Google do not allow that by their X-frame-options.
So, it is virtually impossible now.

Thats its its will work for you....is there any error in that ? Accorcing to me this will work fine.
Check this W3C site for more details : Frames

Quite an old question, but I believe I have the answer for you.
I believe google and yahoo have some sort of JavaScript running on their pages that detects whether they are being loaded in a frame, and if so, do not display any content.
In other words, your code is technically valid, but Yahoo and Google are explicitly preventing this action.
See this JSfiddle example. The Yahoo and Google frames do not work, but the Craigslist one does.
(Note that I used iframes rather than a frameset, but the end result will be the same.)

Related

iframe issue in Firefox - Not showing up at all

I am developing a webpage for a client, and they want to have their Facebook feed in a sidebar. I was happy to find out that it is very easy to embed a Facebook feed, but was unhappy to see that it doesn't seem to work.
After really scratching my head on the issue, I decided "hey, maybe it just isn't working in Firefox", so I factored down to the least common denominator and fired up IE - sure enough, it shows up with no issue in IE. Here is a screenshot of the difference:
http://i.imgur.com/WQ9br1A.png
To make matters a little more strange, this isn't a universal issue in Firefox for me. iframes are showing up great everywhere else. The W3Schools test page, for instance, shows up fine... unless I'm using the Facebook code. For those unfamiliar with it, Facebook provides automatically generated code for feed embeds, and it is as follows:
<iframe src="https://www.facebook.com/plugins/page.php?href=https%3A%2F%2Fwww.facebook.com%2Ffacebook&tabs=timeline&width=340&height=500&small_header=false&adapt_container_width=true&hide_cover=false&show_facepile=true&appId" width="340" height="500" style="border:none;overflow:hidden" scrolling="no" frameborder="0" allowTransparency="true"></iframe>
I suspect since this is the only frame that is giving me issues, there's something wrong with Facebook's code, but it strikes me as odd that a web giant such as Facebook would provide developers with faulty code that was untested on a popular web browser.
Is there something wrong with Facebook's code? My Firefox? Help much appreciated.

Firefox makes bogus call when a video tag is present

I have a weird problem with firefox only.
To put it simply, I have an html (jsp) page with a <video> tag in it.
If I monitor how the page is loading with firebug, I can see that, at the end of the loading, a request is made to the "base href" of my page.
I have a base href tag like this : <base href="http://localhost:8080/CHU/" /> and the call is "GET /CHU/" (see screenshot below)
I can see the video being loaded and be ready to play before that bogus call happens!
If I remove everything in the video tag, like this :<video></video> the bogus call still happens.
For some reason this call will update the session and mess up with other stuff. So I have to prevent that to happen.
Any ideas?
Regards,
Michel
PS: works fine with chrome and IE
I have a site that shows a very similar behaviour. I use jwplayer 6.5, Ff 22 and disabled the flash add in. A video tag is created, then an error is thrown. A trace on the net shows a call to the root of the site (base). It looks as if the video play were attempted with an empty source. The longtail guys claim it's not their script causing this, and I tend to believe them. It's only their handler that catches the error. So I believe I indeed seeing the same symptom. Funny thing is: it only happens if the page was generated by Typo3. A static copy of the site with the same scripts does not show this. Tricky. If I find anything, I'll let you know. Might solve your issue as well.
If have exactly the same problem using latest firefox, html5-video and base-href.
http://jsfiddle.net/38h8b/6/
<base href="http://jsfiddle.net/38h8b">
<video width="320" height="180" src="http://media.sublimevideo.net/vpa/ms_360p.mp4" autoplay="true"></video>

Embedding Html page inside another Html page without using iFrames

I ran into an issue where one of my customer's browser does not support iFrames (rather his Outlook does not). Without using iFrames, how can i display another page's content inside Html? Original iFrames insert looked as following:
<iframe src="http://mybox:8081/blah/report.jsp" width="1000" height="420">
<p>Your browser does not support iframes.</p>
</iframe>
Please advise. Thank you.
You cannot without using an iFrame.
Your options are even more limited because you're working with an email client. HTML in email clients are very finicky.
It seems you are using an email client, which definitely doesn't support iFrames, but for reference, you can do this with jQuery on a website.
$(document).ready(function() {
$(".yourSelector").load("/pages/pageyouwanttoloadhtmlof.html");
});
Please note that .load will strip out scripts in most cases (there are uses that won't), and also note that you cannot load content from different domains than yours. (There are ways around this with things like jsonP, but that gets quite complicated, and you pretty much still have to control both domains.
You can use a DIV to display it, another page content should set using DIV's inner html property

How could I hide the url of a site within an iframe?

I have a site that has an iframe linking to another site with the following example iframe code:
<html>
<body>
<iframe src="http://google.com" width="100%" height="600">
</iframe>
</body>
</html>
So, for the above example, how could I prevent visitors from finding the url: http://google.com ?
You can't. Suffice to browse the source code and see it. And even if you try to put this in an obfuscated javascript file which will dynamically set the src property of the iframe nothing can't be hidden from the Net tab in FireBug. So I would recommend you not wasting your time with this.
You can write e.g. PHP or Apache rewrite to fetch the page from backend server. This has very little CPU overhead.
You could nest an iframe in another site / page and point the iframe on your current page to that one.
This would obfuscate it to some degree but if someone is intent on finding the URL, chances are they will.

Show SVG files on Sharepoint 2007

I'm building a WSS site which has to show SVG files stored on WSS.
I'm trying to use <object> tag to show it and it doesn't show, however, if I use <embed> it works ok. Im'using IE8 and IE7
I've been reading and everyone tells IE prefers <Object> over <embed>, but in WSS it doesn't work this way.
To display the file I'm using a web content editor webpart with this code:
<object type="image/svg+xml" data="/samples/sample.svg"
name="owMain" width="400" height="150">
</object>
Any clue??
I've found that it's not actually necessary to embed SVG as an object.
If you use the SVGWeb JavaScript library, you can actually put your SVG into a normal Content Editor Web Part via the Source Editor, and manipulate the SVG elements via JavaScript.
The library can also work with a referenced SVG file as an object, but I haven't tried that option.
The library is hosted on code.google.com
You cannot add object tags to the html content of a page in WSS. The issue is that the object tag can be used in lots of very bad ways, so it is stripped out by the underlying engine.
You have found that the content editor webpart does not suffer from the same limitations.
The first step, if you haven't already, is to confirm that the HTML content in the response is as you expect (e.g. view source). If it isn't then you've found your issue. If it is, the next step might be to use a debugging proxy like Fiddler to confirm that all of the related requests are being made and handled as you expect. If they're not then you've found your issue (e.g. security). If they are then by the process of elimination you can safely conclude that either the markup or the browser is lacking.
Is it me or IE does not support SVG? Well, it kinda does but it is tricky and it's to draw, not to show svg files. ... If you open with FF can you see what you are expecting?
added
I made an svg draw in IE ... it's not the same, I know, but it's something that you can read and test: stackoverflow.com/questions/536676
I managed to do this on IE7/8 with the following Html:
<embed width="600" height="450" id="objMapView" src="http://XXXXXXXX/file.svgz"
type="image/svg+xml" name="objMapView" border="1"/>
It works Ok bur requires adobe's SVG Plugin