includes/pageutils.php
changeset 1037 61354f877e06
parent 1016 6d32d80b2192
child 1081 745200a9cc2a
equal deleted inserted replaced
1036:589e6e7e5243 1037:61354f877e06
   376             </form>
   376             </form>
   377             <script type="text/javascript">if ( !KILL_SWITCH ) { buildDiffList(); }</script>';
   377             <script type="text/javascript">if ( !KILL_SWITCH ) { buildDiffList(); }</script>';
   378     }
   378     }
   379     $db->free_result();
   379     $db->free_result();
   380     echo '<h3>' . $lang->get('history_heading_other') . '</h3>';
   380     echo '<h3>' . $lang->get('history_heading_other') . '</h3>';
   381     $q = 'SELECT log_id,time_id,action,date_string,page_id,namespace,author,edit_summary,minor_edit FROM ' . table_prefix.'logs WHERE log_type=\'page\' AND action!=\'edit\' AND page_id=\'' . $paths->page_id . '\' AND namespace=\'' . $paths->namespace . '\' ORDER BY time_id DESC;';
   381     $sql = 'SELECT log_id,time_id,action,date_string,page_id,namespace,author,edit_summary,minor_edit FROM ' . table_prefix.'logs WHERE log_type=\'page\' AND action!=\'edit\' AND page_id=\'' . $paths->page_id . '\' AND namespace=\'' . $paths->namespace . '\' ORDER BY time_id DESC;';
   382     if ( !$db->sql_query($q) )
   382     if ( !( $q = $db->sql_query($sql)) )
   383     {
   383     {
   384       $db->_die('The history data for the page "' . htmlspecialchars($paths->cpage['name']) . '" could not be selected.');
   384       $db->_die('The history data for the page "' . htmlspecialchars($paths->cpage['name']) . '" could not be selected.');
   385     }
   385     }
   386     if ( $db->numrows() < 1 )
   386     if ( $db->numrows() < 1 )
   387     {
   387     {
   398                 <th>' . $lang->get('history_col_action_taken') . '</th>
   398                 <th>' . $lang->get('history_col_action_taken') . '</th>
   399                 <th>' . $lang->get('history_col_extra') . '</th>
   399                 <th>' . $lang->get('history_col_extra') . '</th>
   400                 <th colspan="2"></th>
   400                 <th colspan="2"></th>
   401               </tr>';
   401               </tr>';
   402       $cls = 'row2';
   402       $cls = 'row2';
   403       while($r = $db->fetchrow()) {
   403       while($r = $db->fetchrow($q)) {
   404         
   404         
   405         if($cls == 'row2') $cls = 'row1';
   405         if($cls == 'row2') $cls = 'row1';
   406         else $cls = 'row2';
   406         else $cls = 'row2';
   407         
   407         
   408         echo '<tr>';
   408         echo '<tr>';