RE: [PHP] moved code to a new server

From: Date: Fri, 24 Oct 2008 22:50:42 +0000
Subject: RE: [PHP] moved code to a new server
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-282417@lists.php.net to get a copy of this message
I think I fixed it. The error said that the file script.js, line 4 of the code, could not be found: 4 <? require ("http://path/to/the/file/script.js")?> I changed the line to this and it now works: <? require ("script.js") ?> I wonder why on the old server it could find the file based on the full url while the new server cannot find the file with the full url. -----Original Message----- From: Mohamed Ainab [mailto:mohamed@ainab.com] Sent: Friday, October 24, 2008 3:34 PM To: Daniel P. Brown Cc: php php; Marc Fromm Subject: RE: [PHP] moved code to a new server would be very helpfull if you would post the code. ----------- http://ainab.com | http://somaliyrics.net -------- Original Message -------- Subject: [PHP] moved code to a new server From: "Daniel P. Brown" <daniel.brown@parasane.net> Date: Fri, October 24, 2008 3:25 pm To: "php php" <php-general@lists.php.net>, "Marc Fromm" <marc.fromm@wwu.edu> Forwarded to General, since this doesn't belong on DB. On Fri, Oct 24, 2008 at 6:18 PM, Marc Fromm <Marc.Fromm@wwu.edu> wrote: > We moved our website to a new linux server. The code was running on a different linux server. > Thus the OS environment is the same. > We are receiving this error: > [Fri Oct 24 14:53:37 2008] PHP Fatal error: require() [<a > href='function.require'>function.require</a>]: Failed opening required 'this > was a url to a .js file' (include_path='.:/usr/share/pear:/usr/share/php') in > /var/www/html/path to .php file on line 4 > > I'm not a php programmer thus I am in the dark. You don't have to be, you just have to read the error message. If you copied that verbatim, then 'this was a url to a .js file' exists on line 4 of .php in /var/www/html/path, and PHP failed to open it. Make sure the file exists exactly where PHP is looking for it, and that it's accessible and readable to and by the user as which the server is running when executing .php in /var/www/html/path, and that the target file can be found from that directory. -- </Daniel P. Brown> http://www.parasane.net/ [New Look] daniel.brown@parasane.net || danbrown@php.net -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

« previous php.general (#282417) next »