diff --git a/base.php b/base.php index 654af50..dbf8d55 100644 --- a/base.php +++ b/base.php @@ -413,7 +413,8 @@ class PageBookDetail extends Page { public function InitializeContent () { - $this->title = "Book"; + $book = Book::getBookById ($this->idGet); + $this->title = $book->title; } } diff --git a/book.php b/book.php index 2e6112a..20e4dda 100644 --- a/book.php +++ b/book.php @@ -89,6 +89,19 @@ class Book extends Base { return self::ALL_BOOKS_ID.":letter:".$startingLetter; } + public function getUri () { + return "?page=".parent::PAGE_BOOK_DETAIL."&id=$this->id"; + } + + public function getDetailUrl () { + global $config; + if ($config['cops_use_fancyapps'] == 0) { + return 'index.php' . $this->getUri (); + } else { + return 'bookdetail.php?id=' . $this->id; + } + } + public function getTitle () { return $this->title; } diff --git a/bookdetail.php b/bookdetail.php index ff55374..1edd2f3 100644 --- a/bookdetail.php +++ b/bookdetail.php @@ -23,7 +23,7 @@ $book->getLinkArray (); hasCover) { ?> - + @@ -38,7 +38,7 @@ $book->getLinkArray (); } ?> -