Skip to content

Commit

Permalink
Update theme_shortcodes.php
Browse files Browse the repository at this point in the history
adding shortcodes
  • Loading branch information
Jimmi08 authored Aug 6, 2023
1 parent 0177a00 commit 6e5aed0
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions e107_themes/bootstrap5/theme_shortcodes.php
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,45 @@ function sc_theme_news_banner($parm=null)

}

function sc_bootstrap_branding()
{
$pref = e107::pref('theme', 'branding');

switch ($pref)
{
case 'logo':

return e107::getParser()->parseTemplate('{SITELOGO: h=30}', true);

break;

case 'sitenamelogo':
return "<span>" . e107::getParser()->parseTemplate('{SITELOGO: h=30}', true) . "</span>" . SITENAME;

break;

case 'sitename':
default:

return SITENAME;

break;
}
}

function sc_bootstrap_nav_align()
{
$pref = e107::pref('theme', 'nav_alignment');

if ($pref == 'right')
{
return e107::getParser()->parseTemplate('{NAVIGATION: type=main&class=ms-auto}');
}
else
{
return e107::getParser()->parseTemplate('{NAVIGATION: type=main&class=me-auto}');
}
}


}
Expand Down

0 comments on commit 6e5aed0

Please sign in to comment.