[geeklog-devel] Feature Request: ADMIN_list (2 requests)

Joe Mucchiello joe at ThrowingDice.com
Wed Aug 22 19:54:10 EDT 2007


More annoyances:

If you set have_menu to false and have_extras to true, the 
instructions do not display. If you set have_menu to true and 
have_extras to false, the instructions appear twice.

Probably the best fix is to remove the instruction dump at the end of 
the function:
     $retval .= COM_startBlock ($title, $help_url,
                                COM_getBlockTemplate ('_admin_block', 
'header'));
     if (!$has_extras) {
         $retval .= $text_arr['instructions'];  // eliminate this
     }
     $retval .= $admin_templates->finish($admin_templates->get_var('output'))
              . COM_endBlock (COM_getBlockTemplate ('_admin_block', 'footer'));

And move the set_var call out of the if ($has_menu)

     if ($text_arr['has_menu']) {
         # add text strings to template
         $admin_templates->set_var('lang_instructions', 
$text_arr['instructions']);

becomes

     $admin_templates->set_var('lang_instructions', $text_arr['instructions']);
     if ($text_arr['has_menu']) {
         # add text strings to template


----
Joe Mucchiello
Throwing Dice Games
http://www.throwingdice.com 




More information about the geeklog-devel mailing list