Revision 58
Added by stefan about 20 years ago
| trunk/CHANGELOG | ||
|---|---|---|
| 12 | 12 |
|
| 13 | 13 |
------------------------------------- 2.6.0 ------------------------------------- |
| 14 | 14 |
09-Sep-2005 Stefan Braunewell |
| 15 |
+ Added breadcrumbs code. Call using $wb->breadcrumbs(). |
|
| 15 | 16 |
+ Added utf-8 character encoding meta tag into all stock templates. |
| 16 | 17 |
-/! Removed initialize.php again, initialization now takes place in |
| 17 | 18 |
class wb constructor. |
| trunk/wb/framework/compatibility.php | ||
|---|---|---|
| 39 | 39 |
|
| 40 | 40 |
function page_content($block=1) {
|
| 41 | 41 |
global $wb; |
| 42 |
$wb->page_content($block);
|
|
| 42 |
$wb->content($block); |
|
| 43 | 43 |
} |
| 44 | 44 |
|
| 45 | 45 |
// Old menu call invokes new menu function |
| trunk/wb/framework/class.frontend.php | ||
|---|---|---|
| 410 | 410 |
} |
| 411 | 411 |
} |
| 412 | 412 |
|
| 413 |
function page_content($block = 1) {
|
|
| 413 |
function content($block = 1) {
|
|
| 414 | 414 |
// Get outside objects |
| 415 | 415 |
global $TEXT,$MENU,$HEADING,$MESSAGE; |
| 416 | 416 |
global $globals; |
| ... | ... | |
| 452 | 452 |
} |
| 453 | 453 |
} |
| 454 | 454 |
|
| 455 |
function breadcrumbs($sep=' > ',$tier=1,$links=true) {
|
|
| 456 |
$page_id=&$this->page_id; |
|
| 457 |
if ($page_id!=0) |
|
| 458 |
{
|
|
| 459 |
global $database; |
|
| 460 |
$bca=&$this->page_trail; |
|
| 461 |
if (sizeof($bca)==0) |
|
| 462 |
create_breadcrumbs($page_id); |
|
| 463 |
$counter=0; |
|
| 464 |
foreach ($bca as $temp) |
|
| 465 |
{
|
|
| 466 |
if ($counter>=(tier-1)); |
|
| 467 |
{
|
|
| 468 |
if ($counter>=$tier) echo $sep; |
|
| 469 |
$query_menu=$database->query("SELECT menu_title,link FROM ".TABLE_PREFIX."pages WHERE page_id=$temp");
|
|
| 470 |
$page=$query_menu->fetchRow(); |
|
| 471 |
if ($links==true AND $temp!=$page_id) |
|
| 472 |
echo '<a href="'.page_link($page['link']).'">'.$page['menu_title'].'</a>'; |
|
| 473 |
else |
|
| 474 |
echo stripslashes($page['menu_title']); |
|
| 475 |
} |
|
| 476 |
$counter++; |
|
| 477 |
} |
|
| 478 |
} |
|
| 479 |
} |
|
| 480 |
|
|
| 455 | 481 |
// Function for page title |
| 456 | 482 |
function page_title($spacer = ' - ', $template = '[WEBSITE_TITLE][SPACER][PAGE_TITLE]') {
|
| 457 | 483 |
$vars = array('[WEBSITE_TITLE]', '[PAGE_TITLE]', '[MENU_TITLE]', '[SPACER]');
|
Also available in: Unified diff