- 0
Windows Phone 7/IE9 jQuery ajax
-
Recently Browsing 0 members
- No registered users viewing this page.
-
Similar Content
-
Microsoft introduces TypeScript 5.4: Explore the latest features and enhancements
By zikalify,
- microsoft
- typescript
- (and 4 more)
- 11 replies
- 2 views
-
JavaScript All-in-One For Dummies (worth $24) free in exchange for your email
By News Staff,
- ebook offer
- javascript
- (and 3 more)
- 0 replies
- 3 views
-
JavaScript from Frontend to Backend ($20.99 Value) FREE for your work email
By News Staff,
- ebook offer
- sponsored
- (and 3 more)
- 0 replies
- 3 views
-
Firefox vs Chrome: Mozilla finally manages to trump Google on Windows in a decade old test 1 2
By hellowalkman,
- 33 replies
- 4 views
-
Someone got ChatGPT to run on Windows 98 and other older Windows versions by making JavaGPT
By John Callaham,
- 9 replies
- 5 views
-
Question
divinatum
I'm trying to use the following code with jQuery on Windows Phone 7.5. Every time I try to make a ajax request for xml I get returned "Access is Denied" from the error handler. JSONP is not going to work in this scenario, unfortunately as the data I need is only in XML. I'm not sure how I'd go about fixing this issue. I should point out, that the code works fine on Chrome and Safari, but fails on Windows Phone 7.5 and IE9.
Javascript:
[/font][/color]
PHP Proxy to fetch XML from server that doesn't support cross site.
<?php
header('Content-type: text/xml');
header("Access-Control-Allow-Origin: *");
header("Access-Control-Allow-Methods: POST, GET, OPTIONS");
$intme = date('YmdHis');
$start = $_GET['ind'];
$url = "http://some.data.source/data.xml";
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
$output = curl_exec($ch);
curl_close($ch);
echo $output;
?>
[/CODE]
Link to comment
Share on other sites
2 answers to this question
Recommended Posts