[jQuery] Re: How to Get Div from IFrame

2009-11-20 Thread mkmanning
No. Cross domain also applies to different sub-domains, protocols, and
ports.

On Nov 20, 11:17 am, "webspee...@gmail.com" 
wrote:
> Outside of my domain, I can understand. I'll have to hold off for a
> bit then.
>
> Although the page will be remote, it will be accessible 
> byhttp://search.mydomain.com. Once it's accessible as a "sub domain',
> will I then have access to the page's elements?
>
> On Nov 16, 7:55 am, Liam Byrne  wrote:
>
>
>
> > You can't do this if the content of the iFrame is from a different
> > server / domain.
>
> > e.g. if it's not your content, then you can't get at it this way in
> > order to show it in your page; you can only display the iframe as the
> > owner intended.
>
> > L
>
> > webspee...@gmail.com wrote:
> > > When I try it, I get this error:
>
> > > Error: Permission denied for  to get property
> > > HTMLDocument.nodeType from :>.
> > > Source File:http://www..com/js/jquery/jquery.js
> > > Line: 2216
>
> > > Here is the line of JS being used.
>
> > > $("#eseSearchRight").html($('#searchFrame').contents().find
> > > ('.recordHeader').html());
>
> > > On Nov 5, 4:17 pm, Michel Belleville 
> > > wrote:
>
> > >> $('#canvas_frame').contents().find('#my_div');
>
> > >> To seek an id use "#", to seek inside a div use .contents().
>
> > >> Plus, refrain from using iframe, this is almost as bad as using frame and
> > >> almost never worth it. AJAX is good for you instead of shitty iframes.
>
> > >> Michel Belleville
>
> > >> 2009/11/5 Danish 
>
> > >>> I have a page with multiple Frames and Division, Now I am trying to
> > >>> extract one div having id="my_div" from iframe with Id =
> > >>> "canvas_frame" but I am fail to do so, Nor I am getting iframe neither
> > >>> Division in iframe.
> > >>> I tried all these selectors but always null returns although they are
> > >>> in page:
> > >>> 1) $("my_div");
> > >>> 2) $("my_div","canvas_frame");
> > >>> 3) $("canvas_frame",content.document);
> > >>> 4) $("canvas_frame");
> > >>> 5)  var $frame = $("canvas_frame",content.document);
> > >>>     var $div = $("my_div",$frame);
>
> > >>> I am able to do this with Pure JavaScript but due to some reasons I
> > >>> want to use JQuery Library, Any help will be highly appreciated.
> > >>> 
>
> > >>> No virus found in this incoming message.
> > >>> Checked by AVG -www.avg.com
> > >>> Version: 8.5.425 / Virus Database: 270.14.63/2500 - Release Date: 
> > >>> 11/13/09 07:54:00


[jQuery] Re: How to Get Div from IFrame

2009-11-20 Thread webspee...@gmail.com
Outside of my domain, I can understand. I'll have to hold off for a
bit then.

Although the page will be remote, it will be accessible by
http://search.mydomain.com. Once it's accessible as a "sub domain',
will I then have access to the page's elements?

On Nov 16, 7:55 am, Liam Byrne  wrote:
> You can't do this if the content of the iFrame is from a different
> server / domain.
>
> e.g. if it's not your content, then you can't get at it this way in
> order to show it in your page; you can only display the iframe as the
> owner intended.
>
> L
>
>
>
> webspee...@gmail.com wrote:
> > When I try it, I get this error:
>
> > Error: Permission denied for  to get property
> > HTMLDocument.nodeType from :>.
> > Source File:http://www..com/js/jquery/jquery.js
> > Line: 2216
>
> > Here is the line of JS being used.
>
> > $("#eseSearchRight").html($('#searchFrame').contents().find
> > ('.recordHeader').html());
>
> > On Nov 5, 4:17 pm, Michel Belleville 
> > wrote:
>
> >> $('#canvas_frame').contents().find('#my_div');
>
> >> To seek an id use "#", to seek inside a div use .contents().
>
> >> Plus, refrain from using iframe, this is almost as bad as using frame and
> >> almost never worth it. AJAX is good for you instead of shitty iframes.
>
> >> Michel Belleville
>
> >> 2009/11/5 Danish 
>
> >>> I have a page with multiple Frames and Division, Now I am trying to
> >>> extract one div having id="my_div" from iframe with Id =
> >>> "canvas_frame" but I am fail to do so, Nor I am getting iframe neither
> >>> Division in iframe.
> >>> I tried all these selectors but always null returns although they are
> >>> in page:
> >>> 1) $("my_div");
> >>> 2) $("my_div","canvas_frame");
> >>> 3) $("canvas_frame",content.document);
> >>> 4) $("canvas_frame");
> >>> 5)  var $frame = $("canvas_frame",content.document);
> >>>     var $div = $("my_div",$frame);
>
> >>> I am able to do this with Pure JavaScript but due to some reasons I
> >>> want to use JQuery Library, Any help will be highly appreciated.
> >>> 
>
> >>> No virus found in this incoming message.
> >>> Checked by AVG -www.avg.com
> >>> Version: 8.5.425 / Virus Database: 270.14.63/2500 - Release Date: 
> >>> 11/13/09 07:54:00


Re: [jQuery] Re: How to Get Div from IFrame

2009-11-16 Thread Liam Byrne
You can't do this if the content of the iFrame is from a different 
server / domain.


e.g. if it's not your content, then you can't get at it this way in 
order to show it in your page; you can only display the iframe as the 
owner intended.


L

webspee...@gmail.com wrote:

When I try it, I get this error:

Error: Permission denied for  to get property
HTMLDocument.nodeType from :>.
Source File: http://www..com/js/jquery/jquery.js
Line: 2216

Here is the line of JS being used.

$("#eseSearchRight").html($('#searchFrame').contents().find
('.recordHeader').html());



On Nov 5, 4:17 pm, Michel Belleville 
wrote:
  

$('#canvas_frame').contents().find('#my_div');

To seek an id use "#", to seek inside a div use .contents().

Plus, refrain from using iframe, this is almost as bad as using frame and
almost never worth it. AJAX is good for you instead of shitty iframes.

Michel Belleville

2009/11/5 Danish 





I have a page with multiple Frames and Division, Now I am trying to
extract one div having id="my_div" from iframe with Id =
"canvas_frame" but I am fail to do so, Nor I am getting iframe neither
Division in iframe.
I tried all these selectors but always null returns although they are
in page:
1) $("my_div");
2) $("my_div","canvas_frame");
3) $("canvas_frame",content.document);
4) $("canvas_frame");
5)  var $frame = $("canvas_frame",content.document);
var $div = $("my_div",$frame);
  
I am able to do this with Pure JavaScript but due to some reasons I

want to use JQuery Library, Any help will be highly appreciated.



No virus found in this incoming message.
Checked by AVG - www.avg.com 
Version: 8.5.425 / Virus Database: 270.14.63/2500 - Release Date: 11/13/09 07:54:00


  




[jQuery] Re: How to Get Div from IFrame

2009-11-13 Thread webspee...@gmail.com
When I try it, I get this error:

Error: Permission denied for  to get property
HTMLDocument.nodeType from :>.
Source File: http://www..com/js/jquery/jquery.js
Line: 2216

Here is the line of JS being used.

$("#eseSearchRight").html($('#searchFrame').contents().find
('.recordHeader').html());



On Nov 5, 4:17 pm, Michel Belleville 
wrote:
> $('#canvas_frame').contents().find('#my_div');
>
> To seek an id use "#", to seek inside a div use .contents().
>
> Plus, refrain from using iframe, this is almost as bad as using frame and
> almost never worth it. AJAX is good for you instead of shitty iframes.
>
> Michel Belleville
>
> 2009/11/5 Danish 
>
>
>
> > I have a page with multiple Frames and Division, Now I am trying to
> > extract one div having id="my_div" from iframe with Id =
> > "canvas_frame" but I am fail to do so, Nor I am getting iframe neither
> > Division in iframe.
> > I tried all these selectors but always null returns although they are
> > in page:
> > 1) $("my_div");
> > 2) $("my_div","canvas_frame");
> > 3) $("canvas_frame",content.document);
> > 4) $("canvas_frame");
> > 5)  var $frame = $("canvas_frame",content.document);
> >     var $div = $("my_div",$frame);
>
> > I am able to do this with Pure JavaScript but due to some reasons I
> > want to use JQuery Library, Any help will be highly appreciated.


[jQuery] Re: How to Get Div from IFrame

2009-11-13 Thread webspee...@gmail.com
I am in a similar situation and I don't want to use the iFrame, but
how do you use jQuery to do the following.

I have a page on my server and I want to display, say, www.google.com
in a portion of my page. With an iFrame, I simply set the src of the
iFrame. I've tried using jQuery to do the same but it won't work.

What I'm doing is this. I have a "search page" residing on another
site entirely and I'm going to be displaying that page on my page. In
the end it will be in the same domain but I'm trying to get a jump on
development.

What I need is to be able to manipulate the elements from the returned
page from my "parent page".

Any ideas?

On Nov 5, 4:17 pm, Michel Belleville 
wrote:
> $('#canvas_frame').contents().find('#my_div');
>
> To seek an id use "#", to seek inside a div use .contents().
>
> Plus, refrain from using iframe, this is almost as bad as using frame and
> almost never worth it. AJAX is good for you instead of shitty iframes.
>
> Michel Belleville
>
> 2009/11/5 Danish 
>
>
>
> > I have a page with multiple Frames and Division, Now I am trying to
> > extract one div having id="my_div" from iframe with Id =
> > "canvas_frame" but I am fail to do so, Nor I am getting iframe neither
> > Division in iframe.
> > I tried all these selectors but always null returns although they are
> > in page:
> > 1) $("my_div");
> > 2) $("my_div","canvas_frame");
> > 3) $("canvas_frame",content.document);
> > 4) $("canvas_frame");
> > 5)  var $frame = $("canvas_frame",content.document);
> >     var $div = $("my_div",$frame);
>
> > I am able to do this with Pure JavaScript but due to some reasons I
> > want to use JQuery Library, Any help will be highly appreciated.