Page 1 of 1

configuring setup to display php include files

PostPosted: 16. November 2008 23:49
by trout1
I have Dreamweaver CS3 and have installed Xampp.

I have configured the DW testing server profile to point to C:\xampp\htdocs\

When I tell index.php to preview in browser, the file opens as expected except I get the following warning.

"Warning: include(z-sidenav.php) [function.include]: failed to open stream: No such file or directory in C:\xampp\htdocs\index.php on line 23"

So, I'm guessing my includes file are not mapped correctly.
I'd appreciate your suggestions for the correct configuration in order to properly display include files.

PostPosted: 17. November 2008 13:07
by glitzi85
Do you find this File in your Explorer?

C:\xampp\htdocs\z-sidenav.php

mfg glitzi

PostPosted: 17. November 2008 16:30
by trout1
glitzi85 wrote:Do you find this File in your Explorer?

C:\xampp\htdocs\z-sidenav.php

mfg glitzi


No, the file z-sidenav.php is not in the htdocs file. z-sidenav.php is resident with my other collateral files in the folder I have defined for the Dreamweaver assets for this site.

I am now wondering if I need to re-set the Dreamweaver site manager and make htdocs hold all of my php files?

PostPosted: 17. November 2008 17:05
by Nobbie
trout1 wrote:I am now wondering if I need to re-set the Dreamweaver site manager and make htdocs hold all of my php files?


Either do that - or edit php.ini and edit the value of include_path and add the path you choose in Dreamweaver for the include files.

Restart Apache after changing php.ini.

PostPosted: 18. November 2008 00:24
by trout1
Okay. It sort of makes sense to me now.

I just thought that the "include" or "require" php files should work the same way as my graphic s when previewing index.php in my browser.

I probably won't change the "ini" file as every website I do will have a different root folder. That would be a hassle to change the php.ini files everytime, don't you think?