1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-03 13:17:24 +02:00

Bugtracker #4367 - notice removal - thanks Yarodin

This commit is contained in:
e107steved
2008-05-30 20:57:20 +00:00
parent bc4e612896
commit 006c537122

View File

@@ -12,9 +12,9 @@
| GNU General Public License (http://gnu.org). | GNU General Public License (http://gnu.org).
| |
| $Source: /cvs_backup/e107_0.8/e107_handlers/sitelinks_class.php,v $ | $Source: /cvs_backup/e107_0.8/e107_handlers/sitelinks_class.php,v $
| $Revision: 1.15 $ | $Revision: 1.16 $
| $Date: 2007-08-19 21:49:32 $ | $Date: 2008-05-30 20:57:13 $
| $Author: e107coders $ | $Author: e107steved $
+---------------------------------------------------------------+ +---------------------------------------------------------------+
*/ */
@@ -58,7 +58,8 @@ class sitelinks
global $pref, $ns, $e107cache, $linkstyle; global $pref, $ns, $e107cache, $linkstyle;
$usecache = ((trim(defset('LINKSTART_HILITE')) != "" || trim(defset('LINKCLASS_HILITE')) != "") ? false : true); $usecache = ((trim(defset('LINKSTART_HILITE')) != "" || trim(defset('LINKCLASS_HILITE')) != "") ? false : true);
if ($usecache && !strpos(e_SELF, e_ADMIN) & ($data = $e107cache->retrieve('sitelinks_'.$cat.md5($linkstyle.e_PAGE.e_QUERY)))) { if ($usecache && !strpos(e_SELF, e_ADMIN) && ($data = $e107cache->retrieve('sitelinks_'.$cat.md5($linkstyle.e_PAGE.e_QUERY))))
{
return $data; return $data;
} }
@@ -306,7 +307,7 @@ function hilite($link,$enabled='')
$link_qry = (isset($tmp[1])) ? $tmp[1] : ""; $link_qry = (isset($tmp[1])) ? $tmp[1] : "";
$link_slf = (isset($tmp[0])) ? $tmp[0] : ""; $link_slf = (isset($tmp[0])) ? $tmp[0] : "";
$link_pge = basename($link_slf); $link_pge = basename($link_slf);
$link_match = strpos(e_SELF,$tmp[0]); // e_SELF is the actual displayed page $link_match = (empty($tmp[0])) ? "": strpos(e_SELF,$tmp[0]); // e_SELF is the actual displayed page
if(e_MENU == "debug" && getperms('0')) if(e_MENU == "debug" && getperms('0'))
{ {
@@ -432,7 +433,7 @@ function hilite($link,$enabled='')
if(strpos($link, "?") !== FALSE){ if(strpos($link, "?") !== FALSE){
$thelink = str_replace("../", "", $link); $thelink = str_replace("../", "", $link);
if((strpos(e_SELF,$thelink) !== false) && (strpos(e_QUERY,$link_qry) !== false)){ if(!preg_match("/all|item|cat|list/", e_QUERY) && (empty($link) == false) && (strpos(e_SELF, str_replace("../", "",$link)) !== false)){
return true; return true;
} }
} }
@@ -440,11 +441,11 @@ function hilite($link,$enabled='')
return true; return true;
} }
if((!$link_qry && !e_QUERY) && (strpos(e_SELF,$link) !== FALSE)){ if((!$link_qry && !e_QUERY) && (empty($link) == FALSE) && (strpos(e_SELF,$link) !== FALSE)){
return TRUE; return TRUE;
} }
if(($link_slf == e_SELF && !link_qry) || (e_QUERY && strpos(e_SELF."?".e_QUERY,$link)!== FALSE) ){ if(($link_slf == e_SELF && !link_qry) || (e_QUERY && empty($link) == FALSE && strpos(e_SELF."?".e_QUERY,$link)!== FALSE) ){
return TRUE; return TRUE;
} }