you should write San Francisco to Page. there is nothing wrong. wrong thing is sandbox itself. If you write San Francisco to page it gives you that url:
/w/api.php?action=parse&format=json&page=San%20Francisco
add en.wikipedia.org to it and go to page. See everything is fine.Sandbox gives you error cause it programmed wrong basically.
if you want that page as HTML:
<?php
$ip_data = json_decode(file_get_contents("http://en.wikipedia.org/w/api.php?action=parse&format=json&page=Los%20Angeles"), true);
?>
<html>
<body>
<?php print_r($ip_data['parse']['text']['*']) ?>
</body>
</html>