1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-18 04:12:00 +02:00

Generic breadcrumb() function added. Removed front-end css styling from admin area.

This commit is contained in:
Cameron
2013-06-22 18:11:10 -07:00
parent 62e06d7a30
commit 279abb0b2b
3 changed files with 39 additions and 2 deletions

View File

@@ -1570,6 +1570,43 @@ class e_form
}
/**
* Render a Breadcrumb in Bootstrap format.
* @param $array
*/
function breadcrumb($array)
{
if(!is_array($array)){ return; }
$text = '<ul class="breadcrumb">
<li>';
foreach($array as $val)
{
$ret = "";
$ret .= vartrue($val['url']) ? "<a href='".$val['url']."'>" : "";
$ret .= vartrue($val['text'],'');
$ret .= vartrue($val['url']) ? "</a>" : "";
if($ret != '')
{
$opt[] = $ret;
}
}
$text .= implode("<span class='divider'>/</span></li><li>",$opt);
$text .= "</li></ul>";
return $text;
}
/**
* Admin Button - for front-end, use button();