From: chcaron at nrcan dot gc dot ca Operating system: Solaris 5.8 PHP version: 5CVS-2007-10-12 (snap) PHP Bug Type: iPlanet related Bug description: file_get_contents() doesn't work anymore with FastCGI on iPlanet 6.1 SP8
Description: ------------ We have a site that calls file_get_contents() to retrieve data from another file in the same site and display it on the screen. It used to work correctly when we used the NSAPI PHP. Now that we went to FastCGI, it doesn't work anymore, except if "b.php" is sitting on another site, on the same server or another one. I could reproduce the bug with 4.4.7, 5.2.4 and the latest 5.2 snapshot (before you ask to try). PHP was compiled with the following: ./configure --prefix=/usr/local/php-5.2-snap --enable-fastcgi --disable-libxml --disable-dom --disable-simplexml --disable-xml --disable-xmlreader --disable-xmlwriter --without-pear It is Sun Java System Web Server (formely known as iPlanet, or SunONE) 6.1 SP8 with the Sun's FastCGI plugin (http://www.sun.com/download/products.xml?id=42d693c3). Reproduce code: --------------- a.php contains: <?php $url="http://servername/b.php"; $file = file_get_contents($url); echo $file; ?> b.php contains: <? print "Hello World!"; ?> Expected result: ---------------- While browsing to http://servername/a.php, I should see: Hello World! Actual result: -------------- Warning: file_get_contents(http://servername/b.php) [function.file-get-contents]: failed to open stream: HTTP request failed! in /www/servername/a.php on line 3 -- Edit bug report at http://bugs.php.net/?id=42953&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=42953&r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=42953&r=trysnapshot52 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=42953&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=42953&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=42953&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=42953&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=42953&r=needscript Try newer version: http://bugs.php.net/fix.php?id=42953&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=42953&r=support Expected behavior: http://bugs.php.net/fix.php?id=42953&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=42953&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=42953&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=42953&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=42953&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=42953&r=dst IIS Stability: http://bugs.php.net/fix.php?id=42953&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=42953&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=42953&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=42953&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=42953&r=mysqlcfg
