RSSPaginator.php 547 B

1234567891011121314151617181920212223242526272829
  1. <?php
  2. // Un système de pagination beaucoup plus simple que Paginator
  3. // mais mieux adapté à nos besoins
  4. class RSSPaginator {
  5. private $items = array ();
  6. private $next = '';
  7. public function __construct ($items, $next) {
  8. $this->items = $items;
  9. $this->next = $next;
  10. }
  11. public function isEmpty () {
  12. return empty ($this->items);
  13. }
  14. public function items () {
  15. return $this->items;
  16. }
  17. public function render ($view, $getteur) {
  18. $view = APP_PATH . '/views/helpers/'.$view;
  19. if (file_exists ($view)) {
  20. include ($view);
  21. }
  22. }
  23. }