Zen Cart Logo
Forums / Customization from the Admin / "Fatal error" message - can;t save edited files

"Fatal error" message - can;t save edited files

Locked

Views: 3,561

Results 1 to 17 of 17
This thread is locked. New replies are disabled.
26 Jun 2010, 1:09 AM
#1
musicman77 avatar

musicman77

New Zenner

Join Date:
Jun 2010
Posts:
16
Plugin Contributions:
0

"Fatal error" message - can;t save edited files

Right now I am trying to move my files from /shop to the main index. In order to do this, I have to edit both configure.php files. I tried editing them, but everytime I click the "Save Changes" button after editing the files the page reloads to say

"File Saved
[a fatal error or timeout occurred while processing this directive]
Your file /home/bigezwi/public_html/includes/configure.php has been saved. "

However, I;ll check back on the files after and they'll actually be unedited, despite tjhe claim that the file was saved! Why doesn;'t the admin let me edit these files?

Thanks,
Dave

26 Jun 2010, 1:28 AM
#2
frank18 avatar

frank18

Deceased

Join Date:
Nov 2007
Location:
Sunny Coast, Australia
Posts:
3,427
Plugin Contributions:
2

Re: "Fatal error" message - can;t save edited files

Are you trying to edit your configure.php files using your file manager (server side)?

If so, this is not recommended.

You should edit these 2 files locally using a good editor.

Then set permissions to 644, upload the files to their appropriate locations on the server and then set permissions back to 444.

26 Jun 2010, 5:26 PM
#3
musicman77 avatar

musicman77

New Zenner

Join Date:
Jun 2010
Posts:
16
Plugin Contributions:
0

Re: "Fatal error" message - can;t save edited files

Thanks, Frank. This worked for redirecting zen cart to my homepage, but I then i was seeing was a blank page when I tried to access the admin page.

I looked in the admin configure file and found that I accidentally copied the other configure file. I copied dist-configure from the admin and renamed it configure.php, and now all I get is the "Hello. Thank you for loading Zen Cart™.You are seeing this page for one or more reasons:" notice .

26 Jun 2010, 8:27 PM
#4
musicman77 avatar

musicman77

New Zenner

Join Date:
Jun 2010
Posts:
16
Plugin Contributions:
0

Re: "Fatal error" message - can;t save edited files

can anyone help me with this? you can view my admin page at https://www.bigeasyincense.com/admin

thanks,
Dave

26 Jun 2010, 9:21 PM
#5
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: "Fatal error" message - can;t save edited files

Compare the files:
/includes/configure.php
/admin/includes/configure.php

It looks like you are missing the:
/admin/includes/configure.php

or that it is configured incorrectly ...

Or, you have renamed your /admin to another name and loaded another /admin directory to your site ...

26 Jun 2010, 11:45 PM
#6
bminister avatar

bminister

New Zenner

Join Date:
Jun 2010
Location:
London, UK
Posts:
27
Plugin Contributions:
0

Re: "Fatal error" message - can;t save edited files

You see:

"File Saved
[a fatal error or timeout occurred while processing this directive]
Your file /home/bigezwi/public_html/includes/configure.php has been saved. " because you need to choose at least 644 permission for the file. You can do it from your hosting CPanel - when you update the permissions click on "Edit". When you finish don't forget to return the file to 444.

26 Jun 2010, 11:46 PM
#7
bminister avatar

bminister

New Zenner

Join Date:
Jun 2010
Location:
London, UK
Posts:
27
Plugin Contributions:
0

Re: "Fatal error" message - can;t save edited files

http://www.bigeasyincense.com/admin/ - you see that page because your admin/includes/configure.php file has incorrect information. Update the path, save the file and check again.

27 Jun 2010, 7:34 PM
#8
musicman77 avatar

musicman77

New Zenner

Join Date:
Jun 2010
Posts:
16
Plugin Contributions:
0

Re: "Fatal error" message - can;t save edited files

Ajeh:

Compare the files:
/includes/configure.php
/admin/includes/configure.php

Are the two configure files identical?

27 Jun 2010, 8:02 PM
#9
musicman77 avatar

musicman77

New Zenner

Join Date:
Jun 2010
Posts:
16
Plugin Contributions:
0

Re: "Fatal error" message - can;t save edited files

The paths must be wrong. I don't understand why though. I am putting in three paths, "/" (for home) "/admin/", and "/home/bigezwi/public_html/cache" for the SQL cache, all of which seem to be the correct locations...

27 Jun 2010, 10:01 PM
#10
musicman77 avatar

musicman77

New Zenner

Join Date:
Jun 2010
Posts:
16
Plugin Contributions:
0

Re: "Fatal error" message - can;t save edited files

I just ran the Fix Cache Key to see if it could be a problem with the cache. There wasn't. All of the paths are right, too.

28 Jun 2010, 1:13 AM
#11
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: "Fatal error" message - can;t save edited files

The two files are not identical ...

If you want to post your files, from the server, without your username, password or /admin directory name (assuming you have changed that to another directory) we can look to see if there are any errors ...

28 Jun 2010, 7:17 AM
#12
musicman77 avatar

musicman77

New Zenner

Join Date:
Jun 2010
Posts:
16
Plugin Contributions:
0

Re: "Fatal error" message - can;t save edited files

Sure enough. Here's the admin config:

<?php
/**
 * dist-configure.php
 *
 * @package Configuration Settings
 * @package Admin
 * @copyright Copyright 2003-2007 Zen Cart Development Team
 * @copyright Portions Copyright 2003 osCommerce
 * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
 * @version $Id: dist-configure.php 6329 2007-05-16 15:36:56Z drbyte $
 * @private
 */

// Define the webserver and path parameters
// HTTP_SERVER is your Main webserver: eg-http://www.yourdomain.com
// HTTPS_SERVER is your Secure webserver: eg-https://www.yourdomain.com
// HTTP_CATALOG_SERVER is your Main webserver: eg-http://www.yourdomain.com
// HTTPS_CATALOG_SERVER is your Secure webserver: eg-https://www.yourdomain.com
/* 
 * URL's for your site will be built via:  
 *     HTTP_SERVER plus DIR_WS_ADMIN or
 *     HTTPS_SERVER plus DIR_WS_HTTPS_ADMIN or 
 *     HTTP_SERVER plus DIR_WS_CATALOG or 
 *     HTTPS_SERVER plus DIR_WS_HTTPS_CATALOG
 * ...depending on your system configuration settings
 *
 * If you desire your *entire* admin to be SSL-protected, make sure you use a "https:" URL for all 4 of the following:
 */
  define('HTTP_SERVER', 'http://localhost');
  define('HTTPS_SERVER', 'https://localhost');
  define('HTTP_CATALOG_SERVER', 'http://localhost');
  define('HTTPS_CATALOG_SERVER', 'https://localhost');

  // secure webserver for catalog module and/or admin areas?
  define('ENABLE_SSL_CATALOG', 'false');
  define('ENABLE_SSL_ADMIN', 'false');

// NOTE: be sure to leave the trailing '/' at the end of these lines if you make changes!

// * DIR_WS_* = Webserver directories (virtual/URL)
  // these paths are relative to top of your webspace ... (ie: under the public_html or httpdocs folder)
  define('DIR_WS_ADMIN', '/admin/');
  define('DIR_WS_CATALOG', '/');
  define('DIR_WS_HTTPS_ADMIN', '/admin/');
  define('DIR_WS_HTTPS_CATALOG', '/');

  define('DIR_WS_IMAGES', 'images/');
  define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');
  define('DIR_WS_CATALOG_IMAGES', HTTP_CATALOG_SERVER . DIR_WS_CATALOG . 'images/');
  define('DIR_WS_CATALOG_TEMPLATE', HTTP_CATALOG_SERVER . DIR_WS_CATALOG . 'includes/templates/');
  define('DIR_WS_INCLUDES', 'includes/');
  define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');
  define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
  define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
  define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
  define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
  define('DIR_WS_CATALOG_LANGUAGES', HTTP_CATALOG_SERVER . DIR_WS_CATALOG . 'includes/languages/');

// * DIR_FS_* = Filesystem directories (local/physical)
  //the following path is a COMPLETE path to your Zen Cart files. eg: /var/www/vhost/accountname/public_html/store/
  define('DIR_FS_ADMIN', '/admin/');
  define('DIR_FS_CATALOG', '/');

  define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');
  define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');
  define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');
  define('DIR_FS_CATALOG_TEMPLATES', DIR_FS_CATALOG . 'includes/templates/');
  define('DIR_FS_BACKUP', DIR_FS_ADMIN . 'backups/');
  define('DIR_FS_EMAIL_TEMPLATES', DIR_FS_CATALOG . 'email/');
  define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');

// define our database connection
  define('DB_TYPE', 'mysql');
  define('DB_PREFIX', 'zen_');
  define('DB_SERVER', 'localhost'); 
  define('DB_SERVER_USERNAME', 'root');
  define('DB_SERVER_PASSWORD', '');
  define('DB_DATABASE', '');
  define('USE_PCONNECT', 'false');
  define('STORE_SESSIONS', 'db'); 
  // use 'db' for best support, or '' for file-based storage

  // The next 2 "defines" are for SQL cache support.
  // For SQL_CACHE_METHOD, you can select from:  none, database, or file
  // If you choose "file", then you need to set the DIR_FS_SQL_CACHE to a directory where your apache 
  // or webserver user has write privileges (chmod 666 or 777). We recommend using the "cache" folder inside the Zen Cart folder
  // ie: /path/to/your/webspace/public_html/zen/cache   -- leave no trailing slash 
  define('SQL_CACHE_METHOD', 'none');
  define('DIR_FS_SQL_CACHE', '/home/bigezwi/public_html/cache');
?>

I also just changed the admin folder name. Now I am seeing
*
0 DB_ERROR_NOT_CONNECTED
in:
[select * from zen_project_version WHERE project_version_key = 'Zen-Cart Database' ]
If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you left no blank fields.*

28 Jun 2010, 12:42 PM
#13
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: "Fatal error" message - can;t save edited files

Compare that to the file on the server for:
/includes/configure.php

while different, it should help you fill in the proper information for the file, on the server, for:
/admin/includes/configure.php

28 Jun 2010, 6:56 PM
#14
musicman77 avatar

musicman77

New Zenner

Join Date:
Jun 2010
Posts:
16
Plugin Contributions:
0

Re: "Fatal error" message - can;t save edited files

I can't find any differences between these files.

Here is config

<?php
/**
 * @package Configuration Settings circa 1.3.9
 * @copyright Copyright 2003-2009 Zen Cart Development Team
 * @copyright Portions Copyright 2003 osCommerce
 * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
 * File Built by zc_install on 2010-05-14 06:40:53
 */


/*************** NOTE: This file is similar, but DIFFERENT from the "admin" version of configure.php. ***********/
/***************       The 2 files should be kept separate and not used to overwrite each other.      ***********/

// Define the webserver and path parameters
  // HTTP_SERVER is your Main webserver: eg-http://www.your_domain.com
  // HTTPS_SERVER is your Secure webserver: eg-https://www.your_domain.com
  define('HTTP_SERVER', 'http://bigeasyincense.com');
  define('HTTPS_SERVER', 'https://bigeasyincense.com');

  // Use secure webserver for checkout procedure?
  define('ENABLE_SSL', 'false');

// NOTE: be sure to leave the trailing '/' at the end of these lines if you make changes!
// * DIR_WS_* = Webserver directories (virtual/URL)
  // these paths are relative to top of your webspace ... (ie: under the public_html or httpdocs folder)
  define('DIR_WS_CATALOG', '/');
  define('DIR_WS_HTTPS_CATALOG', '/');

  define('DIR_WS_IMAGES', 'images/');
  define('DIR_WS_INCLUDES', 'includes/');
  define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
  define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
  define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
  define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
  define('DIR_WS_DOWNLOAD_PUBLIC', DIR_WS_CATALOG . 'pub/');
  define('DIR_WS_TEMPLATES', DIR_WS_INCLUDES . 'templates/');

  define('DIR_WS_PHPBB', '/');

// * DIR_FS_* = Filesystem directories (local/physical)
  //the following path is a COMPLETE path to your Zen Cart files. eg: /var/www/vhost/accountname/public_html/store/
  define('DIR_FS_CATALOG', '/home/bigezwi/public_html/');

  define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');
  define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');
  define('DIR_WS_UPLOADS', DIR_WS_IMAGES . 'uploads/');
  define('DIR_FS_UPLOADS', DIR_FS_CATALOG . DIR_WS_UPLOADS);
  define('DIR_FS_EMAIL_TEMPLATES', DIR_FS_CATALOG . 'email/');

// define our database connection
  define('DB_TYPE', 'mysql');
  define('DB_PREFIX', 'zen_');
  define('DB_SERVER', 'localhost');
  define('DB_SERVER_USERNAME', '');
  define('DB_SERVER_PASSWORD', '');
  define('DB_DATABASE', '');
  define('USE_PCONNECT', 'false');
  define('STORE_SESSIONS', 'db');
  // for STORE_SESSIONS, use 'db' for best support, or '' for file-based storage

  // The next 2 "defines" are for SQL cache support.
  // For SQL_CACHE_METHOD, you can select from:  none, database, or file
  // If you choose "file", then you need to set the DIR_FS_SQL_CACHE to a directory where your apache 
  // or webserver user has write privileges (chmod 666 or 777). We recommend using the "cache" folder inside the Zen Cart folder
  // ie: /path/to/your/webspace/public_html/zen/cache   -- leave no trailing slash  
  define('SQL_CACHE_METHOD', 'none'); 
  define('DIR_FS_SQL_CACHE', '/home/bigezwi/public_html/cache');

// EOF

admin config

<?php
/**
 * dist-configure.php
 *
 * @package Configuration Settings
 * @package Admin
 * @copyright Copyright 2003-2007 Zen Cart Development Team
 * @copyright Portions Copyright 2003 osCommerce
 * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
 * @version $Id: dist-configure.php 6329 2007-05-16 15:36:56Z drbyte $
 * @private
 */

// Define the webserver and path parameters
// HTTP_SERVER is your Main webserver: eg-http://www.yourdomain.com
// HTTPS_SERVER is your Secure webserver: eg-https://www.yourdomain.com
// HTTP_CATALOG_SERVER is your Main webserver: eg-http://www.yourdomain.com
// HTTPS_CATALOG_SERVER is your Secure webserver: eg-https://www.yourdomain.com
/* 
 * URL's for your site will be built via:  
 *     HTTP_SERVER plus DIR_WS_ADMIN or
 *     HTTPS_SERVER plus DIR_WS_HTTPS_ADMIN or 
 *     HTTP_SERVER plus DIR_WS_CATALOG or 
 *     HTTPS_SERVER plus DIR_WS_HTTPS_CATALOG
 * ...depending on your system configuration settings
 *
 * If you desire your *entire* admin to be SSL-protected, make sure you use a "https:" URL for all 4 of the following:
 */
  define('HTTP_SERVER', 'http://bigeasyincense.com');
  define('HTTPS_SERVER', 'https://bigeasyincense.com');
  define('HTTP_CATALOG_SERVER', 'http://bigeasyincense.com');
  define('HTTPS_CATALOG_SERVER', 'https://bigeasyincense.com');

  // secure webserver for catalog module and/or admin areas?
  define('ENABLE_SSL_CATALOG', 'false');
  define('ENABLE_SSL_ADMIN', 'false');

// NOTE: be sure to leave the trailing '/' at the end of these lines if you make changes!

// * DIR_WS_* = Webserver directories (virtual/URL)
  // these paths are relative to top of your webspace ... (ie: under the public_html or httpdocs folder)
  define('DIR_WS_ADMIN', '/admin/');
  define('DIR_WS_CATALOG', '/');
  define('DIR_WS_HTTPS_ADMIN', '/admin');
  define('DIR_WS_HTTPS_CATALOG', '/');

  define('DIR_WS_IMAGES', 'images/');
  define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');
  define('DIR_WS_CATALOG_IMAGES', HTTP_CATALOG_SERVER . DIR_WS_CATALOG . 'images/');
  define('DIR_WS_CATALOG_TEMPLATE', HTTP_CATALOG_SERVER . DIR_WS_CATALOG . 'includes/templates/');
  define('DIR_WS_INCLUDES', 'includes/');
  define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');
  define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
  define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
  define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
  define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
  define('DIR_WS_CATALOG_LANGUAGES', HTTP_CATALOG_SERVER . DIR_WS_CATALOG . 'includes/languages/');

// * DIR_FS_* = Filesystem directories (local/physical)
  //the following path is a COMPLETE path to your Zen Cart files. eg: /var/www/vhost/accountname/public_html/store/
  define('DIR_FS_ADMIN', '/home/bigezwi/public_html/admin/');
  define('DIR_FS_CATALOG', '/home/bigezwi/public_html/');

  define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');
  define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');
  define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');
  define('DIR_FS_CATALOG_TEMPLATES', DIR_FS_CATALOG . 'includes/templates/');
  define('DIR_FS_BACKUP', DIR_FS_ADMIN . 'backups/');
  define('DIR_FS_EMAIL_TEMPLATES', DIR_FS_CATALOG . 'email/');
  define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');

// define our database connection
  define('DB_TYPE', 'mysql');
  define('DB_PREFIX', 'zen_');
  define('DB_SERVER', 'localhost'); 
  define('DB_SERVER_USERNAME', 'root');
  define('DB_SERVER_PASSWORD', '');
  define('DB_DATABASE', '');
  define('USE_PCONNECT', 'false');
  define('STORE_SESSIONS', 'db'); 
  // use 'db' for best support, or '' for file-based storage

  // The next 2 "defines" are for SQL cache support.
  // For SQL_CACHE_METHOD, you can select from:  none, database, or file
  // If you choose "file", then you need to set the DIR_FS_SQL_CACHE to a directory where your apache 
  // or webserver user has write privileges (chmod 666 or 777). We recommend using the "cache" folder inside the Zen Cart folder
  // ie: /path/to/your/webspace/public_html/zen/cache   -- leave no trailing slash 
  define('SQL_CACHE_METHOD', 'none');
  define('DIR_FS_SQL_CACHE', '/home/bigezwi/public_html/cache');

?>

keep in mind that /admin/ is not the real name. Thank you very much for your help! I haven't been able to do any admin stuff in 3 days.

29 Jun 2010, 12:20 AM
#15
musicman77 avatar

musicman77

New Zenner

Join Date:
Jun 2010
Posts:
16
Plugin Contributions:
0

Re: "Fatal error" message - can;t save edited files

Since this is proving to be an issue, should I just move zen cart back to its original directory?

29 Jun 2010, 1:10 PM
#16
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: "Fatal error" message - can;t save edited files

Check the spelling of your new Admin directory and ensure that in the file:
/youradmindir/includes/configure.php

you have replaced all of the the:
/admin/

with your new directory:
/youradmindir/

NOTE: be sure you are checking the file on the server when reviewing your changes ...

29 Jun 2010, 4:11 PM
#17
musicman77 avatar

musicman77

New Zenner

Join Date:
Jun 2010
Posts:
16
Plugin Contributions:
0

Re: "Fatal error" message - can;t save edited files

Everything is correct. I don't know what else to do. Would it be wise to just reinstall Zen cart so everything will work again? I am very frustrated now and have no idea what to do next.