includes/pageutils.php
changeset 323 58fa63f7f23b
parent 318 eec2dfd2f0a3
equal deleted inserted replaced
322:44b68ee8d2f5 323:58fa63f7f23b
  1449     if(!$e) $db->_die('The page text entry could not be deleted.');
  1449     if(!$e) $db->_die('The page text entry could not be deleted.');
  1450     $e = $db->sql_query('DELETE FROM ' . table_prefix.'pages WHERE urlname=\'' . $page_id . '\' AND namespace=\'' . $namespace . '\'');
  1450     $e = $db->sql_query('DELETE FROM ' . table_prefix.'pages WHERE urlname=\'' . $page_id . '\' AND namespace=\'' . $namespace . '\'');
  1451     if(!$e) $db->_die('The page entry could not be deleted.');
  1451     if(!$e) $db->_die('The page entry could not be deleted.');
  1452     $e = $db->sql_query('DELETE FROM ' . table_prefix.'files WHERE page_id=\'' . $page_id . '\'');
  1452     $e = $db->sql_query('DELETE FROM ' . table_prefix.'files WHERE page_id=\'' . $page_id . '\'');
  1453     if(!$e) $db->_die('The file entry could not be deleted.');
  1453     if(!$e) $db->_die('The file entry could not be deleted.');
       
  1454     $e = $db->sql_query('DELETE FROM ' . table_prefix.'acl WHERE page_id=\'' . $page_id . '\' AND namespace=\'' . $namespace . '\'');
       
  1455     if(!$e) $db->_die('The ACL entries associated with the page could not be deleted.');
  1454     return('This page has been deleted. Note that there is still a log of edits and actions in the database, and anyone with admin rights can raise this page from the dead unless the log is cleared. If the deleted file is an image, there may still be cached thumbnails of it in the cache/ directory, which is inaccessible to users.');
  1456     return('This page has been deleted. Note that there is still a log of edits and actions in the database, and anyone with admin rights can raise this page from the dead unless the log is cleared. If the deleted file is an image, there may still be cached thumbnails of it in the cache/ directory, which is inaccessible to users.');
  1455   }
  1457   }
  1456   
  1458   
  1457   /**
  1459   /**
  1458    * Increments the deletion votes for a page by 1, and adds the current username/IP to the list of users that have voted for the page to prevent dual-voting
  1460    * Increments the deletion votes for a page by 1, and adds the current username/IP to the list of users that have voted for the page to prevent dual-voting