PHP5 and IIS on win2003 not working as expected.

Forum for you who has PHP installation issues

Moderators: macek, egami, gesf

zupperman74
New php-forum User
New php-forum User
Posts: 2
Joined: Sun Jun 12, 2011 1:46 am

PHP5 and IIS on win2003 not working as expected.

Postby zupperman74 » Sun Jun 12, 2011 1:57 am

Hi guys, Is a week that I'm trying to make PHP runs on a win2003 server.
I've followed all the istructions, tutorials, original istructions but I can't resolve a big (and that make all unusefull) problem.
Inclusion of other scripts.
If in a script there is a :

require_once(./admin.php)

it doesn't runs ok.
and i get an error:

PHP Warning: require_once(./admin.php): failed to open stream: No such file or directory in C:\Inetpub\wwwroot\heels\wp\wp-admin\plugins.php on line 10 PHP Fatal error: require_once(): Failed opening required './admin.php' (include_path='.;c:\php\includes') in C:\Inetpub\wwwroot\heels\wp\wp-admin\plugins.php on line 10

if I change it to:

require_once(admin.php)

it runs ok.
So is not a rights problem.
I've found tons of pople with the same problem but without solution.
The solution could be to change all the include but I can't do it for every script (think about at wpress or phpmyadmin) every time I make an upgrade.... or simply I add a plugin.
Any idea how to solve it? I'm pretty desperate on that! :help:

johnj
php-forum Super User
php-forum Super User
Posts: 1805
Joined: Thu Mar 10, 2011 5:07 pm

Re: PHP5 and IIS on win2003 not working as expected.

Postby johnj » Sun Jun 12, 2011 7:45 am

write a one time php script whose job is to read all the files (that you need to change...maybe one or more directories) and change require_once './admin.php' to require_once 'admin.php'.

zupperman74
New php-forum User
New php-forum User
Posts: 2
Joined: Sun Jun 12, 2011 1:46 am

Re: PHP5 and IIS on win2003 not working as expected.

Postby zupperman74 » Sun Jun 12, 2011 7:52 am

johnj wrote:write a one time php script whose job is to read all the files (that you need to change...maybe one or more directories) and change require_once './admin.php' to require_once 'admin.php'.



yes... but at the next sotware upgrade?
Is not the definitive solution.... must be a trick to solve the problem.
The tsrange fact is that "./filetoinclude.php" should be equivalent to "filetoinclude.php" but is not.

johnj
php-forum Super User
php-forum Super User
Posts: 1805
Joined: Thu Mar 10, 2011 5:07 pm

Re: PHP5 and IIS on win2003 not working as expected.

Postby johnj » Sun Jun 12, 2011 11:19 pm

...yes... but at the next sotware upgrade?....


Why? What is stopping you from doing it now?


Return to “PHP Installation”

Who is online

Users browsing this forum: No registered users and 1 guest