views:

261

answers:

1

anyone know any workaround of using uframe to load external uri ? currently when i tried i get access denied on firefox

+1  A: 

You could use a server-side proxy page to grab external URLs and pull that in using ajax/XHR, then populate that.

$.get(
'proxy.php',
    {
        url:'http://www.sitename.com/'
    },
    function(data) {
        $('el').html( data );
    }

);

( assuming the .get invocation I have is in the correct form and you have jQuery loaded ).

And all proxy.php would do is check for $_GET['url'] and just echo the result of file_get_contents ( $_GET['url'] );

meder