#37081 : Make the include-errors mention faulty permissions
From: phpbugs at demomusic dot nu
Operating system: All
PHP version: 6CVS-2006-04-14 (CVS)
PHP Bug Type: Feature/Change Request
Bug description: Make the include-errors mention faulty permissions
Description:
------------
(I wanted to choose "All" for php-version but was not allowed this...)
This is a typical scenario when permissions are not correctly ets:
One can get annoyed with php/apache sometimes:
Code:
include_once('Mail.php');
include_once('Mail/mime.php');
Error:
Warning: include_once(Mail.php) [function.include-once]: failed to open
stream: Filen eller katalogen finns inte in
/home/motin/Dev/Pdev/trunk/proc/basicFunctions.inc.php on line 15
Warning: include_once() [function.include]: Failed opening 'Mail.php' for
inclusion (include_path='.:/opt/lampp/lib/php') in
/home/motin/Dev/Pdev/trunk/proc/basicFunctions.inc.php on line 15
The /opt/lampp/lib/php is chmodded 777 for diagnosis and apache is run as
nobody:
motin@laptop:~$ ls /opt/lampp/lib/php/Mail.php -l
-rwxrwxrwx 1 motin users 8066 2005-08-15 18:12
/opt/lampp/lib/php/Mail.php
motin@laptop:~$ sudo su nobody
Password:
sh-3.1$ ls /opt/lampp/lib/php/Mail.php -l
-rwxrwxrwx 1 motin users 8066 2005-08-15 18:12
/opt/lampp/lib/php/Mail.php
sh-3.1$
Obviously for an experienced programmer this is an permissions issue. PHP
beginners will though probably go nuts tried to figure this paradox out,
and is forced to go looking in the forums and the do***entation for a
solution.
Requested change is for either "Failed opening 'Mail.php' for inclusion"
to be changed to "Failed opening 'Mail.php' for inclusion (check
permissions)" or, better yet: change the common "failed to open stream" to
"failed to open stream (check permissions)" or similar.
Reproduce code:
---------------
include_once('Mail.php');
include_once('Mail/mime.php');
.... Not that relevant with reproduce-code here
Expected result:
----------------
.... Not relevant
Actual result:
--------------
.... Not relevant
--
Edit bug report at http://bugs.php.net/?id=37081&edit=1
--
Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=37081&r=trysnapshot44
Try a CVS snapshot (PHP 5.1): http://bugs.php.net/fix.php?id=37081&r=trysnapshot51
Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=37081&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=37081&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=37081&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=37081&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=37081&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=37081&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=37081&r=support
Expected behavior: http://bugs.php.net/fix.php?id=37081&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=37081&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=37081&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=37081&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=37081&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=37081&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=37081&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=37081&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=37081&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=37081&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=37081&r=mysqlcfg
|