Link to home
Start Free TrialLog in
Avatar of jammy-d0dger
jammy-d0dger

asked on

Current folder delimiter in PHP for include files

We recently setup a new server, Windows Server 2003 with IIS6.  We've now installed PHP 5 but our developer is having trouble deploying his application to it.  php_info.php responds ok and the site can conect to MySQL no problem, but there seems to be a problem using the ./ delimiter for include file paths.  This is what he said:

"I've managed to find the source of the error.  It was where I've included files using the delimeter ./ to mark the current directory (I think this is an issue in asp applications, not had this problem before).  I've removed all occurences of it in the front end of the site and it's working fine now, however I've used it quite a lot throughout the backend I've developed.  Is there a way to globally enable having paths start with ./ on the server?  That would be preferable rather than having to go through the entire cms and pick out the ./ delimeters..."

Any help, much appreciated.

ASKER CERTIFIED SOLUTION
Avatar of jopie916
jopie916

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of jammy-d0dger
jammy-d0dger

ASKER

Apologies for asking a simpleton question but the developer isn't here and I'm a .NET guy so not up on PHP at all....

Thanks for the suggestion but I've looked at his code that's uploaded and there's no .htaccess file anywhere in the website.  Is this a global file that I shoudl be able to find in the php folder somewhere along with php.ini or is this a site-specific file that should be included with every site?

Help appreciated...
Update: Developer says that he doesn't use specific path:

"I've not used a specific include folder, i just include them relatively from the script I'm using (eg ../../includedFile.php for a file two levels up).  Don't think it's a script thing as we've run the same code without these issues on a windows server before.  Has to be some wierd server configuration option we're missing...
"

Any ideas experts?
The problem has been solved.  Unfortunately nobody is sure how:

"I'd just commented out all the php and worked backwards uncommenting a block at a time, but it just kept working till I'd returned the file to it's previous state."

Maybe a screwed up FTP upload that 'resumed' rather than overwrote. Thanks for your input, I've split the points evenly, seems only fair.