TORRENT_COMMENTS_PER_PAGE) { $DB->query(" SELECT COUNT(ID) FROM collages_comments WHERE CollageID = $CollageID AND ID <= $_GET[postid]"); list($PostNum) = $DB->next_record(); list($Page, $Limit) = Format::page_limit(TORRENT_COMMENTS_PER_PAGE, $PostNum); } else { list($Page, $Limit) = Format::page_limit(TORRENT_COMMENTS_PER_PAGE, $NumComments); } //Get the cache catalogue $CatalogueID = floor((TORRENT_COMMENTS_PER_PAGE * $Page - TORRENT_COMMENTS_PER_PAGE) / THREAD_CATALOGUE); $CatalogueLimit = $CatalogueID * THREAD_CATALOGUE . ', ' . THREAD_CATALOGUE; //---------- Get some data to start processing // Cache catalogue from which the page is selected, allows block caches and future ability to specify posts per page $Catalogue = Collages::get_comment_catalogue($CollageID, $CatalogueID); //This is a hybrid to reduce the catalogue down to the page elements: We use the page limit % catalogue $Thread = array_slice($Catalogue, ((TORRENT_COMMENTS_PER_PAGE * $Page - TORRENT_COMMENTS_PER_PAGE) % THREAD_CATALOGUE), TORRENT_COMMENTS_PER_PAGE, true); $DB->query(" SELECT Name FROM collages WHERE ID = '$CollageID'"); list($Name) = $DB->next_record(); // Start printing View::show_header("Comments for collage $Name", 'comments,bbcode'); ?>

Collages >

# - Quote - Edit - Delete Report
full_format($Body)?>
'collageid', 'InputID' => $CollageID, 'InputAction' => 'add_comment', 'TextareaCols' => 90)); } } ?>