summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: e70bc4f)
raw | patch | inline | side by side (parent: e70bc4f)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 30 May 2006 04:29:49 +0000 (04:29 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 30 May 2006 04:29:49 +0000 (04:29 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@3550 594d385d-05f5-0310-b6e9-bd551577e9d8
html/helpviewer.php | patch | blob | history | |
include/functions_helpviewer.inc | patch | blob | history |
diff --git a/html/helpviewer.php b/html/helpviewer.php
index dddf0cd8b0c6a72bfc98f5165e399cf00460c508..c463c63ed84a6b65a6e55f22c8a4363a9a90a607 100644 (file)
--- a/html/helpviewer.php
+++ b/html/helpviewer.php
$index =$defaultpage;
$forward ="node1.html";
-
+$helpdir ="";
/* Every class which is called within a tab, stores its name in the Session.
* If $_SESSION['current_class_for_help'] isset,
* get the helpfile specified in the xml file and display it.
$str = $xml->parse();
/* __LANG__ is used as placeholder for the used language*/
- $helpdir= preg_replace("/__LANG__/i",$lang,$str[($_SESSION['current_class_for_help'])]['PATH']);
+ $helpdir= @preg_replace("/__LANG__/i",$lang,$str[($_SESSION['current_class_for_help'])]['PATH']);
/* If there is no entry in the xml file for this class, display an error message */
if($helpdir == ""){
}
}
}
-
$helpdir.="/";
/* Save current settings */
index 44938a19bd55726ad52719eb192e43e4347e7342..874f24b3f02958c43b9a7c221cfe0fc3440183e7 100644 (file)
}
function tag_open($parser,$tag,$attrs)
{
- $this->entries[$attrs['NAME']]=$attrs;
+ @$this->entries[$attrs['NAME']]=$attrs;
}
function tag_close(){; }
/* Filter in Tag results*/
if(count($matches[0])){
foreach($matches[0] as $num=>$hit){
- if(is_in_tag($arr[$key]['content'],$hit[1])) {
+ if(isset($arr[$key]['content']) && (is_in_tag($arr[$key]['content'],$hit[1]))){
unset($matches[0][$num]);
}
}
/* appending footer message for resultlist */
$ret.= "<br>
- ".sprintf(_("%s results for your search with the keyword %s interpreted as %s"),
+ ".sprintf(_("%s results for your search with the keyword %s"),
"<b>".count($topten)."</b>",
- "<b>".($_SESSION['search_string'])."</b>",
"<b>".$_SESSION['parsed_search_keyword']."</b>");
$ret.="<br>
<br>";
/*Simple function to detect if we prepare to change a tag or visible text */
function is_in_tag($string,$pos)
{
- $pos1 = strpos($string,"<",$pos);
- $pos2 = strpos($string,">",$pos);
-
+ $pos1 = $pos2 = 0;
+ if(preg_match("/</",$string)){
+ $pos1 = strpos($string,"<",$pos);
+ }
+ if(preg_match("/>/",$string)){
+ $pos2 = strpos($string,">",$pos);
+ }
if ($pos1 > $pos2) {
return(true);
}else{