Results 1 to 2 of 2
  1. #1
    Join Date
    May 2010
    Posts
    5
    Plugin Contributions
    0

    Default [Not a Bug] V1.39h Application_top error in code

    We have a fresh install of 1.39h and about every few days the Zen Install page will appear and stop the store. The admin panel is not affected, just the store. The first to times I ended up re-installing, but the third time I searched and found an error in the code. The application.php file has a config section that is checking for the configure.php in two locations on the server, but the second location does not contain a config file. I placed a copy of the configure.php in the folder and it now works. The folder it looks fore is includes/local/configure.php

    This is the bad code after * determine install status:


    CODE BELOW IS FROM LINE 141 DOWN.

    /**
    * determine install status
    */
    if (((!file_exists('includes/configure.php') && !file_exists('includes/local/configure.php')) || (DB_TYPE == '') || (!file_exists('includes/classes/db/' .DB_TYPE . '/query_factory.php')) || !file_exists('includes/autoload_func.php')) {
    $problemString = 'includes/configure.php file empty or file not found, OR wrong DB_TYPE set, OR cannot find includes/autoload_func.php which suggests paths are wrong or files were not uploaded correctly';
    require('includes/templates/template_default/templates/tpl_zc_install_suggested_default.php');
    header('location: zc_install/index.php');
    exit;
    }

  2. #2
    Join Date
    Jan 2004
    Posts
    66,364
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: V1.39h Application_top error in code

    Um, that's not a bug. It's specifically designed to look for that "local" file so that you can have simpler setups for local-server-testing vs your live-server operation.

    Whatever problems you're having are not caused by the lack of an /includes/local/configure.php file being present on your server.
    That file should not be present under normal production/server circumstances. And, if it is present, Zen Cart will use it. If it's not present, then it won't use it.

    You'll notice that the code already contains safeties to check for the file's existence before it even tries to load the file, so that protects its non-existence from causing any problems.

    As far as configure.php files are concerned, that section of code will only trigger the "need to install" message if BOTH configure.php files don't exist. So, your problem has nothing to do with an /includes/local/configure.php file. Rather, your problem would be that your MAIN configure.php file is not present or has permissions so low that it can't be read, or perhaps one of the other 2 conditions that line of code checks for are failing for some reason, all of which indicate that your main configuration setup is damaged and a reinstall is appropriate ... or a restore from backup to fix whatever's been corrupted since it was last working properly.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

 

 

Similar Threads

  1. [Code Error Bug]
    By bargincircus in forum Upgrading from 1.3.x to 1.3.9
    Replies: 1
    Last Post: 18 Nov 2010, 08:52 PM
  2. [Not a bug] customers.php code error
    By chadderuski in forum Bug Reports
    Replies: 1
    Last Post: 4 Jun 2010, 09:41 PM
  3. (Not a bug) Maybe missing a code?
    By travel124 in forum Bug Reports
    Replies: 1
    Last Post: 26 Apr 2008, 06:24 PM
  4. [Not a bug] Redemption code not sent on email.
    By Sawhorse in forum Bug Reports
    Replies: 6
    Last Post: 9 Apr 2008, 11:07 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR