forum.coppermine-gallery.net

Dev Board => cpg1.4 Testing/Bugs => cpg1.4 Testing/Bugs: FIXED/CLOSED => Topic started by: Nibbler on January 04, 2005, 04:38:45 am

Title: Database error messages error
Post by: Nibbler on January 04, 2005, 04:38:45 am
If I trigger a db error, all I am getting is a template error :

Code: [Select]
Template error
Failed to find block 'logout'(#(<!-- BEGIN logout -->)(.*?)(<!-- END logout -->)#s) in :

                        <!-- BEGIN register -->
        <a href="{REGISTER_TGT}" title="{REGISTER_TITLE}">{REGISTER_LNK}</a> ::
  <!-- END register -->  <!-- BEGIN faq -->
        <a href="{FAQ_TGT}" title="{FAQ_TITLE}">{FAQ_LNK}</a> ::
  <!-- END faq -->  <!-- BEGIN login -->
        <a href="{LOGIN_TGT}" title="{LOGIN_TITLE}">{LOGIN_LNK}</a>
  <!-- END login -->  

Anyone else experiencing this ?

Hmm, It may be plugin related....
Title: Re: Database error messages error
Post by: Casper on January 05, 2005, 06:25:10 pm
yes, I'm also getting it, in a bridged install (smf)
Title: Re: Database error messages error
Post by: Nibbler on January 13, 2005, 08:35:15 pm
Here's my analysis:

cpg_db_error() calls cpg_die() which calls pageheader() which calls theme_main_menu('sys_menu') which attempts to template_extract_block() a whole load of things from $template_sys_menu which are not there as they have already been extracted during the original call to pageheader, causing the error.

If you comment out pageheader($lang_cpg_die[$msg_code]); in cpg_die() then you will get the db error message although the page will of course look all wrong.

Suggestions for a fix welcome :)
Title: Re: Database error messages error
Post by: Joachim Müller on February 18, 2005, 08:47:50 am
afaik this has been addressed in a thread in the dev board as well (off limits for "regular" users).
@donnoman: has this issue been fixed?

Joachim
Title: Re: Database error messages error
Post by: donnoman on February 24, 2005, 10:48:36 pm
yes this was addressed with a fix from omnideveloper.

He made it so that both 'sys_menu' and 'sub_menu' are statics, and are returned if you call pageheader a second time.