views:

296

answers:

5

my js file calls uses an xmlHttpRequest to display an rss feed. when i reference the java script within my html page, my browser renders an error: Permission denied. and therefore, my script is being blocked. i am not allowed to change the security settings and would i'd appreciate any work around tips. thanks!

A: 

Cross-origins call? You can't do that ( at least not directly e.g. need an extension/plugin etc.).

jldupont
+1  A: 

It's called the same origin policy. There's no easy workaround.

Reinis I.
+1  A: 

Simply put, XmlHttpRequest doesn't allow you to perform ajax calls across domains. Meaning, if you're website is mydomain.com, you can't use XHR to call out to pages (xml or otherwise) on someonelsesdomain.com.

There are work-arounds, typically using flash (less elegant) or webservice proxies (more elegant). Google "cross domain ajax calls" for more help.

WesleyJohnson
A: 

You need a proxy server... a utility that will allow access to foreign (in this case, on another server) material on your own server. Since (as the others mentioned) Browsers have security features enabled to prevent you from accessing content via AJAX on these foreign servers, a proxy will enable you access to this content locally.

Eddie Welker
A: 

this .net method was perfect and easy to implement: http://www.asp101.com/articles/john/megatokyo/dotnet.asp

MG