changeset 238 | a78537db2850 |
parent 227 | 0eca1498a77b |
parent 234 | d5dff8148dfe |
child 240 | f0149a27df5f |
231:b11a2f1353c0 | 238:a78537db2850 |
---|---|
840 $r = $db->fetchrow(); |
840 $r = $db->fetchrow(); |
841 $e = $db->sql_query('INSERT INTO ' . table_prefix.'page_text(page_id,namespace,page_text,char_tag) VALUES(\'' . $rb['page_id'] . '\',\'' . $rb['namespace'] . '\',\'' . $db->escape($r['page_text']) . '\',\'' . $r['char_tag'] . '\')'); if(!$e) return("An error occurred during the rollback operation.\nMySQL said: ".mysql_error()."\n\nSQL backtrace:\n".$db->sql_backtrace()); |
841 $e = $db->sql_query('INSERT INTO ' . table_prefix.'page_text(page_id,namespace,page_text,char_tag) VALUES(\'' . $rb['page_id'] . '\',\'' . $rb['namespace'] . '\',\'' . $db->escape($r['page_text']) . '\',\'' . $r['char_tag'] . '\')'); if(!$e) return("An error occurred during the rollback operation.\nMySQL said: ".mysql_error()."\n\nSQL backtrace:\n".$db->sql_backtrace()); |
842 return 'The page "' . $name . '" has been undeleted according to the log created at ' . $rb['date_string'] . '.'; |
842 return 'The page "' . $name . '" has been undeleted according to the log created at ' . $rb['date_string'] . '.'; |
843 break; |
843 break; |
844 case "reupload": |
844 case "reupload": |
845 if ( !$session->get_permissions('history_rollbacks_extra') ) |
845 if ( !$session->get_permissions('history_rollback_extra') ) |
846 { |
846 { |
847 return 'Administrative privileges are required for file rollbacks.'; |
847 return 'Administrative privileges are required for file rollbacks.'; |
848 } |
848 } |
849 $newtime = time(); |
849 $newtime = time(); |
850 $newdate = date('d M Y h:i a'); |
850 $newdate = date('d M Y h:i a'); |