[Easymod-cvs] easymod2/mods/easymod/includes admin_easymod.php.txt,1.33,1.34 mod_sql_body.tpl,1.4,1.
Status: Beta
Brought to you by:
wgeric
From: Markus P. <mar...@us...> - 2005-11-04 05:14:19
|
Update of /cvsroot/easymod/easymod2/mods/easymod/includes In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22538/mods/easymod/includes Modified Files: admin_easymod.php.txt mod_sql_body.tpl Log Message: revised implementation of the sql parser. Index: mod_sql_body.tpl =================================================================== RCS file: /cvsroot/easymod/easymod2/mods/easymod/includes/mod_sql_body.tpl,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** mod_sql_body.tpl 31 Oct 2005 17:57:15 -0000 1.4 --- mod_sql_body.tpl 4 Nov 2005 05:14:10 -0000 1.5 *************** *** 3,26 **** <p>{L_SQL_INTRO}</p> - <!-- BEGIN drop_warning --> <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline" align="center"> ! <tr> ! <th height="25" class="thHead" nowrap="nowrap">{L_URGENT_WARNING}</th> ! </tr> ! <tr> ! <td class="row1"><table border="0" cellpadding="3" cellspacing="1" width="100%"> ! <tr> ! <td align="center"> </td> ! </tr> ! <tr> ! <td width="100%" align="center"><span class="gen">{L_SQL_DROP_WARN}</span></td> ! </tr> ! <tr> ! <td align="center"> </td> ! </tr> ! </table> ! </td> ! </tr> </table> <br /> --- 3,26 ---- <p>{L_SQL_INTRO}</p> <!-- BEGIN drop_warning --> <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline" align="center"> ! <tr> ! <th height="25" class="thHead" nowrap="nowrap">{L_URGENT_WARNING}</th> ! </tr> ! <tr> ! <td class="row1"> ! <table border="0" cellpadding="3" cellspacing="1" width="100%"> ! <tr> ! <td align="center"> </td> ! </tr> ! <tr> ! <td width="100%" align="center"><span class="gen">{L_SQL_DROP_WARN}</span></td> ! </tr> ! <tr> ! <td align="center"> </td> ! </tr> ! </table> ! </td> ! </tr> </table> <br /> *************** *** 29,49 **** <!-- BEGIN msaccess --> <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline" align="center"> ! <tr> ! <th height="25" class="thHead" nowrap="nowrap">{L_NOTICE}</th> ! </tr> ! <tr> ! <td class="row1"><table border="0" cellpadding="3" cellspacing="1" width="100%"> ! <tr> ! <td align="center"> </td> ! </tr> ! <tr> ! <td width="100%" align="center"><span class="gen">{L_SQL_MSACCESS_WARN}</span></td> ! </tr> ! <tr> ! <td align="center"> </td> ! </tr> ! </table> ! </td> ! </tr> </table> <br /> --- 29,50 ---- <!-- BEGIN msaccess --> <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline" align="center"> ! <tr> ! <th height="25" class="thHead" nowrap="nowrap">{L_NOTICE}</th> ! </tr> ! <tr> ! <td class="row1"> ! <table border="0" cellpadding="3" cellspacing="1" width="100%"> ! <tr> ! <td align="center"> </td> ! </tr> ! <tr> ! <td width="100%" align="center"><span class="gen">{L_SQL_MSACCESS_WARN}</span></td> ! </tr> ! <tr> ! <td align="center"> </td> ! </tr> ! </table> ! </td> ! </tr> </table> <br /> *************** *** 52,79 **** <!-- BEGIN sql_error --> <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline" align="center"> ! <tr> ! <th height="25" class="thHead" nowrap="nowrap">{L_SQL_ERROR}</th> ! </tr> ! <tr> ! <td class="row1"><table border="0" cellpadding="3" cellspacing="1" width="100%"> ! <tr> ! <td align="center"> </td> ! </tr> ! <tr> ! <td width="100%" align="center"><div class="gen"><b>{L_SQL_HALTED}</b><br /> ! <br />{L_SQL_ERROR_EXPLAIN}<br /> ! <br /> ! {L_FAILED_LINE}:<br /> ! <table cellpadding="4" border="0"><tr><td><pre style="text-align:left;">{sql_error.LINE}</pre></td></tr></table> ! <br /> ! {L_SQL_ERROR}: {sql_error.ERROR_CODE}<br /> ! {sql_error.ERROR_MSG}</div></td> ! </tr> ! <tr> ! <td align="center"> </td> ! </tr> ! </table> ! </td> ! </tr> </table> <br /> --- 53,82 ---- <!-- BEGIN sql_error --> <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline" align="center"> ! <tr> ! <th height="25" class="thHead" nowrap="nowrap">{L_SQL_ERROR}</th> ! </tr> ! <tr> ! <td class="row1"> ! <table border="0" cellpadding="3" cellspacing="1" width="100%"> ! <tr> ! <td align="center"> </td> ! </tr> ! <tr> ! <td width="100%" align="center"><div class="gen"><b>{L_SQL_HALTED}</b><br /> ! <br />{L_SQL_ERROR_EXPLAIN}<br /> ! <br /> ! {L_FAILED_LINE}:<br /> ! <table cellpadding="4" border="0"><tr><td><pre style="text-align:left;">{sql_error.LINE}</pre></td></tr></table> ! <br /> ! {L_SQL_ERROR}: {sql_error.ERROR_CODE}<br /> ! {sql_error.ERROR_MSG}</div> ! </td> ! </tr> ! <tr> ! <td align="center"> </td> ! </tr> ! </table> ! </td> ! </tr> </table> <br /> *************** *** 82,185 **** <!-- BEGIN experimental --> <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline" align="center"> ! <tr> ! <th height="25" class="thHead" nowrap="nowrap">{L_NOTICE}</th> ! </tr> ! <tr> ! <td class="row1"><table border="0" cellpadding="3" cellspacing="1" width="100%"> ! <tr> ! <td align="center"> </td> ! </tr> ! <tr> ! <td width="100%" align="center"><span class="gen">{L_EXPERIMENTAL_EXPLAIN}</span></td> ! </tr> ! <tr> ! <td align="center"> </td> ! </tr> ! </table> ! </td> ! </tr> </table> <!-- END experimental --> ! <form method="post" action="{S_ACTION}"> <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline"> ! <tr> ! <th width="90%" class="thCornerL" height="25">{L_PSEUDO}</th> ! <th width="10%" height="25" class="thCornerR">{L_ALLOW}</th> ! </tr> ! <!-- BEGIN error --> ! <tr> ! <td class="row1" colspan="2"> ! <table border="0" cellpadding="3" cellspacing="1" width="100%"> ! <tr> ! <td align="center"> </td> ! </tr> ! <tr> ! <td width="100%" align="center"><span class="gen"> ! <b>{L_SQL_PROCESS_ERROR}:</b><br /> ! <b>{L_NO_SQL_PREFORMED}<br /> ! <br /> ! {L_FOLLOWING_ERROR}:<br /> ! <br /> ! {error.ERROR_MSG} ! </span></td> ! </tr> ! <tr> ! <td align="center"> </td> ! </tr> ! </table> ! </td> ! </tr> ! <!-- END error --> ! <!-- BEGIN no_sql --> ! <tr> ! <td class="row1" colspan="2"> ! <table border="0" cellpadding="3" cellspacing="1" width="100%"> ! <tr> ! <td align="center"> </td> ! </tr> ! <tr> ! <td width="100%" align="center"><span class="gen"> ! {L_NO_SQL} ! </span></td> ! </tr> ! <tr> ! <td align="center"> </td> ! </tr> ! </table> ! </td> ! </tr> ! <!-- END no_sql --> ! <!-- BEGIN sql_row --> ! <tr> ! <td width="90%" class="{sql_row.ROW_CLASS}"><pre>{sql_row.DISPLAY_SQL}</pre></td> ! <td width="10%" align="center" class="{sql_row.ROW_CLASS}"> ! {sql_row.HIDDEN_SQL} ! {sql_row.CHECK} ! </td> ! </tr> ! <!-- END sql_row --> ! <tr> ! <td class="catBottom" colspan="2" align="center" height="28"> ! {HIDDEN} ! <input type="hidden" name="mode" value="{MODE}" /> ! <input type="hidden" name="SQL_lines" value="{SQL_LINES}" /> ! <input type="hidden" name="themes" value="{THEMES}" /> ! <input type="hidden" name="languages" value="{LANGUAGES}" /> ! <input type="hidden" name="files" value="{FILES}" /> ! <input type="hidden" name="num_proc" value="{PROCESSED}" /> ! <input type="hidden" name="num_unproc" value="{UNPROCESSED}" /> ! <input type="hidden" name="install_file" value="{MOD_FILE}" /> ! <input type="hidden" name="install_path" value="{MOD_PATH}" /> ! <input type="hidden" name="password" value="{EM_PASS}" /> ! <input type="submit" name="post" class="mainoption" value="{L_COMPLETE}" /> ! </td> ! </tr> </table> ! <br /> </form> <br /> --- 85,227 ---- <!-- BEGIN experimental --> <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline" align="center"> ! <tr> ! <th height="25" class="thHead" nowrap="nowrap">{L_NOTICE}</th> ! </tr> ! <tr> ! <td class="row1"> ! <table border="0" cellpadding="3" cellspacing="1" width="100%"> ! <tr> ! <td align="center"> </td> ! </tr> ! <tr> ! <td width="100%" align="center"><span class="gen">{L_EXPERIMENTAL_EXPLAIN}</span></td> ! </tr> ! <tr> ! <td align="center"> </td> ! </tr> ! </table> ! </td> ! </tr> </table> + <br /> <!-- END experimental --> ! <!-- BEGIN warnings_block --> <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline"> ! <tr> ! <th height="25" class="thHead" nowrap="nowrap">{warnings_block.TITLE}</th> ! </tr> ! <tr> ! <td class="row1"> ! <table cellpadding="4" cellspacing="0" border="0" align="center"> ! <tr><td align="left"> ! <div class="genmed"><ol> ! <!-- BEGIN line --> ! <li style="margin-bottom:8px;">{warnings_block.line.TEXT}</li> ! <!-- END line --> ! </ol></div> ! </td></tr> ! </table> ! </td> ! </tr> ! </table> ! <br /> ! <!-- END warnings_block --> ! <form name="sqlform" method="post" action="{S_ACTION}"> ! <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline"> ! <tr> ! <th width="5%" height="25" class="thCornerL"> </th> ! <th width="90%" height="25" class="thTop">{L_PSEUDO}</th> ! <th width="5%" height="25" class="thCornerR">{L_ALLOW}</th> ! </tr> ! <!-- BEGIN error --> ! <tr> ! <td class="row1" colspan="3"> ! <table border="0" cellpadding="3" cellspacing="1" width="100%"> ! <tr> ! <td align="center"> </td> ! </tr> ! <tr> ! <td width="100%" align="center"><div class="gen"> ! <b>{L_SQL_PROCESS_ERROR}:</b><br /> ! {L_NO_SQL_PREFORMED}<br /> ! <br /> ! {L_FOLLOWING_ERROR}:<br /> ! <br /> ! {error.ERROR_MSG} ! </div></td> ! </tr> ! <tr> ! <td align="center"> </td> ! </tr> ! </table> ! </td> ! </tr> ! <!-- END error --> ! <!-- BEGIN no_sql --> ! <tr> ! <td class="row1" colspan="3"> ! <table border="0" cellpadding="3" cellspacing="1" width="100%"> ! <tr> ! <td align="center"> </td> ! </tr> ! <tr> ! <td width="100%" align="center"><span class="gen">{L_NO_SQL}</span></td> ! </tr> ! <tr> ! <td align="center"> </td> ! </tr> ! </table> ! </td> ! </tr> ! <!-- END no_sql --> ! <!-- BEGIN sql_row --> ! <tr> ! <td width="5%" align="center" class="{sql_row.ROW_CLASS}"><span class="genmed"> {sql_row.STMT_COUNT} </span></td> ! <td width="90%" class="{sql_row.ROW_CLASS}"><pre>{sql_row.DISPLAY_SQL}</pre></td> ! <td width="5%" align="center" class="{sql_row.ROW_CLASS}"> ! {sql_row.HIDDEN_SQL} ! {sql_row.CHECK} ! </td> ! </tr> ! <!-- END sql_row --> ! ! <tr> ! <td class="catBottom" colspan="3" align="center" height="28"> ! {HIDDEN} ! <input type="hidden" name="mode" value="{MODE}" /> ! <input type="hidden" name="SQL_lines" value="{SQL_LINES}" /> ! <input type="hidden" name="themes" value="{THEMES}" /> ! <input type="hidden" name="languages" value="{LANGUAGES}" /> ! <input type="hidden" name="files" value="{FILES}" /> ! <input type="hidden" name="num_proc" value="{PROCESSED}" /> ! <input type="hidden" name="num_unproc" value="{UNPROCESSED}" /> ! <input type="hidden" name="install_file" value="{MOD_FILE}" /> ! <input type="hidden" name="install_path" value="{MOD_PATH}" /> ! <input type="hidden" name="password" value="{EM_PASS}" /> ! <input type="submit" name="post" class="mainoption" value="{L_COMPLETE}" /> ! </td> ! </tr> </table> ! <!-- BEGIN sql_rows --> ! <table width="100%" cellspacing="0" cellpadding="0" border="0"> ! <tr> ! <td align="right"><span class="nav"><b><a href="javascript:marklist('sqlform', true);this.blur();">{L_MARK_ALL}</a> :: <a href="javascript:marklist('sqlform', false);this.blur();">{L_UNMARK_ALL}</a></b> </span></td> ! </tr> ! </table> ! <!-- END sql_rows --> </form> <br /> + <script language="javascript" type="text/javascript"><!-- + function marklist(formname, status) + { + for( i = 0; i < document.forms[formname].length; i++ ) + { + document.forms[formname].elements[i].checked = status; + } + } + //--></script> \ No newline at end of file Index: admin_easymod.php.txt =================================================================== RCS file: /cvsroot/easymod/easymod2/mods/easymod/includes/admin_easymod.php.txt,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** admin_easymod.php.txt 2 Nov 2005 12:58:07 -0000 1.33 --- admin_easymod.php.txt 4 Nov 2005 05:14:10 -0000 1.34 *************** *** 2832,2836 **** // load up any SQL commands into hidden fields as well ! for ($i=0; $i<count( $sql); $i++) { $line = ''; --- 2832,2836 ---- // load up any SQL commands into hidden fields as well ! for ($i=0; $i<count($sql); $i++) { $line = ''; *************** *** 2933,2993 **** ); ! ! /********************************************************************************\ ! // turn the psuedo mysql into SQL for this user's DB type ! include($phpbb_root_path . 'admin/em_includes/em_schema.' . $phpEx); $formatted_sql = array(); $error = ''; ! for ($i=0; $i<count($sql); $i++) { ! $return_sql = handle_db_alteration( $sql[$i], $error ); ! if ( $error != '') { ! $template->assign_block_vars( 'error', array('ERROR_MSG' => $error)); ! break; } ! for ($j=0; $j<count($return_sql); $j++) { ! $formatted_sql[] = $return_sql[$j]; ! } ! } ! \********************************************************************************/ ! // Load the new SQL Parser ! if( @file_exists($phpbb_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_sql_parser.' . $phpEx) ) ! { ! require($phpbb_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_sql_parser.' . $phpEx); ! } ! else ! { ! require($phpbb_root_path . 'language/lang_english/lang_sql_parser.' . $phpEx); ! } ! require($phpbb_root_path . 'includes/sql/sql_parser.' . $phpEx); ! // Instatiate the SQL Parser object. ! $sql_parser = new sql_parser(); ! // Parse and convert the SQL statements for this user's DB type. ! $result = $sql_parser->parse_stream(implode("\n", $sql), $table_prefix); ! $error = ''; ! $formatted_sql = array(); ! if( $result & SQL_PARSER_ERROR ) ! { ! $error = '<b>Error:</b><br />' . $sql_parser->error_message['message'] . '<br /><br /><b>SQL:</b><br />' . $sql_parser->sql_input[$sql_parser->sql_count]; ! $template->assign_block_vars('error', array('ERROR_MSG' => $error)); ! } ! if( $result & SQL_PARSER_WARNINGS ) ! { ! $warnings = $sql_parser->warnings; ! } ! for( $j = 0; $j < count($sql_parser->sql_output); $j++ ) ! { ! $formatted_sql[] = $sql_parser->sql_output[$j]; } - /********************************************************************************/ // print message if there is no SQL to worry about ! if (count($sql) == 0) { $template->assign_block_vars('no_sql', array()); --- 2933,3001 ---- ); ! // Parser SQL statements, if any $formatted_sql = array(); + $sql_warnings = array(); $error = ''; ! if( count($sql) > 0 ) { ! // Use the old SQL Parser for MS-Access, support for which has been dropped ! if( SQL_LAYER == 'msaccess' ) { ! // turn the psuedo mysql into SQL for this user's DB type ! require($phpbb_root_path . 'admin/em_includes/em_schema.' . $phpEx); ! for( $i = 0; $i < count($sql); $i++ ) ! { ! $return_sql = handle_db_alteration($sql[$i], $error); ! if (!empty($error)) ! { ! $template->assign_block_vars('error', array('ERROR_MSG' => $error)); ! break; ! } ! ! for( $j = 0; $j < count($return_sql); $j++ ) ! { ! $formatted_sql[] = $return_sql[$j]; ! } ! } } ! // Use the new SQL Parser to deal with any other SQL server ! else { ! // Load the new SQL Parser ! if( @file_exists($phpbb_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_sql_parser.' . $phpEx) ) ! { ! require($phpbb_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_sql_parser.' . $phpEx); ! } ! else ! { ! require($phpbb_root_path . 'language/lang_english/lang_sql_parser.' . $phpEx); ! } ! require($phpbb_root_path . 'includes/sql/sql_parser.' . $phpEx); ! // Instatiate the SQL Parser object. ! $sql_parser = new sql_parser(); ! // Parse and convert the SQL statements for this user's DB type. ! $result = $sql_parser->parse_stream(implode("\n", $sql), $table_prefix); ! if( $result & SQL_PARSER_ERROR ) ! { ! $error = '<b>Error:</b><br />' . $sql_parser->error_message['message'] . '<br /><br /><b>SQL:</b><br />' . $sql_parser->sql_input[$sql_parser->sql_count]; ! $template->assign_block_vars('error', array('ERROR_MSG' => $error)); ! } ! if( $result & SQL_PARSER_WARNINGS ) ! { ! $sql_warnings = $sql_parser->warnings; ! } ! for( $j = 0; $j < count($sql_parser->sql_output); $j++ ) ! { ! $formatted_sql[] = $sql_parser->sql_output[$j]; ! } ! } } // print message if there is no SQL to worry about ! else { $template->assign_block_vars('no_sql', array()); *************** *** 2996,3061 **** } ! // display the list of SQL to generate and give use the option to not run them; display warnings if needed $drop_warning = false; $steps = 0; ! for ($i=0; $i<count($formatted_sql); $i++) { ! // if there is an error, then skip this ! if ( $error != '') { ! break; } ! $row_class = ( !($i % 2) ) ? $theme['td_class1'] : $theme['td_class2']; ! // see if this is the warning about dropping columns in postgresql ! $split = explode(' ', $formatted_sql[$i]); ! $hidden_sql = ''; ! if ($split[0] == 'ABORTED:') { ! $formatted_sql[$i] = '<b>' . htmlspecialchars($formatted_sql[$i]) . ';</b>'; $hidden_sql = ''; ! $check = ''; ! } ! else ! { ! $formatted_sql[$i] = htmlspecialchars($formatted_sql[$i]) . ';'; ! $hidden_sql = '<input type="hidden" name="SQL' . $steps . '" value="' . htmlspecialchars($formatted_sql[$i]) . '" />'; ! $check = '<input type="checkbox" name="check_SQL' . $steps . '" checked="checked" />'; ! $steps++; ! } ! // see if there are any DROP's we should warn the user about; we only want to display the warning once ! if ((!$drop_warning) && ((strtoupper($split[0]) == 'DROP') || (strtoupper($split[3]) == 'DROP'))) ! { ! $template->assign_block_vars( 'drop_warning', array()); ! $template->assign_vars(array( ! 'L_SQL_DROP_WARN' => $lang['EM_sql_drop_warning'], ! 'L_URGENT_WARNING' => $lang['EM_urgent_warning']) ); - $drop_warning = true; } - - - $template->assign_block_vars( 'sql_row', array( - 'ROW_CLASS' => $row_class, - 'HIDDEN_SQL' => $hidden_sql, - 'CHECK' => $check, - 'DISPLAY_SQL' => $formatted_sql[$i]) - ); } $hidden .= '<input type="hidden" name="num_sql_steps" value="' . $steps . "\" />\n"; // if it's postgre or mssql, let them know I don't have things quite right yet! ! if (($error == '') && ((SQL_LAYER == 'mssql') || (SQL_LAYER == 'postgresql'))) ! { ! $link = 'http://area51.phpbb.com/phpBB/viewtopic.php?t='; ! $link .= (SQL_LAYER == 'postgresql') ? '15388' : '15389'; ! ! $template->assign_block_vars('experimental', array()); ! $template->assign_vars(array( ! 'L_EXPERIMENTAL_EXPLAIN' => sprintf($lang['EM_experimental_explain'], SQL_LAYER, $link)) ! ); ! } // if it's msaccess, let them know that we can't add defaults :( --- 3004,3086 ---- } ! // display the list of SQL to generate and give user the option to not run them; display warnings if needed $drop_warning = false; $steps = 0; ! // if there was an error, then simply skip this ! if (empty($error)) { ! // Display warnings generated by the SQL Parser, if any ! for( $i = 0; $i < count($sql_warnings); $i++ ) { ! $sql_warnings_count = count($sql_warnings); ! $template->assign_block_vars('warnings_block', array( ! 'TITLE' => sprintf($lang['EM_sql_warnings_reported'], $sql_warnings_count) ! )); ! for( $j = 0; $j < $sql_warnings_count; $j++ ) ! { ! $template->assign_block_vars('warnings_block.line', array( ! 'TEXT' => $sql_warnings[$j]['message'] ! )); ! } } ! // Show the mark/unmark commands ! $template->assign_block_vars('sql_rows', array()); ! for( $i = 0; $i < count($formatted_sql); $i++ ) { ! $row_class = ( !($i % 2) ) ? $theme['td_class1'] : $theme['td_class2']; ! ! // see if this is the warning about dropping columns in postgresql ! $split = explode(' ', $formatted_sql[$i]); $hidden_sql = ''; ! if ($split[0] == 'ABORTED:') ! { ! $formatted_sql[$i] = '<b>' . htmlspecialchars($formatted_sql[$i]) . ';</b>'; ! $hidden_sql = ''; ! $check = ''; ! } ! else ! { ! $formatted_sql[$i] = htmlspecialchars($formatted_sql[$i]) . ';'; ! $hidden_sql = '<input type="hidden" name="SQL' . $steps . '" value="' . htmlspecialchars($formatted_sql[$i]) . '" />'; ! $check = '<input type="checkbox" name="check_SQL' . $steps . '" checked="checked" />'; ! $steps++; ! } ! // see if there are any DROP's we should warn the user about; we only want to display the warning once ! if ((!$drop_warning) && ((strtoupper($split[0]) == 'DROP') || (strtoupper($split[3]) == 'DROP'))) ! { ! $template->assign_block_vars('drop_warning', array()); ! $template->assign_vars(array( ! 'L_SQL_DROP_WARN' => $lang['EM_sql_drop_warning'], ! 'L_URGENT_WARNING' => $lang['EM_urgent_warning']) ! ); ! $drop_warning = true; ! } ! ! $template->assign_block_vars('sql_row', array( ! 'ROW_CLASS' => $row_class, ! 'STMT_COUNT' => $i+1, ! 'HIDDEN_SQL' => $hidden_sql, ! 'CHECK' => $check, ! 'DISPLAY_SQL' => $formatted_sql[$i]) ); } } $hidden .= '<input type="hidden" name="num_sql_steps" value="' . $steps . "\" />\n"; // if it's postgre or mssql, let them know I don't have things quite right yet! ! // Commented out since the new SQL Parser should process them nicely ! // if (($error == '') && ((SQL_LAYER == 'mssql') || (SQL_LAYER == 'postgresql'))) ! // { ! // $link = 'http://area51.phpbb.com/phpBB/viewtopic.php?t='; ! // $link .= (SQL_LAYER == 'postgresql') ? '15388' : '15389'; ! // ! // $template->assign_block_vars('experimental', array()); ! // $template->assign_vars(array( ! // 'L_EXPERIMENTAL_EXPLAIN' => sprintf($lang['EM_experimental_explain'], SQL_LAYER, $link)) ! // ); ! // } // if it's msaccess, let them know that we can't add defaults :( *************** *** 3066,3070 **** } - // fill the template $template->assign_vars(array( --- 3091,3094 ---- *************** *** 3080,3083 **** --- 3104,3109 ---- 'L_COMPLETE' => $lang['EM_complete_install'], 'L_NOTICE' => $lang['EM_notice'], + 'L_MARK_ALL' => $lang['Mark_all'], + 'L_UNMARK_ALL' => $lang['Unmark_all'], 'L_SQL_PROCESS_ERROR' => $lang['EM_sql_process_error'], *************** *** 3186,3190 **** // display the list of SQL to generate and give use the option to not run them; display warnings if needed - $drop_warning = false; $steps = 0; for( $i = 0; $i < count($sql); $i++ ) --- 3212,3215 ---- |