FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


Require_once error





socalhockeygal
Hello, I am new to the forum and do not have a whole lot of experience with scripting.

I was asked to manage the website for the company I work for. The website needed updating, in particular pricing for the products we sell.

The way I was taught to update the site was to select a product. At the bottom of each product page there is a link to "Update product".

Typically the first time I use the link, it asks me to log in, and then it takes me to an administrative page where I can change information for the product.

I was working on it all day, when towards the end of the day I received this error message once I finished updating a product:

Fatal error: require_once(): Failed opening required './Connections/ccgifts.php' (include_path='.:/usr/share/pear:/usr/share/php53/pear') in /webroot/c/r/creat031/primary/www/cms/index.php on line 1

It seems like it is telling me to add the include_path on line one of my index.php. And I have, but then I get error messages like this:

Parse error: syntax error, unexpected T_STRING in /webroot/c/r/creat031/primary/www/cms/index.php on line 1

Please help! Usually after clicking on updating the product it takes me to the main Administrative page on what seems to be the back end of the website. Now it just gives me error messages.

Thanks in advance for your help!
Marcuzzo
does the file "/webroot/c/r/creat031/primary/www/cms/Connections/ccgifts.php" exist?

php.net wrote:
Files are included based on the file path given or, if none is given, the include_path specified. If the file isn't found in the include_path, include will finally check in the calling script's own directory and the current working directory before failing. The include construct will emit a warning if it cannot find a file; this is different behavior from require, which will emit a fatal error.

If a path is defined whether absolute (starting with a drive letter or \ on Windows, or / on Unix/Linux systems) or relative to the current directory (starting with . or ..) the include_path will be ignored altogether. For example, if a filename begins with ../, the parser will look in the parent directory to find the requested file.


as for the unexpected T_STRING, I'm guessing that you have an issue with a broken string but I would need to see some code before I can be sure
Related topics
Help: SQL error after uploading new files(thread updated)
Error 404 ..... How to Hide ...
fantastico error
ERROR: Nameserver ns1.frihost.net is not authoritative
Custom error pages using .htaccess
error with cash mod
error
Error messages and php editing in a photo archive (fixed?)
Fatal Error: Can't Install Joomla!!
Include() and require_once() errors
SMF forum error?
fatal error in Joomla installation "index.php"
MySQL - Session error?
Display an error if there is no value in the database
Reply to topic    Frihost Forum Index -> Scripting -> Php and MySQL

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.