#21674 [Opn]: Warning: main(lang.php) [function.main]: failed to create stream: No such file
| From: | wez@php.net | Date: | Fri, 17 Jan 2003 19:50:23 +0000 |
| Subject: | #21674 [Opn]: Warning: main(lang.php) [function.main]: failed to create stream: No such file | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-30381@lists.php.net to get a copy of this message | ||
ID: 21674
Updated by: wez@php.net
Reported By: moderator@blackpeeps.com
Status: Open
Bug Type: *URL Functions
Operating System: Cobalt RAQ4 Apache/Linux
PHP Version: 4.3.0
New Comment:
Can you do the same for the config.php file.
(and look to see if you have some .htaccess file in there too that
might be changing PHP settings)
Previous Comments:
------------------------------------------------------------------------
[2003-01-17 13:36:52] moderator@blackpeeps.com
Here are the results to your request.
string(14) ".:/usr/lib/php"
Warning: main(lang.php) [function.main]: failed to create stream: No
such file or directory in /home/sites/site2/web/IV/config.php on line
97
Warning: main() [function.main]: Failed opening 'lang.php' for
inclusion (include_path='') in /home/sites/site2/web/IV/config.php on
line 97
Warning: main(extras.php) [function.main]: failed to create stream: No
such file or directory in /home/sites/site2/web/IV/config.php on line
98
Warning: main() [function.main]: Failed opening 'extras.php' for
inclusion (include_path='') in /home/sites/site2/web/IV/config.php on
line 98
Hello - Testing PHP 4.3.0 bug# 21674// End - Copy and Save this code as
phpbug21674.php
------------------------------------------------------------------------
[2003-01-17 13:03:35] wez@php.net
add:
var_dump(ini_get('include_path'));
to the line before the require_once in the phpbug21674.php script and
paste the output here.
------------------------------------------------------------------------
[2003-01-17 12:59:28] moderator@blackpeeps.com
This is what my phpinfo() says
include_path .:/usr/lib/php
------------------------------------------------------------------------
[2003-01-17 12:48:12] wez@php.net
It works fine here...
Is your include_path still '' ?
You *must* have '.' in your include path for relative includes to work;
have you tried that?
------------------------------------------------------------------------
[2003-01-17 12:27:02] moderator@blackpeeps.com
Test this code if you will:
// Start- Copy and Save this code as phpbug21674.php in a path folder
name "site3"
<?
// PHP BUG# 21674
// This script must be saved to Docs root path of virtual domain-A
// To debug.. change the path to the path on your test server
require_once ("/home/sites/site2/config.php");
echo "Hello - Testing PHP 4.3.0 bug# 21674<br>";
?>
// End - Copy and Save this code as phpbug21674.php
// Begin - Copy and Save this code as config.php in a path folder name
"site2"
<?
include ('extras.php');
?>
// End - Copy and Save this code as config.php
// Begin - Copy and Save this code as extras.php in a path folder name
"site2"
<?
// -- field definitions --
$extra=array(); // leave this line alone
$extra[info1][name]="Alias Name/Nickname";
$extra[info1][type]="text";
$extra[info2][name]="Your Gender";
$extra[info2][type]=array("Female","Male",);
$extra[info3][name]="Relationship Status";
$extra[info3][type]=array("Single","Single-Looking for
Couples","Couple-Looking for
Singles","Dating","Involved/Partner","Involved-Seeking New
Friends","Married","Married-Seeking Discreet
Friend","Engaged","Divorced","Widowed","Player","Just
looking for
friend","Just Looking for Sex Partner","Undecided");
$extra[info4][name]="Sexual Orientation";
$extra[info4][type]=array("Heterosexual","Gay","Lesbian","BiSexual","BiCurious","Rather
Not Say");
// do not edit past this line
$extras = array();
for ($i=0; $i < 21; $i++)
{ $marker = "info".$i; // print $marker."<br>"; // debug
if (strlen($extra[$marker][name]) > 1)
$extras[]=$marker;
}
// in general, to display extra variable values, use
$extra[infox][value]
?>
Now execute php21674.php to reproduce errors.
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/21674
--
Edit this bug report at http://bugs.php.net/?id=21674&edit=1