Loading external content with jquery or iframe?

Posted by nailuenlue on Stack Overflow See other posts from Stack Overflow or by nailuenlue
Published on 2011-01-06T22:36:57Z Indexed on 2011/01/06 22:53 UTC
Read the original article Hit count: 132

Filed under:
|
|
|

Hiho,

There's an existing website that i need to include into another site which goes like this:

a.mysite.com

and i need to fetch content from this site in my

www.mysite.com

website...

As i need to access the content of the iframe the Same origin policy produces a problem here. What i did was to configure mod_proxy on Apache to proxy pass all requests from

www.mysite.com/a

to

a.mysite.com

This will work fine...but my problem is that im not sure what the best way would be to include those pages.

1. Idea

As the content of the iframe is a full featured site with a top navigation...left navigation etc....i would need to change the page template to only show the content box to be able to integrate that page in the iframe.

2. Idea

I could just load the DIV where the content lies through JQuery.load() and integrate it into my site.

What is the best way to accomplish such a task? How bad is both ideas from the SEO point of view?

© Stack Overflow or respective owner

Related posts about JavaScript

Related posts about jQuery