24 require_once(
"./Services/COPage/classes/class.ilPageContent.php");
25 require_once(
"./Services/COPage/classes/class.ilWysiwygUtil.php");
58 $this->par_node =& $a_node->first_child();
70 $this->par_node =& $this->dom->create_element(
"Paragraph");
71 $this->par_node =& $this->node->append_child($this->par_node);
72 $this->par_node->set_attribute(
"Language",
"");
73 $node->append_child ($this->node);
85 if($succ_node =
$node->next_sibling())
87 $this->node = $succ_node->insert_before($this->node, $succ_node);
91 $parent_node =
$node->parent_node();
92 $this->node = $parent_node->append_child($this->node);
94 $this->par_node = $this->dom->create_element(
"Paragraph");
95 $this->par_node = $this->node->append_child($this->par_node);
96 $this->par_node->set_attribute(
"Language",
"");
106 function create(&$a_pg_obj, $a_hier_id, $a_pc_id =
"")
109 $this->node =& $this->dom->create_element(
"PageContent");
110 $a_pg_obj->insertContent($this, $a_hier_id,
IL_INSERT_AFTER, $a_pc_id);
111 $this->par_node =& $this->dom->create_element(
"Paragraph");
112 $this->par_node =& $this->node->append_child($this->par_node);
113 $this->par_node->set_attribute(
"Language",
"");
124 function setText($a_text, $a_auto_split =
false)
126 if (!is_array($a_text))
128 $text = array(array(
"level" => 0,
"text" => $a_text));
142 $temp_dom =
domxml_open_mem(
'<?xml version="1.0" encoding="UTF-8"?><Paragraph>'.$text[0][
"text"].
'</Paragraph>',
143 DOMXML_LOAD_PARSING, $error);
150 $children = $this->par_node->child_nodes();
151 for($i=0; $i<count($children); $i++)
153 $this->par_node->remove_child($children[$i]);
158 $path =
"//Paragraph";
160 if (count(
$res->nodeset) == 1)
162 $new_par_node =&
$res->nodeset[0];
163 $new_childs = $new_par_node->child_nodes();
165 for($i=0; $i<count($new_childs); $i++)
167 $cloned_child =& $new_childs[$i]->clone_node(
true);
168 $this->par_node->append_child($cloned_child);
174 if ((count($text) > 1) && (substr($orig_characteristic, 0, 8) ==
"Headline"))
176 $orig_characteristic =
"";
178 if ($text[0][
"level"] > 0)
180 $this->par_node->set_attribute(
"Characteristic",
'Headline'.$text[0][
"level"]);
188 for ($i=1; $i<count($text); $i++)
193 $next_par->createAfter($c_node);
195 if ($text[$i][
"level"] > 0)
197 $next_par->setCharacteristic(
"Headline".$text[$i][
"level"]);
201 $next_par->setCharacteristic($orig_characteristic);
203 $ok = $next_par->setText($text[$i][
"text"],
false);
204 $c_node = $next_par->node;
223 if (is_object($this->par_node))
226 $childs = $this->par_node->child_nodes();
227 for($i=0; $i<count($childs); $i++)
229 $content .= $this->dom->dump_node($childs[$i]);
248 $this->par_node->set_attribute(
"Characteristic", $a_char);
252 if ($this->par_node->has_attribute(
"Characteristic"))
254 $this->par_node->remove_attribute(
"Characteristic");
266 if (is_object($this->par_node))
268 return $this->par_node->get_attribute(
"Characteristic");
280 $this->par_node->set_attribute(
"SubCharacteristic", $a_char);
284 if ($this->par_node->has_attribute(
"SubCharacteristic"))
286 $this->par_node->remove_attribute(
"SubCharacteristic");
298 return $this->par_node->get_attribute(
"AutoIndent");
305 $this->par_node->set_attribute(
"AutoIndent", $a_char);
309 if ($this->par_node->has_attribute(
"AutoIndent"))
311 $this->par_node->remove_attribute(
"AutoIndent");
321 return $this->par_node->get_attribute(
"SubCharacteristic");
332 $this->par_node->set_attribute(
"DownloadTitle", $a_char);
336 if ($this->par_node->has_attribute(
"DownloadTitle"))
338 $this->par_node->remove_attribute(
"DownloadTitle");
348 return $this->par_node->get_attribute(
"DownloadTitle");
357 $a_char = empty($a_char)?
"n":$a_char;
359 $this->par_node->set_attribute(
"ShowLineNumbers", $a_char);
368 return $this->par_node->get_attribute(
"ShowLineNumbers");
376 $this->par_node->set_attribute(
"Language", $a_lang);
384 return $this->par_node->get_attribute(
"Language");
387 function input2xml($a_text, $a_wysiwyg = 0, $a_handle_lists =
true)
395 static function _input2xml($a_text, $a_lang, $a_wysiwyg = 0, $a_handle_lists =
true)
401 $a_text = trim($a_text);
406 $a_text = str_replace(
"&",
"&",$a_text);
407 $a_text = str_replace(
"<",
"<",$a_text);
408 $a_text = str_replace(
">",
">",$a_text);
411 $a_text = preg_replace(
'/<([\s\/]*?PageTurn.*?)>/i',
"<$1>",$a_text);
412 $a_text = preg_replace(
'/<([\s\/]*?BibItemIdentifier.*?)>/i',
"<$1>",$a_text);
423 $a_text = str_replace(chr(13).chr(10),
"<br />",$a_text);
424 $a_text = str_replace(chr(13),
"<br />", $a_text);
425 $a_text = str_replace(chr(10),
"<br />", $a_text);
433 $a_text = eregi_replace(
"\[com\]",
"<Comment Language=\"".$a_lang.
"\">",$a_text);
434 $a_text = eregi_replace(
"\[\/com\]",
"</Comment>",$a_text);
435 $a_text = eregi_replace(
"\[emp\]",
"<Emph>",$a_text);
436 $a_text = eregi_replace(
"\[\/emp\]",
"</Emph>",$a_text);
437 $a_text = eregi_replace(
"\[str\]",
"<Strong>",$a_text);
438 $a_text = eregi_replace(
"\[\/str\]",
"</Strong>",$a_text);
439 $a_text = eregi_replace(
"\[fn\]",
"<Footnote>",$a_text);
440 $a_text = eregi_replace(
"\[\/fn\]",
"</Footnote>",$a_text);
441 $a_text = eregi_replace(
"\[quot\]",
"<Quotation Language=\"".$a_lang.
"\">",$a_text);
442 $a_text = eregi_replace(
"\[\/quot\]",
"</Quotation>",$a_text);
443 $a_text = eregi_replace(
"\[code\]",
"<Code>",$a_text);
444 $a_text = eregi_replace(
"\[\/code\]",
"</Code>",$a_text);
448 $ws=
"[ \t\r\f\v\n]*";
450 while (eregi(
"\[(iln$ws((inst$ws=$ws([\"0-9])*)?$ws".
451 "((page|chap|term|media|htlm|lm|dbk|glo|frm|exc|tst|svy|webr|chat|cat|crs|grp|file|fold|sahs|mcst|obj)$ws=$ws([\"0-9])*)$ws".
452 "(target$ws=$ws(\"(New|FAQ|Media)\"))?$ws))\]", $a_text, $found))
455 $inst_str = $attribs[
"inst"];
457 if (isset($attribs[
"page"]))
459 if (!empty($found[10]))
461 $tframestr =
" TargetFrame=\"".$found[10].
"\" ";
467 $a_text = eregi_replace(
"\[".$found[1].
"\]",
468 "<IntLink Target=\"il_".$inst_str.
"_pg_".$attribs[page].
"\" Type=\"PageObject\"".$tframestr.
">", $a_text);
471 else if (isset($attribs[
"chap"]))
473 if (!empty($found[10]))
475 $tframestr =
" TargetFrame=\"".$found[10].
"\" ";
481 $a_text = eregi_replace(
"\[".$found[1].
"\]",
482 "<IntLink Target=\"il_".$inst_str.
"_st_".$attribs[chap].
"\" Type=\"StructureObject\"".$tframestr.
">", $a_text);
485 else if (isset($attribs[
"term"]))
490 $tframestr =
" TargetFrame=\"New\" ";
494 $tframestr =
" TargetFrame=\"Glossary\" ";
497 $a_text = eregi_replace(
"\[".$found[1].
"\]",
498 "<IntLink Target=\"il_".$inst_str.
"_git_".$attribs[term].
"\" Type=\"GlossaryItem\" $tframestr>", $a_text);
501 else if (isset($attribs[
"media"]))
503 if (!empty($found[10]))
505 $tframestr =
" TargetFrame=\"".$found[10].
"\" ";
506 $a_text = eregi_replace(
"\[".$found[1].
"\]",
507 "<IntLink Target=\"il_".$inst_str.
"_mob_".$attribs[media].
"\" Type=\"MediaObject\"".$tframestr.
">", $a_text);
511 $a_text = eregi_replace(
"\[".$found[1].
"\]",
512 "<IntLink Target=\"il_".$inst_str.
"_mob_".$attribs[media].
"\" Type=\"MediaObject\"/>", $a_text);
517 else if (isset($attribs[
"lm"]) || isset($attribs[
"dbk"]) || isset($attribs[
"glo"])
518 || isset($attribs[
"frm"]) || isset($attribs[
"exc"]) || isset($attribs[
"tst"])
519 || isset($attribs[
"svy"]) || isset($attribs[
"obj"]) || isset($attribs[
'webr'])
520 || isset($attribs[
"htlm"]) || isset($attribs[
"chat"]) || isset($attribs[
"grp"])
521 || isset($attribs[
"fold"]) || isset($attribs[
"sahs"]) || isset($attribs[
"mcst"])
522 || isset($attribs[
"cat"]) || isset($attribs[
"crs"]) || isset($attribs[
"file"]))
524 $obj_id = (isset($attribs[
"lm"])) ? $attribs[
"lm"] : $obj_id;
525 $obj_id = (isset($attribs[
"dbk"])) ? $attribs[
"dbk"] : $obj_id;
526 $obj_id = (isset($attribs[
"chat"])) ? $attribs[
"chat"] : $obj_id;
527 $obj_id = (isset($attribs[
"glo"])) ? $attribs[
"glo"] : $obj_id;
528 $obj_id = (isset($attribs[
"frm"])) ? $attribs[
"frm"] : $obj_id;
529 $obj_id = (isset($attribs[
"exc"])) ? $attribs[
"exc"] : $obj_id;
530 $obj_id = (isset($attribs[
"htlm"])) ? $attribs[
"htlm"] : $obj_id;
531 $obj_id = (isset($attribs[
"tst"])) ? $attribs[
"tst"] : $obj_id;
532 $obj_id = (isset($attribs[
"svy"])) ? $attribs[
"svy"] : $obj_id;
533 $obj_id = (isset($attribs[
"obj"])) ? $attribs[
"obj"] : $obj_id;
534 $obj_id = (isset($attribs[
"webr"])) ? $attribs[
"webr"] : $obj_id;
535 $obj_id = (isset($attribs[
"fold"])) ? $attribs[
"fold"] : $obj_id;
536 $obj_id = (isset($attribs[
"cat"])) ? $attribs[
"cat"] : $obj_id;
537 $obj_id = (isset($attribs[
"crs"])) ? $attribs[
"crs"] : $obj_id;
538 $obj_id = (isset($attribs[
"grp"])) ? $attribs[
"grp"] : $obj_id;
539 $obj_id = (isset($attribs[
"file"])) ? $attribs[
"file"] : $obj_id;
540 $obj_id = (isset($attribs[
"sahs"])) ? $attribs[
"sahs"] : $obj_id;
541 $obj_id = (isset($attribs[
"mcst"])) ? $attribs[
"mcst"] : $obj_id;
546 $a_text = eregi_replace(
"\[".$found[1].
"\]",
547 "<IntLink Target=\"il_".$inst_str.
"_obj_".$obj_id.
"\" Type=\"RepositoryItem\">", $a_text);
551 $a_text = eregi_replace(
"\[".$found[1].
"\]",
552 "<IntLink Target=\"il_".$inst_str.
"_".$found[6].
"_".$obj_id.
"\" Type=\"RepositoryItem\">", $a_text);
557 $a_text = eregi_replace(
"\[".$found[1].
"\]",
"[error: iln".$found[1].
"]",$a_text);
560 while (eregi(
"\[(iln$ws((inst$ws=$ws([\"0-9])*)?".$ws.
"media$ws=$ws([\"0-9])*)$ws)/\]", $a_text, $found))
563 $inst_str = $attribs[
"inst"];
564 $a_text = eregi_replace(
"\[".$found[1].
"/\]",
565 "<IntLink Target=\"il_".$inst_str.
"_mob_".$attribs[media].
"\" Type=\"MediaObject\"/>", $a_text);
567 $a_text = eregi_replace(
"\[\/iln\]",
"</IntLink>",$a_text);
570 $ws=
"[ \t\r\f\v\n]*";
573 while (eregi(
"\[(xln$ws(url$ws=$ws\"([^\"])*\")$ws)\]", $a_text, $found))
579 if (isset($attribs[
"url"]))
582 $a_text = str_replace(
"[".$found[1].
"]",
"<ExtLink Href=\"".$attribs[
"url"].
"\">", $a_text);
586 $a_text = str_replace(
"[".$found[1].
"]",
"[error: xln".$found[1].
"]",$a_text);
589 $a_text = eregi_replace(
"\[\/xln\]",
"</ExtLink>",$a_text);
607 $rows = explode(
"<br />", $a_text.
"<br />");
614 foreach ($rows as $row)
617 if (str_replace(
"#",
"*", substr($row, 0, 3)) ==
"***")
621 else if (str_replace(
"#",
"*", substr($row, 0, 2)) ==
"**")
625 else if (str_replace(
"#",
"*", substr($row, 0, 1)) ==
"*")
631 if ($level < $old_level)
633 for ($i = $old_level; $i > $level; $i--)
635 $text.=
"</SimpleListItem></".$clist[$i].
">";
639 $text.=
"</SimpleListItem>";
642 else if ($old_level > 0 && $level > 0 && ($level == $old_level))
644 $text.=
"</SimpleListItem>";
646 else if (($level == $old_level) && $text !=
"")
652 if ($level > $old_level)
654 for($i = $old_level + 1; $i <= $level; $i++)
656 if (substr($row, $i - 1, 1) ==
"*")
658 $clist[$i] =
"SimpleBulletList";
662 $clist[$i] =
"SimpleNumberedList";
664 $text.=
"<".$clist[$i].
"><SimpleListItem>";
667 else if ($old_level > 0 && $level > 0)
669 $text.=
"<SimpleListItem>";
671 $text.= substr($row, $level);
677 if (substr($text, strlen($text) - 6) ==
"<br />")
679 $text = substr($text, 0, strlen($text) - 6);
695 "</SimpleListItem>",
"<SimpleListItem>",
"<SimpleListItem/>",
"<SimpleNumberedList>",
"</SimpleNumberedList>"));
697 $current_list = array();
699 for ($i=0; $i<= count($segments); $i++)
701 if ($segments[$i] ==
"<SimpleBulletList>")
703 if (count($current_list) == 0)
707 array_push($current_list,
"*");
710 else if ($segments[$i] ==
"<SimpleNumberedList>")
712 if (count($current_list) == 0)
716 array_push($current_list,
"#");
719 else if ($segments[$i] ==
"</SimpleBulletList>")
721 array_pop($current_list);
724 else if ($segments[$i] ==
"</SimpleNumberedList>")
726 array_pop($current_list);
729 else if ($segments[$i] ==
"<SimpleListItem>")
733 else if ($segments[$i] ==
"</SimpleListItem>")
737 else if ($segments[$i] ==
"<SimpleListItem/>")
744 foreach($current_list as $list)
760 foreach($current_list as $list)
765 $text.= $segments[$i];
775 if ($segments[count($segments) - 1] ==
"</SimpleBulletList>" ||
776 $segments[count($segments) - 1] ==
"</SimpleNumberedList>" &&
777 substr($text, strlen($text) - 6) ==
"<br />")
779 $text = substr($text, 0, strlen($text) - 6);
792 $nothing_found =
false;
793 while (!$nothing_found)
795 $nothing_found =
true;
797 foreach($a_needles as $needle)
799 $pos = stripos($a_haystack, $needle);
800 if (is_int($pos) && ($pos < $found || $found == -1))
803 $found_needle = $needle;
804 $nothing_found =
false;
809 $segments[] = substr($a_haystack, 0, $found);
810 $a_haystack = substr($a_haystack, $found);
814 $segments[] = substr($a_haystack, 0, strlen($found_needle));
815 $a_haystack = substr($a_haystack, strlen($found_needle));
818 if ($a_haystack !=
"")
820 $segments[] = $a_haystack;
840 $a_text = eregi_replace(
"<Comment[^>]*>",
"[com]",$a_text);
841 $a_text = eregi_replace(
"</Comment>",
"[/com]",$a_text);
842 $a_text = eregi_replace(
"<Comment/>",
"[com][/com]",$a_text);
843 $a_text = eregi_replace(
"<Emph>",
"[emp]",$a_text);
844 $a_text = eregi_replace(
"</Emph>",
"[/emp]",$a_text);
845 $a_text = eregi_replace(
"<Emph/>",
"[emp][/emp]",$a_text);
846 $a_text = eregi_replace(
"<Strong>",
"[str]",$a_text);
847 $a_text = eregi_replace(
"</Strong>",
"[/str]",$a_text);
848 $a_text = eregi_replace(
"<Strong/>",
"[str][/str]",$a_text);
849 $a_text = eregi_replace(
"<Footnote[^>]*>",
"[fn]",$a_text);
850 $a_text = eregi_replace(
"</Footnote>",
"[/fn]",$a_text);
851 $a_text = eregi_replace(
"<Footnote/>",
"[fn][/fn]",$a_text);
852 $a_text = eregi_replace(
"<Quotation[^>]*>",
"[quot]",$a_text);
853 $a_text = eregi_replace(
"</Quotation>",
"[/quot]",$a_text);
854 $a_text = eregi_replace(
"<Quotation/>",
"[quot][/quot]",$a_text);
855 $a_text = eregi_replace(
"<Code[^>]*>",
"[code]",$a_text);
856 $a_text = eregi_replace(
"</Code>",
"[/code]",$a_text);
857 $a_text = eregi_replace(
"<Code/>",
"[code][/code]",$a_text);
863 while (eregi(
"<IntLink($any)>", $a_text, $found))
867 $target = explode(
"_", $attribs[
"Target"]);
869 $inst_str = (!is_int(strpos($attribs[
"Target"],
"__")))
870 ? $inst_str =
"inst=\"".$target[1].
"\" "
872 switch($attribs[
"Type"])
875 $tframestr = (!empty($attribs[
"TargetFrame"]))
876 ?
" target=\"".$attribs[
"TargetFrame"].
"\""
878 $a_text = eregi_replace(
"<IntLink".$found[1].
">",
"[iln ".$inst_str.
"page=\"".
$target_id.
"\"$tframestr]",$a_text);
881 case "StructureObject":
882 $tframestr = (!empty($attribs[
"TargetFrame"]))
883 ?
" target=\"".$attribs[
"TargetFrame"].
"\""
885 $a_text = eregi_replace(
"<IntLink".$found[1].
">",
"[iln ".$inst_str.
"chap=\"".
$target_id.
"\"$tframestr]",$a_text);
889 $tframestr = (empty($attribs[
"TargetFrame"]) || $attribs[
"TargetFrame"] ==
"Glossary")
891 :
" target=\"".$attribs[
"TargetFrame"].
"\"";
892 $a_text = eregi_replace(
"<IntLink".$found[1].
">",
"[iln ".$inst_str.
"term=\"".
$target_id.
"\"".$tframestr.
"]",$a_text);
896 if (empty($attribs[
"TargetFrame"]))
898 $a_text = eregi_replace(
"<IntLink".$found[1].
">",
"[iln ".$inst_str.
"media=\"".
$target_id.
"\"/]",$a_text);
902 $a_text = eregi_replace(
"<IntLink".$found[1].
">",
"[iln media=\"".
$target_id.
"\"".
903 " target=\"".$attribs[
"TargetFrame"].
"\"]",$a_text);
907 case "RepositoryItem":
914 $rtype = $target[count($target) - 2];
917 $a_text = eregi_replace(
"<IntLink".$found[1].
">",
"[iln ".$inst_str.
"$target_type=\"".
$target_id.
"\"".$tframestr.
"]",$a_text);
921 $a_text = eregi_replace(
"<IntLink".$found[1].
">",
"[iln]",$a_text);
925 $a_text = eregi_replace(
"</IntLink>",
"[/iln]",$a_text);
928 while (eregi(
"<ExtLink($any)>", $a_text, $found))
933 $a_text = str_replace(
"<ExtLink".$found[1].
">",
"[xln url=\"".$attribs[
"Href"].
"\"]",$a_text);
935 $a_text = eregi_replace(
"</ExtLink>",
"[/xln]",$a_text);
939 $a_text = str_replace(
"<br />",
"\n", $a_text);
940 $a_text = str_replace(
"<br/>",
"\n", $a_text);
943 $a_text = str_replace(
"{",
"{", $a_text);
944 $a_text = str_replace(
"}",
"}", $a_text);
947 $a_text = str_replace(
"<",
"<", $a_text);
948 $a_text = str_replace(
">",
">",$a_text);
951 $a_text = str_replace(
""",
"\"", $a_text);
955 $a_text = str_replace(
"&",
"&", $a_text);
958 $a_text = str_replace(
"<",
"&lt;", $a_text);
959 $a_text = str_replace(
">",
"&gt;", $a_text);
973 $a_text = str_replace (
"=<SimpleBulletList>",
"=<br /><SimpleBulletList>", $a_text);
974 $a_text = str_replace (
"=<SimpleNumberedList>",
"=<br /><SimpleNumberedList>", $a_text);
975 $a_text = str_replace (
"</SimpleBulletList>=",
"</SimpleBulletList><br />=", $a_text);
976 $a_text = str_replace (
"</SimpleNumberedList>=",
"</SimpleNumberedList><br />=", $a_text);
977 $a_text =
"<br />".$a_text.
"<br />";
982 while ($c_text !=
"")
986 $s1 = strpos($c_text,
"<br />=");
990 $s2 = strpos($c_text,
"<br />==");
991 if (is_int($s2) && $s2 <= $s1)
994 $s3 = strpos($c_text,
"<br />===");
995 if (is_int($s3) && $s3 <= $s2)
998 $n = strpos($c_text,
"<br />", $s3 + 1);
999 if (
$n > ($s3+9) && substr($c_text,
$n-3, 9) ==
"===<br />")
1003 if ($s3 > 0 || $head !=
"")
1006 $chunks[] = array(
"level" => 0,
1010 $chunks[] = array(
"level" => 3,
1011 "text" => trim(substr($c_text, $s3+9,
$n-$s3-12)));
1017 $head.= substr($c_text, 0,
$n);
1018 $c_text = substr($c_text,
$n);
1024 $n = strpos($c_text,
"<br />", $s2 + 1);
1025 if (
$n > ($s2+8) && substr($c_text,
$n-2, 8) ==
"==<br />")
1029 if ($s2 > 0 || $head !=
"")
1032 $chunks[] = array(
"level" => 0,
1036 $chunks[] = array(
"level" => 2,
"text" => trim(substr($c_text, $s2+8,
$n-$s2-10)));
1042 $head.= substr($c_text, 0,
$n);
1043 $c_text = substr($c_text,
$n);
1050 $n = strpos($c_text,
"<br />", $s1 + 1);
1051 if (
$n > ($s1+7) && substr($c_text,
$n-1, 7) ==
"=<br />")
1055 if ($s1 > 0 || $head !=
"")
1058 $chunks[] = array(
"level" => 0,
1062 $chunks[] = array(
"level" => 1,
"text" => trim(substr($c_text, $s1+7,
$n-$s1-8)));
1068 $head.= substr($c_text, 0,
$n);
1069 $c_text = substr($c_text,
$n);
1077 $chunks[] = array(
"level" => 0,
"text" => $head.$c_text);
1082 if (count($chunks) == 0)
1084 $chunks[] = array(
"level" => 0,
"text" =>
"");
1089 if (substr($chunks[0][
"text"], 0, 6) ==
"<br />")
1091 $chunks[0][
"text"] = substr($chunks[0][
"text"], 6);
1095 if (substr($chunks[count($chunks) - 1][
"text"],
1096 strlen($chunks[count($chunks) - 1][
"text"]) - 6, 6) ==
"<br />")
1098 $chunks[count($chunks) - 1][
"text"] =
1099 substr($chunks[count($chunks) - 1][
"text"], 0, strlen($chunks[count($chunks) - 1][
"text"]) - 6);
1100 if ($chunks[count($chunks) - 1][
"text"] ==
"")
1102 unset($chunks[count($chunks) - 1]);
1115 if (substr($a_str, 0, 6) ==
"<br />" && substr($a_str, 6, 1) !=
"=")
1117 $a_str = substr($a_str, 6);
1123 if (substr($a_str, 0, 1) ==
"=")
1125 $a_str =
"<br />".$a_str;
1136 if (substr($a_str, strlen($a_str) - 6) ==
"<br />")
1138 $a_str = substr($a_str, 0, strlen($a_str) - 6);