|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2006-09-20 14:16 UTC] rrichards@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Dec 02 03:00:02 2025 UTC |
Description: ------------ Is it possible to add HTTP proxy support to DOM function? I couldn't see any references to this on the php site. We are currently having difficulties with a loadHTMLFile script when accessing remote servers external to our network. Reproduce code: --------------- $dom = new DomDocument (); $dom= DOMDocument::loadHTMLFile('http://www.php.net'); $title = $dom->getElementsByTagName("title"); print $title->item(0)->textContent; Expected result: ---------------- PHP: Hypertext Preprocessor Actual result: -------------- Warning: DOMDocument::loadHTMLFile(http://www.php.net) [function.DOMDocument-loadHTMLFile]: failed to open stream: Connection timed out in /web/test1.php on line 3 Warning: DOMDocument::loadHTMLFile() [function.DOMDocument-loadHTMLFile]: I/O warning : failed to load external entity "http://www.php.net" in /web/test1.php on line 3