wjwolf79 Posted May 25, 2006 Share Posted May 25, 2006 I have installed php on a Win2K3 server (IIS6) and it works fine until I try to use include() or require() (doesn't matter which one). I get the following errors:Warning: require([i]my_function[/i]) [function.require]: failed to open stream: No such file or directory in [i]my_file_path[/i] on line 3Fatal error: require() [function.require]: Failed opening required [i]my_function[/i]' (include_path='.;C:\php5\pear') in [i]my_file_path[/i] on line 3I noticed what the second one said about my include path, but that's not what my php.ini says my include path is. Here's my include path directive from my php.ini:include_path = ".;c:\php\includes"I've been trying to figure this out for about a week now (I tink a little more than that, actually). I cannot figure it out. I'm using the ISAPI setup, since I cannot get the CGI setup to run at all.Any assistence would be helpful, as I'm at my wit's end. Quote Link to comment Share on other sites More sharing options...
wildteen88 Posted May 25, 2006 Share Posted May 25, 2006 include and require only include files, It doesnt include functions.This is how you use the functions:[code]<?phpinclude 'filename.php';// ORrequire 'filename.php';?>[/code] Quote Link to comment Share on other sites More sharing options...
wjwolf79 Posted May 25, 2006 Author Share Posted May 25, 2006 well duh on that... my mistake typing that. I had the word function in my head because of that function.require line. They are .php files. They work fine on my local pc with IIS5, but not on the server with IIS6.I have set up php several times on an xp box with IIS5 with no problems both with CGI and ISAPI. IIS6 is very different from IIS5 (thank you, Microsoft), and I cannot get it to recognize any included files (besides putting the file in the same directory as the same file that's trying to include it). Even the phpinfo() function shows that it's thinking my config file is located at C:\Windows (and actually putting it there doesn't solve the problem). Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.