| @@ 292-294 (lines=3) @@ | ||
| 289 | $tbl_ancestors = $mytree->getAllParent($cat_cid); |
|
| 290 | $tbl_ancestors = array_reverse($tbl_ancestors); |
|
| 291 | $tbl_tmp[] = "<a href='" . BOOKSHOP_URL . "index.php' title='" . bookshop_makeHrefTitle(bookshop_get_module_name()) . "'>" . bookshop_get_module_name() . '</a>'; |
|
| 292 | foreach ($tbl_ancestors as $item) { |
|
| 293 | $tbl_tmp[] = "<a href='" . $h_bookshop_cat->GetCategoryLink($item->getVar('cat_cid'), $item->getVar('cat_title')) . "' title='" . bookshop_makeHrefTitle($item->getVar('cat_title')) . "'>" . $item->getVar('cat_title') . '</a>'; |
|
| 294 | } |
|
| 295 | // Adding to the current category |
|
| 296 | $tbl_tmp[] = "<a href='" . $h_bookshop_cat->GetCategoryLink($cat_cid, $category->getVar('cat_title')) . "' title='" . bookshop_makeHrefTitle($category->getVar('cat_title')) . "'>" . $category->getVar('cat_title') . '</a>'; |
|
| 297 | $breadcrumb = implode(' » ', $tbl_tmp); |
|
| @@ 57-59 (lines=3) @@ | ||
| 54 | $mytree = new XoopsObjectTree($tbl_categories, 'cat_cid', 'cat_pid'); |
|
| 55 | $tblChilds = $mytree->getAllChild($cat_cid); |
|
| 56 | //$tblChilds = array_reverse($tblChilds); |
|
| 57 | foreach ($tblChilds as $item) { |
|
| 58 | $tbl_tmp[] = "<a href='" . $h_bookshop_cat->GetCategoryLink($item->getVar('cat_cid'), $item->getVar('cat_title')) . "' title='" . bookshop_makeHrefTitle($item->getVar('cat_title')) . "'>" . $item->getVar('cat_title') . '</a>'; |
|
| 59 | } |
|
| 60 | $block['block_categories'] = $tbl_tmp; |
|
| 61 | ||
| 62 | $category = null; |
|
| @@ 74-76 (lines=3) @@ | ||
| 71 | $criteria = new Criteria('cat_pid', 0, '='); |
|
| 72 | $criteria->setSort('cat_title'); |
|
| 73 | $tbl_categories = $h_bookshop_cat->getObjects($criteria, true); |
|
| 74 | foreach ($tbl_categories as $item) { |
|
| 75 | $tbl_tmp[] = "<a href='" . $h_bookshop_cat->GetCategoryLink($item->getVar('cat_cid'), $item->getVar('cat_title')) . "' title='" . bookshop_makeHrefTitle($item->getVar('cat_title')) . "'>" . $item->getVar('cat_title') . '</a>'; |
|
| 76 | } |
|
| 77 | $block['block_categories'] = $tbl_tmp; |
|
| 78 | } |
|
| 79 | } else { // Affichage classique |
|
| @@ 233-236 (lines=4) @@ | ||
| 230 | $tbl_ancestors = $mytree->getAllParent($book->getVar('book_cid')); |
|
| 231 | $tbl_ancestors = array_reverse($tbl_ancestors); |
|
| 232 | $tbl_tmp[] = "<a href='" . BOOKSHOP_URL . "index.php' title='" . bookshop_makeHrefTitle(bookshop_get_module_name()) . "'>" . bookshop_get_module_name() . '</a>'; |
|
| 233 | foreach ($tbl_ancestors as $item) { |
|
| 234 | $tbl_tmp[] = "<a href='" . $h_bookshop_cat->GetCategoryLink($item->getVar('cat_cid'), $item->getVar('cat_title')) . "' title='" . bookshop_makeHrefTitle($item->getVar('cat_title')) . "'>" . $item->getVar('cat_title') . '</a>'; |
|
| 235 | } |
|
| 236 | // Add the current category |
|
| 237 | $tbl_tmp[] = "<a href='" . $h_bookshop_cat->GetCategoryLink($book_category->getVar('cat_cid'), $book_category->getVar('cat_title')) . "' title='" . bookshop_makeHrefTitle($book_category->getVar('cat_title')) . "'>" . $book_category->getVar('cat_title') . '</a>'; |
|
| 238 | $tbl_tmp[] = $book->getVar('book_title'); |
|
| 239 | $breadcrumb = implode(' » ', $tbl_tmp); |
|