Get content of iframe from jquery
<p>everyone.
I created my page and inserted inside another page using IFrame. Now I'm trying to get whole text of that inserted page using pure javascript or jquery. Here's what I have now, but it doesn't work... </p>

<pre><code>    &lt;html&gt;
&lt;head&gt;
&lt;meta http-equiv="Content-Type" content="text/html; charset=UTF-8"&gt;
&lt;script type="text/javascript" src="jquery-1.5.1.js"&gt;&lt;/script&gt;   
&lt;script type="text/javascript"&gt;
function getFrameContents(){
   return $("#myframe").contents().find('body');
}
&lt;/script&gt;
&lt;/head&gt;

&lt;form&gt;
&lt;input type="button" value="CodingForums" onClick="window.alert(getFrameContents())" /&gt;
&lt;/form&gt;

&lt;iframe id='myframe' src="http://www.fxstreet.com/rates-charts/currency-rates/" width="100%" height="300"&gt;
  &lt;p&gt;Your browser does not support iframes.&lt;/p&gt;
&lt;/iframe&gt;

&lt;/html&gt;
</code></pre>

<p>I've read also that there is some policy about accessing pages from different server. How can I do it properly?</p>
