chubbyk
chubbyk

Reputation: 6302

Get page content from client side (cross domain)

Is there a way to get page content (cross domain) with just usage of JS (or some other scripting language) from client side without usage of server side script ?

Upvotes: 0

Views: 451

Answers (2)

Shadow2531
Shadow2531

Reputation: 12170

If you have control of the source of both pages, you can use postMessage in one page to send markup to the other.

Upvotes: 1

Martin Jespersen
Martin Jespersen

Reputation: 26183

If it is a public page you can use YQL and make it deliver jsonp results in a script tag, but other than that we are talking XSS here, and that is a no-no.

Upvotes: 2

Related Questions