ID: 36255 Updated by: [EMAIL PROTECTED] Reported By: tecklord at argocom dot cv dot ua -Status: Open +Status: Feedback Bug Type: URL related Operating System: Windows PHP Version: 4.4.2 New Comment:
Add error_reporting(E_ALL) and ini_set("display_errors", 1); in the beginning of test.php. Previous Comments: ------------------------------------------------------------------------ [2006-02-02 02:58:48] tecklord at argocom dot cv dot ua Description: ------------ There is a problem in use of fopen() function in a batch file when requesting remote URI. It`s impossible to fetch any data via HTTP even if allow_url_fopen is set to On in php.ini. With local files fopen() seems to work correctly. Ex. C:\PHP\php.exe -c "F:\php.ini" -f "F:\test.php" C:\PHP>php.exe -v PHP 4.4.2 (cgi-fcgi) (built: Jan 13 2006 13:53:43) Copyright (c) 1997-2006 The PHP Group Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies the same code works correctly with F:\backup_php>php.exe -v PHP 4.4.0 (cgi-fcgi) (built: Jul 11 2005 16:13:04) Copyright (c) 1997-2004 The PHP Group Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies Reproduce code: --------------- $url = "http://www.google.com"; $fp = fopen($url, 'r'); if ($fp): echo "yes"; fclose($fp); else: echo "No"; endif; Expected result: ---------------- "Yes" on the screen :) Actual result: -------------- There is no output at all, even with error_reporting = E_ALL in php.ini ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=36255&edit=1