Proxying is a technique which enables the cross domain loading of data (not necessary for json data types)

The following is a simple PHP example (but a completely open one) be sure to define the path to your proxy as a global variable on the page

 var proxy = "/cgi-bin/proxy.php?";
 

or define your urls in terms of your proxy var proxypath = "/cgi-bin/proxy.php?"; var url = proxypath+"url="+datasourceurl; You can and probably should restrict the values allowed for the url, i $_GET['url'] unless you are building a gateway or similar, use at your own risk.

proxy.php src:
0 ){
    curl_setopt($ch, CURLOPT_POSTFIELDS, $post_data);
}
$response = curl_exec($ch);     
if (curl_errno($ch)) {
    print curl_error($ch);
} else {
    curl_close($ch);
    print $response;
}
?>

The above proxy script is fully open, and there are people who will tell you (if you have a rather targeted use like always getting from google or similar single source you might want to change it to test $_GET['url'] variable to see if the script is being called for your purpose