Oppaitime's version of Gazelle
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

revisionhistory.class.php 629B

12345678910111213141516171819202122232425
  1. <?
  2. class RevisionHistory {
  3. /**
  4. * Read the revision history of an artist or torrent page
  5. * @param string $Page artists or torrents
  6. * @param in $PageID
  7. * @return array
  8. */
  9. public static function get_revision_history($Page, $PageID) {
  10. $Table = ($Page == 'artists') ? 'wiki_artists' : 'wiki_torrents';
  11. $QueryID = G::$DB->get_query_id();
  12. G::$DB->query("
  13. SELECT
  14. RevisionID,
  15. Summary,
  16. Time,
  17. UserID
  18. FROM $Table
  19. WHERE PageID = $PageID
  20. ORDER BY RevisionID DESC");
  21. $Ret = G::$DB->to_array();
  22. G::$DB->set_query_id($QueryID);
  23. return $Ret;
  24. }
  25. }