Mercurial > hg > fapweb
changeset 887:e6a1410ce71d
Move function to index.php
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Wed, 26 Nov 2014 18:05:52 +0200 |
parents | 354183f9c6e9 |
children | e0903d0c3954 |
files | index.php msite.inc.php |
diffstat | 2 files changed, 11 insertions(+), 11 deletions(-) [+] |
line wrap: on
line diff
--- a/index.php Wed Nov 26 17:48:28 2014 +0200 +++ b/index.php Wed Nov 26 18:05:52 2014 +0200 @@ -8,6 +8,17 @@ require_once "msite.inc.php"; require_once "msession.inc.php"; + +function stGetMainPageLink($id, $name, $show = TRUE) +{ + global $pageName; + if ($show) + return " <a class=\"".($id == $pageName ? "active" : "inactive")."\" href=\"".$id."\">".$name."</a>\n"; + else + return ""; +} + + // Get the name of the page if (!isset($pagePath)) $pagePath = "pages/"; if (!isset($pageExt)) $pageExt = ".inc.php";
--- a/msite.inc.php Wed Nov 26 17:48:28 2014 +0200 +++ b/msite.inc.php Wed Nov 26 18:05:52 2014 +0200 @@ -1262,17 +1262,6 @@ } -// Get link helper function -function stGetMainPageLink($id, $name, $show = TRUE) -{ - global $pageName; - if ($show) - return " <a class=\"".($id == $pageName ? "active" : "inactive")."\" href=\"".$id."\">".$name."</a>\n"; - else - return ""; -} - - function stNormalizeListSlideOrder($list_id) { }