_GALLERY_INDEX_ errors in Debug log

Since upgrading to Zenphoto 1.5 my debug log is being flooded with the following message:

{3862365:Wed, 27 Jun 2018 04:53:27 GMT}
NOTICE: Use of undefined constant GALLERY_INDEX - assumed 'GALLERY_INDEX' in /home/bpskdk/public_html/zenphoto/zp-core/rewrite.php(100) : eval()'d code on line 1
eval called from rewriteHandler (rewrite.php [100])
from include (index.php [38])
from index.php [31]

My setup is as follows:

Zenphoto version 1.5 (Official build)   
Current locale setting: en_US.UTF8  
PHP version: 5.6.36
MySQLi version: 5.5.5

Comments

  • fretzl Administrator, Developer

    Look in your /zp-data/zenphoto.cfg.php file.
    You will see something like this around line 72:

    $conf['special_pages'] = array(
        'page'=>            array('define'=>'_PAGE_',   'rewrite'=>'page'),
        'search'=>          array('define'=>'_SEARCH_', 'rewrite'=>'_PAGE_/search'),
        'archive'=>         array('define'=>'_ARCHIVE_',    'rewrite'=>'_PAGE_/archive'),
        'tags'=>            array('define'=>'_TAGS_',   'rewrite'=>'_SEARCH_/tags')
    );
    

    You have to add one line so it looks like this:

    $conf['special_pages'] = array(
        'page'=>            array('define'=>'_PAGE_',   'rewrite'=>'page'),
        'search'=>          array('define'=>'_SEARCH_', 'rewrite'=>'_PAGE_/search'),
        'archive'=>         array('define'=>'_ARCHIVE_',    'rewrite'=>'_PAGE_/archive'),
        'tags'=>            array('define'=>'_TAGS_',   'rewrite'=>'_SEARCH_/tags'),
        'gallery'=>         array('define'=>'_GALLERY_INDEX_',  'rewrite'=>'_PAGE_/gallery')
    );
    
  • vincent3569 Member, Translator
  • fretzl Administrator, Developer

    Yes, but when you just upgrade the line is not added.
    At least, not on my local installs.

  • acrylian Administrator, Developer

    That's sounds like a bug then sadly…

  • My sincere apologies for not replying sooner.

    The update to the /zp-data/zenphoto.cfg.php file fixed the problem for me.

    Many thanks.

  • acrylian Administrator, Developer

    Thanks for the follow up. We'll also see to fix this for the next bugfix update.

Sign In or Register to comment.