javascriptcursus/php/geshi/docs/api/__filesource/fsource_geshi_core_geshi.php.html

<?xml version="1.0" encoding="iso-8859-1"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <!-- template designed by Marco Von Ballmoos --> <title>File Source for geshi.php</title> <link rel="stylesheet" href="../media/stylesheet.css" /> <meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/> </head> <body> <h1>Source for file geshi.php</h1> <p>Documentation is available at <a href="../geshi/core/_geshi.php.html">geshi.php</a></p> <div class="src-code"> <div class="src-code"><ol><li><div class="src-line"><a name="a1"></a><span class="src-php">&lt;?php</span></div></li> <li><div class="src-line"><a name="a2"></a><span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a3"></a><span class="src-doc">&nbsp;*&nbsp;GeSHi&nbsp;-&nbsp;Generic&nbsp;Syntax&nbsp;Highlighter</span></div></li> <li><div class="src-line"><a name="a4"></a><span class="src-doc">&nbsp;*</span></div></li> <li><div class="src-line"><a name="a5"></a><span class="src-doc">&nbsp;*&nbsp;The&nbsp;GeSHi&nbsp;class&nbsp;for&nbsp;Generic&nbsp;Syntax&nbsp;Highlighting.&nbsp;Please&nbsp;refer&nbsp;to&nbsp;the</span></div></li> <li><div class="src-line"><a name="a6"></a><span class="src-doc">&nbsp;*&nbsp;documentation&nbsp;at&nbsp;http://qbnz.com/highlighter/documentation.php&nbsp;for&nbsp;more</span></div></li> <li><div class="src-line"><a name="a7"></a><span class="src-doc">&nbsp;*&nbsp;information&nbsp;about&nbsp;how&nbsp;to&nbsp;use&nbsp;this&nbsp;class.</span></div></li> <li><div class="src-line"><a name="a8"></a><span class="src-doc">&nbsp;*</span></div></li> <li><div class="src-line"><a name="a9"></a><span class="src-doc">&nbsp;*&nbsp;For&nbsp;changes,&nbsp;release&nbsp;notes,&nbsp;TODOs&nbsp;etc,&nbsp;see&nbsp;the&nbsp;relevant&nbsp;files&nbsp;in&nbsp;the&nbsp;docs/</span></div></li> <li><div class="src-line"><a name="a10"></a><span class="src-doc">&nbsp;*&nbsp;directory.</span></div></li> <li><div class="src-line"><a name="a11"></a><span class="src-doc">&nbsp;*</span></div></li> <li><div class="src-line"><a name="a12"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;&nbsp;This&nbsp;file&nbsp;is&nbsp;part&nbsp;of&nbsp;GeSHi.</span></div></li> <li><div class="src-line"><a name="a13"></a><span class="src-doc">&nbsp;*</span></div></li> <li><div class="src-line"><a name="a14"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;GeSHi&nbsp;is&nbsp;free&nbsp;software;&nbsp;you&nbsp;can&nbsp;redistribute&nbsp;it&nbsp;and/or&nbsp;modify</span></div></li> <li><div class="src-line"><a name="a15"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;it&nbsp;under&nbsp;the&nbsp;terms&nbsp;of&nbsp;the&nbsp;GNU&nbsp;General&nbsp;Public&nbsp;License&nbsp;as&nbsp;published&nbsp;by</span></div></li> <li><div class="src-line"><a name="a16"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;the&nbsp;Free&nbsp;Software&nbsp;Foundation;&nbsp;either&nbsp;version&nbsp;2&nbsp;of&nbsp;the&nbsp;License,&nbsp;or</span></div></li> <li><div class="src-line"><a name="a17"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;(at&nbsp;your&nbsp;option)&nbsp;any&nbsp;later&nbsp;version.</span></div></li> <li><div class="src-line"><a name="a18"></a><span class="src-doc">&nbsp;*</span></div></li> <li><div class="src-line"><a name="a19"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;GeSHi&nbsp;is&nbsp;distributed&nbsp;in&nbsp;the&nbsp;hope&nbsp;that&nbsp;it&nbsp;will&nbsp;be&nbsp;useful,</span></div></li> <li><div class="src-line"><a name="a20"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;but&nbsp;WITHOUT&nbsp;ANY&nbsp;WARRANTY;&nbsp;without&nbsp;even&nbsp;the&nbsp;implied&nbsp;warranty&nbsp;of</span></div></li> <li><div class="src-line"><a name="a21"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;MERCHANTABILITY&nbsp;or&nbsp;FITNESS&nbsp;FOR&nbsp;A&nbsp;PARTICULAR&nbsp;PURPOSE.&nbsp;&nbsp;See&nbsp;the</span></div></li> <li><div class="src-line"><a name="a22"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;GNU&nbsp;General&nbsp;Public&nbsp;License&nbsp;for&nbsp;more&nbsp;details.</span></div></li> <li><div class="src-line"><a name="a23"></a><span class="src-doc">&nbsp;*</span></div></li> <li><div class="src-line"><a name="a24"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;You&nbsp;should&nbsp;have&nbsp;received&nbsp;a&nbsp;copy&nbsp;of&nbsp;the&nbsp;GNU&nbsp;General&nbsp;Public&nbsp;License</span></div></li> <li><div class="src-line"><a name="a25"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;along&nbsp;with&nbsp;GeSHi;&nbsp;if&nbsp;not,&nbsp;write&nbsp;to&nbsp;the&nbsp;Free&nbsp;Software</span></div></li> <li><div class="src-line"><a name="a26"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;Foundation,&nbsp;Inc.,&nbsp;59&nbsp;Temple&nbsp;Place,&nbsp;Suite&nbsp;330,&nbsp;Boston,&nbsp;MA&nbsp;&nbsp;02111-1307&nbsp;&nbsp;USA</span></div></li> <li><div class="src-line"><a name="a27"></a><span class="src-doc">&nbsp;*</span></div></li> <li><div class="src-line"><a name="a28"></a><span class="src-doc">&nbsp;*&nbsp;</span><span class="src-doc-coretag">@package</span><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;geshi</span></div></li> <li><div class="src-line"><a name="a29"></a><span class="src-doc">&nbsp;*&nbsp;</span><span class="src-doc-coretag">@subpackage</span><span class="src-doc">&nbsp;core</span></div></li> <li><div class="src-line"><a name="a30"></a><span class="src-doc">&nbsp;*&nbsp;</span><span class="src-doc-coretag">@author</span><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Nigel&nbsp;McNie&nbsp;&lt;nigel@geshi.org&gt;,&nbsp;Benny&nbsp;Baumann&nbsp;&lt;BenBE@omorphia.de&gt;</span></div></li> <li><div class="src-line"><a name="a31"></a><span class="src-doc">&nbsp;*&nbsp;</span><span class="src-doc-coretag">@copyright</span><span class="src-doc">&nbsp;&nbsp;(C)&nbsp;2004&nbsp;-&nbsp;2007&nbsp;Nigel&nbsp;McNie,&nbsp;(C)&nbsp;2007&nbsp;-&nbsp;2008&nbsp;Benny&nbsp;Baumann</span></div></li> <li><div class="src-line"><a name="a32"></a><span class="src-doc">&nbsp;*&nbsp;</span><span class="src-doc-coretag">@license</span><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;http://gnu.org/copyleft/gpl.html&nbsp;GNU&nbsp;GPL</span></div></li> <li><div class="src-line"><a name="a33"></a><span class="src-doc">&nbsp;*</span></div></li> <li><div class="src-line"><a name="a34"></a><span class="src-doc">&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a35"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a36"></a><span class="src-comm">//</span></div></li> <li><div class="src-line"><a name="a37"></a><span class="src-comm">//&nbsp;GeSHi&nbsp;Constants</span></div></li> <li><div class="src-line"><a name="a38"></a><span class="src-comm">//&nbsp;You&nbsp;should&nbsp;use&nbsp;these&nbsp;constant&nbsp;names&nbsp;in&nbsp;your&nbsp;programs&nbsp;instead&nbsp;of</span></div></li> <li><div class="src-line"><a name="a39"></a><span class="src-comm">//&nbsp;their&nbsp;values&nbsp;-&nbsp;you&nbsp;never&nbsp;know&nbsp;when&nbsp;a&nbsp;value&nbsp;may&nbsp;change&nbsp;in&nbsp;a&nbsp;future</span></div></li> <li><div class="src-line"><a name="a40"></a><span class="src-comm">//&nbsp;version</span></div></li> <li><div class="src-line"><a name="a41"></a><span class="src-comm">//</span></div></li> <li><div class="src-line"><a name="a42"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a43"></a><span class="src-doc">/**&nbsp;The&nbsp;version&nbsp;of&nbsp;this&nbsp;GeSHi&nbsp;file&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a44"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_VERSION'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'1.0.8.2'</span><span class="src-sym">,</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a45"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a46"></a><span class="src-comm">//&nbsp;Define&nbsp;the&nbsp;root&nbsp;directory&nbsp;for&nbsp;the&nbsp;GeSHi&nbsp;code&nbsp;tree</span></div></li> <li><div class="src-line"><a name="a47"></a><span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span><a href="http://www.php.net/defined">defined</a><span class="src-sym">(</span><span class="src-str">'GESHI_ROOT'</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a48"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**&nbsp;The&nbsp;root&nbsp;directory&nbsp;for&nbsp;GeSHi&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a49"></a>&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_ROOT'</span><span class="src-sym">,&nbsp;</span><span class="src-id">dirname</span><span class="src-sym">(</span>__FILE__<span class="src-sym">)&nbsp;</span>.&nbsp;<span class="src-id">DIRECTORY_SEPARATOR</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a50"></a><span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a51"></a><span class="src-doc">/**&nbsp;The&nbsp;language&nbsp;file&nbsp;directory&nbsp;for&nbsp;GeSHi</span></div></li> <li><div class="src-line"><a name="a52"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;@access&nbsp;private&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a53"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_LANG_ROOT'</span><span class="src-sym">,&nbsp;</span><span class="src-id">GESHI_ROOT&nbsp;</span>.&nbsp;<span class="src-str">'geshi'&nbsp;</span>.&nbsp;<span class="src-id">DIRECTORY_SEPARATOR</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a54"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a55"></a><span class="src-comm">//&nbsp;Define&nbsp;if&nbsp;GeSHi&nbsp;should&nbsp;be&nbsp;paranoid&nbsp;about&nbsp;security</span></div></li> <li><div class="src-line"><a name="a56"></a><span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span><a href="http://www.php.net/defined">defined</a><span class="src-sym">(</span><span class="src-str">'GESHI_SECURITY_PARANOID'</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a57"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**&nbsp;Tells&nbsp;GeSHi&nbsp;to&nbsp;be&nbsp;paranoid&nbsp;about&nbsp;security&nbsp;settings&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a58"></a>&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_SECURITY_PARANOID'</span><span class="src-sym">,&nbsp;</span><span class="src-id">false</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a59"></a><span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a60"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a61"></a><span class="src-comm">//&nbsp;Line&nbsp;numbers&nbsp;-&nbsp;use&nbsp;with&nbsp;enable_line_numbers()</span></div></li> <li><div class="src-line"><a name="a62"></a><span class="src-doc">/**&nbsp;Use&nbsp;no&nbsp;line&nbsp;numbers&nbsp;when&nbsp;building&nbsp;the&nbsp;result&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a63"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NO_LINE_NUMBERS'</span><span class="src-sym">,&nbsp;</span><span class="src-num">0</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a64"></a><span class="src-doc">/**&nbsp;Use&nbsp;normal&nbsp;line&nbsp;numbers&nbsp;when&nbsp;building&nbsp;the&nbsp;result&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a65"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NORMAL_LINE_NUMBERS'</span><span class="src-sym">,&nbsp;</span><span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a66"></a><span class="src-doc">/**&nbsp;Use&nbsp;fancy&nbsp;line&nbsp;numbers&nbsp;when&nbsp;building&nbsp;the&nbsp;result&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a67"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_FANCY_LINE_NUMBERS'</span><span class="src-sym">,&nbsp;</span><span class="src-num">2</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a68"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a69"></a><span class="src-comm">//&nbsp;Container&nbsp;HTML&nbsp;type</span></div></li> <li><div class="src-line"><a name="a70"></a><span class="src-doc">/**&nbsp;Use&nbsp;nothing&nbsp;to&nbsp;surround&nbsp;the&nbsp;source&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a71"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_HEADER_NONE'</span><span class="src-sym">,&nbsp;</span><span class="src-num">0</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a72"></a><span class="src-doc">/**&nbsp;Use&nbsp;a&nbsp;&quot;div&quot;&nbsp;to&nbsp;surround&nbsp;the&nbsp;source&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a73"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_HEADER_DIV'</span><span class="src-sym">,&nbsp;</span><span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a74"></a><span class="src-doc">/**&nbsp;Use&nbsp;a&nbsp;&quot;pre&quot;&nbsp;to&nbsp;surround&nbsp;the&nbsp;source&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a75"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_HEADER_PRE'</span><span class="src-sym">,&nbsp;</span><span class="src-num">2</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a76"></a><span class="src-doc">/**&nbsp;Use&nbsp;a&nbsp;pre&nbsp;to&nbsp;wrap&nbsp;lines&nbsp;when&nbsp;line&nbsp;numbers&nbsp;are&nbsp;enabled&nbsp;or&nbsp;to&nbsp;wrap&nbsp;the&nbsp;whole&nbsp;code.&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a77"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_HEADER_PRE_VALID'</span><span class="src-sym">,&nbsp;</span><span class="src-num">3</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a78"></a><span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a79"></a><span class="src-doc">&nbsp;*&nbsp;Use&nbsp;a&nbsp;&quot;table&quot;&nbsp;to&nbsp;surround&nbsp;the&nbsp;source:</span></div></li> <li><div class="src-line"><a name="a80"></a><span class="src-doc">&nbsp;*</span></div></li> <li><div class="src-line"><a name="a81"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;&lt;table&gt;</span></div></li> <li><div class="src-line"><a name="a82"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&lt;thead&gt;&lt;tr&gt;&lt;td&nbsp;colspan=&quot;2&quot;&gt;$header&lt;/td&gt;&lt;/tr&gt;&lt;/thead&gt;</span></div></li> <li><div class="src-line"><a name="a83"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;&lt;pre&gt;$linenumbers&lt;/pre&gt;&lt;/td&gt;&lt;td&gt;&lt;pre&gt;$code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;</span></div></li> <li><div class="src-line"><a name="a84"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&lt;tfooter&gt;&lt;tr&gt;&lt;td&nbsp;colspan=&quot;2&quot;&gt;$footer&lt;/td&gt;&lt;/tr&gt;&lt;/tfoot&gt;</span></div></li> <li><div class="src-line"><a name="a85"></a><span class="src-doc">&nbsp;*&nbsp;&nbsp;&lt;/table&gt;</span></div></li> <li><div class="src-line"><a name="a86"></a><span class="src-doc">&nbsp;*</span></div></li> <li><div class="src-line"><a name="a87"></a><span class="src-doc">&nbsp;*&nbsp;this&nbsp;is&nbsp;essentially&nbsp;only&nbsp;a&nbsp;workaround&nbsp;for&nbsp;Firefox,&nbsp;see&nbsp;sf#1651996&nbsp;or&nbsp;take&nbsp;a&nbsp;look&nbsp;at</span></div></li> <li><div class="src-line"><a name="a88"></a><span class="src-doc">&nbsp;*&nbsp;https://bugzilla.mozilla.org/show_bug.cgi?id=365805</span></div></li> <li><div class="src-line"><a name="a89"></a><span class="src-doc">&nbsp;*&nbsp;</span><span class="src-doc-tag">@note</span><span class="src-doc">&nbsp;when&nbsp;linenumbers&nbsp;are&nbsp;disabled&nbsp;this&nbsp;is&nbsp;essentially&nbsp;the&nbsp;same&nbsp;as&nbsp;GESHI_HEADER_PRE</span></div></li> <li><div class="src-line"><a name="a90"></a><span class="src-doc">&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a91"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_HEADER_PRE_TABLE'</span><span class="src-sym">,&nbsp;</span><span class="src-num">4</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a92"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a93"></a><span class="src-comm">//&nbsp;Capatalisation&nbsp;constants</span></div></li> <li><div class="src-line"><a name="a94"></a><span class="src-doc">/**&nbsp;Lowercase&nbsp;keywords&nbsp;found&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a95"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_CAPS_NO_CHANGE'</span><span class="src-sym">,&nbsp;</span><span class="src-num">0</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a96"></a><span class="src-doc">/**&nbsp;Uppercase&nbsp;keywords&nbsp;found&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a97"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_CAPS_UPPER'</span><span class="src-sym">,&nbsp;</span><span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a98"></a><span class="src-doc">/**&nbsp;Leave&nbsp;keywords&nbsp;found&nbsp;as&nbsp;the&nbsp;case&nbsp;that&nbsp;they&nbsp;are&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a99"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_CAPS_LOWER'</span><span class="src-sym">,&nbsp;</span><span class="src-num">2</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a100"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a101"></a><span class="src-comm">//&nbsp;Link&nbsp;style&nbsp;constants</span></div></li> <li><div class="src-line"><a name="a102"></a><span class="src-doc">/**&nbsp;Links&nbsp;in&nbsp;the&nbsp;source&nbsp;in&nbsp;the&nbsp;:link&nbsp;state&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a103"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_LINK'</span><span class="src-sym">,&nbsp;</span><span class="src-num">0</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a104"></a><span class="src-doc">/**&nbsp;Links&nbsp;in&nbsp;the&nbsp;source&nbsp;in&nbsp;the&nbsp;:hover&nbsp;state&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a105"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_HOVER'</span><span class="src-sym">,&nbsp;</span><span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a106"></a><span class="src-doc">/**&nbsp;Links&nbsp;in&nbsp;the&nbsp;source&nbsp;in&nbsp;the&nbsp;:active&nbsp;state&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a107"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_ACTIVE'</span><span class="src-sym">,&nbsp;</span><span class="src-num">2</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a108"></a><span class="src-doc">/**&nbsp;Links&nbsp;in&nbsp;the&nbsp;source&nbsp;in&nbsp;the&nbsp;:visited&nbsp;state&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a109"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_VISITED'</span><span class="src-sym">,&nbsp;</span><span class="src-num">3</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a110"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a111"></a><span class="src-comm">//&nbsp;Important&nbsp;string&nbsp;starter/finisher</span></div></li> <li><div class="src-line"><a name="a112"></a><span class="src-comm">//&nbsp;Note&nbsp;that&nbsp;if&nbsp;you&nbsp;change&nbsp;these,&nbsp;they&nbsp;should&nbsp;be&nbsp;as-is:&nbsp;i.e.,&nbsp;don't</span></div></li> <li><div class="src-line"><a name="a113"></a><span class="src-comm">//&nbsp;write&nbsp;them&nbsp;as&nbsp;if&nbsp;they&nbsp;had&nbsp;been&nbsp;run&nbsp;through&nbsp;htmlentities()</span></div></li> <li><div class="src-line"><a name="a114"></a><span class="src-doc">/**&nbsp;The&nbsp;starter&nbsp;for&nbsp;important&nbsp;parts&nbsp;of&nbsp;the&nbsp;source&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a115"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_START_IMPORTANT'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'&lt;BEGIN&nbsp;GeSHi&gt;'</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a116"></a><span class="src-doc">/**&nbsp;The&nbsp;ender&nbsp;for&nbsp;important&nbsp;parts&nbsp;of&nbsp;the&nbsp;source&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a117"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_END_IMPORTANT'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'&lt;END&nbsp;GeSHi&gt;'</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a118"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a119"></a><span class="src-comm">/**#@+</span></div></li> <li><div class="src-line"><a name="a120"></a><span class="src-comm">&nbsp;*&nbsp;&nbsp;@access&nbsp;private</span></div></li> <li><div class="src-line"><a name="a121"></a><span class="src-comm">&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a122"></a><span class="src-comm">//&nbsp;When&nbsp;strict&nbsp;mode&nbsp;applies&nbsp;for&nbsp;a&nbsp;language</span></div></li> <li><div class="src-line"><a name="a123"></a><span class="src-doc">/**&nbsp;Strict&nbsp;mode&nbsp;never&nbsp;applies&nbsp;(this&nbsp;is&nbsp;the&nbsp;most&nbsp;common)&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a124"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NEVER'</span><span class="src-sym">,&nbsp;</span><span class="src-num">0</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a125"></a><span class="src-doc">/**&nbsp;Strict&nbsp;mode&nbsp;*might*&nbsp;apply,&nbsp;and&nbsp;can&nbsp;be&nbsp;enabled&nbsp;or</span></div></li> <li><div class="src-line"><a name="a126"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;disabled&nbsp;by&nbsp;</span><span class="src-doc-inlinetag">{@link&nbsp;GeSHi-&gt;enable_strict_mode()}</span><span class="src-doc">&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a127"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_MAYBE'</span><span class="src-sym">,&nbsp;</span><span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a128"></a><span class="src-doc">/**&nbsp;Strict&nbsp;mode&nbsp;always&nbsp;applies&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a129"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_ALWAYS'</span><span class="src-sym">,&nbsp;</span><span class="src-num">2</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a130"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a131"></a><span class="src-comm">//&nbsp;Advanced&nbsp;regexp&nbsp;handling&nbsp;constants,&nbsp;used&nbsp;in&nbsp;language&nbsp;files</span></div></li> <li><div class="src-line"><a name="a132"></a><span class="src-doc">/**&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;regex&nbsp;array&nbsp;defining&nbsp;what&nbsp;to&nbsp;search&nbsp;for&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a133"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_SEARCH'</span><span class="src-sym">,&nbsp;</span><span class="src-num">0</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a134"></a><span class="src-doc">/**&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;regex&nbsp;array&nbsp;defining&nbsp;what&nbsp;bracket&nbsp;group&nbsp;in&nbsp;a</span></div></li> <li><div class="src-line"><a name="a135"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;matched&nbsp;search&nbsp;to&nbsp;use&nbsp;as&nbsp;a&nbsp;replacement&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a136"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_REPLACE'</span><span class="src-sym">,&nbsp;</span><span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a137"></a><span class="src-doc">/**&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;regex&nbsp;array&nbsp;defining&nbsp;any&nbsp;modifiers&nbsp;to&nbsp;the&nbsp;regular&nbsp;expression&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a138"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_MODIFIERS'</span><span class="src-sym">,&nbsp;</span><span class="src-num">2</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a139"></a><span class="src-doc">/**&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;regex&nbsp;array&nbsp;defining&nbsp;what&nbsp;bracket&nbsp;group&nbsp;in&nbsp;a</span></div></li> <li><div class="src-line"><a name="a140"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;matched&nbsp;search&nbsp;to&nbsp;put&nbsp;before&nbsp;the&nbsp;replacement&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a141"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_BEFORE'</span><span class="src-sym">,&nbsp;</span><span class="src-num">3</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a142"></a><span class="src-doc">/**&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;regex&nbsp;array&nbsp;defining&nbsp;what&nbsp;bracket&nbsp;group&nbsp;in&nbsp;a</span></div></li> <li><div class="src-line"><a name="a143"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;matched&nbsp;search&nbsp;to&nbsp;put&nbsp;after&nbsp;the&nbsp;replacement&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a144"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_AFTER'</span><span class="src-sym">,&nbsp;</span><span class="src-num">4</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a145"></a><span class="src-doc">/**&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;regex&nbsp;array&nbsp;defining&nbsp;a&nbsp;custom&nbsp;keyword&nbsp;to&nbsp;use</span></div></li> <li><div class="src-line"><a name="a146"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;for&nbsp;this&nbsp;regexp's&nbsp;html&nbsp;tag&nbsp;class&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a147"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_CLASS'</span><span class="src-sym">,&nbsp;</span><span class="src-num">5</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a148"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a149"></a><span class="src-doc">/**&nbsp;Used&nbsp;in&nbsp;language&nbsp;files&nbsp;to&nbsp;mark&nbsp;comments&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a150"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_COMMENTS'</span><span class="src-sym">,&nbsp;</span><span class="src-num">0</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a151"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a152"></a><span class="src-doc">/**&nbsp;Used&nbsp;to&nbsp;work&nbsp;around&nbsp;missing&nbsp;PHP&nbsp;features&nbsp;**/</span></div></li> <li><div class="src-line"><a name="a153"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_PHP_PRE_433'</span><span class="src-sym">,&nbsp;</span><span class="src-sym">!</span><span class="src-sym">(</span><span class="src-id">version_compare</span><span class="src-sym">(</span><span class="src-id">PHP_VERSION</span><span class="src-sym">,&nbsp;</span><span class="src-str">'4.3.3'</span><span class="src-sym">)&nbsp;</span>===&nbsp;<span class="src-num">1</span><span class="src-sym">))</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a154"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a155"></a><span class="src-doc">/**&nbsp;make&nbsp;sure&nbsp;we&nbsp;can&nbsp;call&nbsp;stripos&nbsp;**/</span></div></li> <li><div class="src-line"><a name="a156"></a><span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span><a href="http://www.php.net/function_exists">function_exists</a><span class="src-sym">(</span><span class="src-str">'stripos'</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a157"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;the&nbsp;offset&nbsp;param&nbsp;of&nbsp;preg_match&nbsp;is&nbsp;not&nbsp;supported&nbsp;below&nbsp;PHP&nbsp;4.3.3</span></div></li> <li><div class="src-line"><a name="a158"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-id">GESHI_PHP_PRE_433</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a159"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a160"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@ignore</span></div></li> <li><div class="src-line"><a name="a161"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a162"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function&nbsp;</span><a href="http://www.php.net/stripos">stripos</a><span class="src-sym">(</span><span class="src-var">$haystack</span><span class="src-sym">,&nbsp;</span><span class="src-var">$needle</span><span class="src-sym">,&nbsp;</span><span class="src-var">$offset&nbsp;</span>=&nbsp;<span class="src-id">null</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a163"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span><a href="http://www.php.net/is_null">is_null</a><span class="src-sym">(</span><span class="src-var">$offset</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a164"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$haystack&nbsp;</span>=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$haystack</span><span class="src-sym">,&nbsp;</span><span class="src-var">$offset</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a165"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a166"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><a href="http://www.php.net/preg_match">preg_match</a><span class="src-sym">(</span><span class="src-str">'/'</span>.&nbsp;<a href="http://www.php.net/preg_quote">preg_quote</a><span class="src-sym">(</span><span class="src-var">$needle</span><span class="src-sym">,&nbsp;</span><span class="src-str">'/'</span><span class="src-sym">)&nbsp;</span>.&nbsp;<span class="src-str">'/'</span><span class="src-sym">,&nbsp;</span><span class="src-var">$haystack</span><span class="src-sym">,&nbsp;</span><span class="src-var">$match</span><span class="src-sym">,&nbsp;</span><span class="src-id">PREG_OFFSET_CAPTURE</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a167"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><span class="src-var">$match</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a168"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a169"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><span class="src-id">false</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a170"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a171"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a172"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">else&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a173"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a174"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@ignore</span></div></li> <li><div class="src-line"><a name="a175"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a176"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function&nbsp;</span><a href="http://www.php.net/stripos">stripos</a><span class="src-sym">(</span><span class="src-var">$haystack</span><span class="src-sym">,&nbsp;</span><span class="src-var">$needle</span><span class="src-sym">,&nbsp;</span><span class="src-var">$offset&nbsp;</span>=&nbsp;<span class="src-id">null</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a177"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><a href="http://www.php.net/preg_match">preg_match</a><span class="src-sym">(</span><span class="src-str">'/'</span>.&nbsp;<a href="http://www.php.net/preg_quote">preg_quote</a><span class="src-sym">(</span><span class="src-var">$needle</span><span class="src-sym">,&nbsp;</span><span class="src-str">'/'</span><span class="src-sym">)&nbsp;</span>.&nbsp;<span class="src-str">'/'</span><span class="src-sym">,&nbsp;</span><span class="src-var">$haystack</span><span class="src-sym">,&nbsp;</span><span class="src-var">$match</span><span class="src-sym">,&nbsp;</span><span class="src-id">PREG_OFFSET_CAPTURE</span><span class="src-sym">,&nbsp;</span><span class="src-var">$offset</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a178"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><span class="src-var">$match</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a179"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a180"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><span class="src-id">false</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a181"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a182"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a183"></a><span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a184"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a185"></a><span class="src-doc">/**&nbsp;some&nbsp;old&nbsp;PHP&nbsp;/&nbsp;PCRE&nbsp;subpatterns&nbsp;only&nbsp;support&nbsp;up&nbsp;to&nbsp;xxx&nbsp;subpatterns&nbsp;in</span></div></li> <li><div class="src-line"><a name="a186"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;regular&nbsp;expressions.&nbsp;Set&nbsp;this&nbsp;to&nbsp;false&nbsp;if&nbsp;your&nbsp;PCRE&nbsp;lib&nbsp;is&nbsp;up&nbsp;to&nbsp;date</span></div></li> <li><div class="src-line"><a name="a187"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;@see&nbsp;GeSHi-&gt;optimize_regexp_list()</span></div></li> <li><div class="src-line"><a name="a188"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;**/</span></div></li> <li><div class="src-line"><a name="a188"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a189"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_MAX_PCRE_SUBPATTERNS'</span><span class="src-sym">,&nbsp;</span><span class="src-num">500</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a190"></a><span class="src-doc">/**&nbsp;it's&nbsp;also&nbsp;important&nbsp;not&nbsp;to&nbsp;generate&nbsp;too&nbsp;long&nbsp;regular&nbsp;expressions</span></div></li> <li><div class="src-line"><a name="a191"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;be&nbsp;generous&nbsp;here...&nbsp;but&nbsp;keep&nbsp;in&nbsp;mind,&nbsp;that&nbsp;when&nbsp;reaching&nbsp;this&nbsp;limit&nbsp;we</span></div></li> <li><div class="src-line"><a name="a192"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;still&nbsp;have&nbsp;to&nbsp;close&nbsp;open&nbsp;patterns.&nbsp;12k&nbsp;should&nbsp;do&nbsp;just&nbsp;fine&nbsp;on&nbsp;a&nbsp;16k&nbsp;limit.</span></div></li> <li><div class="src-line"><a name="a193"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;@see&nbsp;GeSHi-&gt;optimize_regexp_list()</span></div></li> <li><div class="src-line"><a name="a194"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;**/</span></div></li> <li><div class="src-line"><a name="a194"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a195"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_MAX_PCRE_LENGTH'</span><span class="src-sym">,&nbsp;</span><span class="src-num">12288</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a196"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a197"></a><span class="src-comm">//Number&nbsp;format&nbsp;specification</span></div></li> <li><div class="src-line"><a name="a198"></a><span class="src-doc">/**&nbsp;Basic&nbsp;number&nbsp;format&nbsp;for&nbsp;integers&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a199"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_INT_BASIC'</span><span class="src-sym">,&nbsp;</span><span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//Default&nbsp;integers&nbsp;\d+</span></div></li> <li><div class="src-line"><a name="a200"></a><span class="src-doc">/**&nbsp;Enhanced&nbsp;number&nbsp;format&nbsp;for&nbsp;integers&nbsp;like&nbsp;seen&nbsp;in&nbsp;C&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a201"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_INT_CSTYLE'</span><span class="src-sym">,&nbsp;</span><span class="src-num">2</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//Default&nbsp;C-Style&nbsp;\d+[lL]?</span></div></li> <li><div class="src-line"><a name="a202"></a><span class="src-doc">/**&nbsp;Number&nbsp;format&nbsp;to&nbsp;highlight&nbsp;binary&nbsp;numbers&nbsp;with&nbsp;a&nbsp;suffix&nbsp;&quot;b&quot;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a203"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_BIN_SUFFIX'</span><span class="src-sym">,&nbsp;</span><span class="src-num">16</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//[01]+[bB]</span></div></li> <li><div class="src-line"><a name="a204"></a><span class="src-doc">/**&nbsp;Number&nbsp;format&nbsp;to&nbsp;highlight&nbsp;binary&nbsp;numbers&nbsp;with&nbsp;a&nbsp;prefix&nbsp;%&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a205"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_BIN_PREFIX_PERCENT'</span><span class="src-sym">,&nbsp;</span><span class="src-num">32</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//%[01]+</span></div></li> <li><div class="src-line"><a name="a206"></a><span class="src-doc">/**&nbsp;Number&nbsp;format&nbsp;to&nbsp;highlight&nbsp;binary&nbsp;numbers&nbsp;with&nbsp;a&nbsp;prefix&nbsp;0b&nbsp;(C)&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a207"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_BIN_PREFIX_0B'</span><span class="src-sym">,&nbsp;</span><span class="src-num">64</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//0b[01]+</span></div></li> <li><div class="src-line"><a name="a208"></a><span class="src-doc">/**&nbsp;Number&nbsp;format&nbsp;to&nbsp;highlight&nbsp;octal&nbsp;numbers&nbsp;with&nbsp;a&nbsp;leading&nbsp;zero&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a209"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_OCT_PREFIX'</span><span class="src-sym">,&nbsp;</span><span class="src-num">256</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//0[0-7]+</span></div></li> <li><div class="src-line"><a name="a210"></a><span class="src-doc">/**&nbsp;Number&nbsp;format&nbsp;to&nbsp;highlight&nbsp;octal&nbsp;numbers&nbsp;with&nbsp;a&nbsp;suffix&nbsp;of&nbsp;o&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a211"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_OCT_SUFFIX'</span><span class="src-sym">,&nbsp;</span><span class="src-num">512</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//[0-7]+[oO]</span></div></li> <li><div class="src-line"><a name="a212"></a><span class="src-doc">/**&nbsp;Number&nbsp;format&nbsp;to&nbsp;highlight&nbsp;hex&nbsp;numbers&nbsp;with&nbsp;a&nbsp;prefix&nbsp;0x&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a213"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_HEX_PREFIX'</span><span class="src-sym">,&nbsp;</span><span class="src-num">4096</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//0x[0-9a-fA-F]+</span></div></li> <li><div class="src-line"><a name="a214"></a><span class="src-doc">/**&nbsp;Number&nbsp;format&nbsp;to&nbsp;highlight&nbsp;hex&nbsp;numbers&nbsp;with&nbsp;a&nbsp;suffix&nbsp;of&nbsp;h&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a215"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_HEX_SUFFIX'</span><span class="src-sym">,&nbsp;</span><span class="src-num">8192</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//[0-9][0-9a-fA-F]*h</span></div></li> <li><div class="src-line"><a name="a216"></a><span class="src-doc">/**&nbsp;Number&nbsp;format&nbsp;to&nbsp;highlight&nbsp;floating-point&nbsp;numbers&nbsp;without&nbsp;support&nbsp;for&nbsp;scientific&nbsp;notation&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a217"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_FLT_NONSCI'</span><span class="src-sym">,&nbsp;</span><span class="src-num">65536</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//\d+\.\d+</span></div></li> <li><div class="src-line"><a name="a218"></a><span class="src-doc">/**&nbsp;Number&nbsp;format&nbsp;to&nbsp;highlight&nbsp;floating-point&nbsp;numbers&nbsp;without&nbsp;support&nbsp;for&nbsp;scientific&nbsp;notation&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a219"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_FLT_NONSCI_F'</span><span class="src-sym">,&nbsp;</span><span class="src-num">131072</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//\d+(\.\d+)?f</span></div></li> <li><div class="src-line"><a name="a220"></a><span class="src-doc">/**&nbsp;Number&nbsp;format&nbsp;to&nbsp;highlight&nbsp;floating-point&nbsp;numbers&nbsp;with&nbsp;support&nbsp;for&nbsp;scientific&nbsp;notation&nbsp;(E)&nbsp;and&nbsp;optional&nbsp;leading&nbsp;zero&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a221"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_FLT_SCI_SHORT'</span><span class="src-sym">,&nbsp;</span><span class="src-num">262144</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//\.\d+e\d+</span></div></li> <li><div class="src-line"><a name="a222"></a><span class="src-doc">/**&nbsp;Number&nbsp;format&nbsp;to&nbsp;highlight&nbsp;floating-point&nbsp;numbers&nbsp;with&nbsp;support&nbsp;for&nbsp;scientific&nbsp;notation&nbsp;(E)&nbsp;and&nbsp;required&nbsp;leading&nbsp;digit&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a223"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_NUMBER_FLT_SCI_ZERO'</span><span class="src-sym">,&nbsp;</span><span class="src-num">524288</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-comm">//\d+(\.\d+)?e\d+</span></div></li> <li><div class="src-line"><a name="a224"></a><span class="src-comm">//Custom&nbsp;formats&nbsp;are&nbsp;passed&nbsp;by&nbsp;RX&nbsp;array</span></div></li> <li><div class="src-line"><a name="a225"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a226"></a><span class="src-comm">//&nbsp;Error&nbsp;detection&nbsp;-&nbsp;use&nbsp;these&nbsp;to&nbsp;analyse&nbsp;faults</span></div></li> <li><div class="src-line"><a name="a227"></a><span class="src-doc">/**&nbsp;No&nbsp;sourcecode&nbsp;to&nbsp;highlight&nbsp;was&nbsp;specified</span></div></li> <li><div class="src-line"><a name="a228"></a><span class="src-doc">&nbsp;*&nbsp;</span><span class="src-doc-coretag">@deprecated</span></div></li> <li><div class="src-line"><a name="a229"></a><span class="src-doc">&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a230"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_ERROR_NO_INPUT'</span><span class="src-sym">,&nbsp;</span><span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a231"></a><span class="src-doc">/**&nbsp;The&nbsp;language&nbsp;specified&nbsp;does&nbsp;not&nbsp;exist&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a232"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_ERROR_NO_SUCH_LANG'</span><span class="src-sym">,&nbsp;</span><span class="src-num">2</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a233"></a><span class="src-doc">/**&nbsp;GeSHi&nbsp;could&nbsp;not&nbsp;open&nbsp;a&nbsp;file&nbsp;for&nbsp;reading&nbsp;(generally&nbsp;a&nbsp;language&nbsp;file)&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a234"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_ERROR_FILE_NOT_READABLE'</span><span class="src-sym">,&nbsp;</span><span class="src-num">3</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a235"></a><span class="src-doc">/**&nbsp;The&nbsp;header&nbsp;type&nbsp;passed&nbsp;to&nbsp;</span><span class="src-doc-inlinetag">{@link&nbsp;GeSHi-&gt;set_header_type()}</span><span class="src-doc">&nbsp;was&nbsp;invalid&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a236"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_ERROR_INVALID_HEADER_TYPE'</span><span class="src-sym">,&nbsp;</span><span class="src-num">4</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a237"></a><span class="src-doc">/**&nbsp;The&nbsp;line&nbsp;number&nbsp;type&nbsp;passed&nbsp;to&nbsp;</span><span class="src-doc-inlinetag">{@link&nbsp;GeSHi-&gt;enable_line_numbers()}</span><span class="src-doc">&nbsp;was&nbsp;invalid&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a238"></a><a href="http://www.php.net/define">define</a><span class="src-sym">(</span><span class="src-str">'GESHI_ERROR_INVALID_LINE_NUMBER_TYPE'</span><span class="src-sym">,&nbsp;</span><span class="src-num">5</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a239"></a><span class="src-comm">/**#@-*/</span></div></li> <li><div class="src-line"><a name="a240"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a241"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a242"></a><span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a243"></a><span class="src-doc">&nbsp;*&nbsp;The&nbsp;GeSHi&nbsp;Class.</span></div></li> <li><div class="src-line"><a name="a244"></a><span class="src-doc">&nbsp;*</span></div></li> <li><div class="src-line"><a name="a245"></a><span class="src-doc">&nbsp;*&nbsp;Please&nbsp;refer&nbsp;to&nbsp;the&nbsp;documentation&nbsp;for&nbsp;GeSHi&nbsp;1.0.X&nbsp;that&nbsp;is&nbsp;available</span></div></li> <li><div class="src-line"><a name="a246"></a><span class="src-doc">&nbsp;*&nbsp;at&nbsp;http://qbnz.com/highlighter/documentation.php&nbsp;for&nbsp;more&nbsp;information</span></div></li> <li><div class="src-line"><a name="a247"></a><span class="src-doc">&nbsp;*&nbsp;about&nbsp;how&nbsp;to&nbsp;use&nbsp;this&nbsp;class.</span></div></li> <li><div class="src-line"><a name="a248"></a><span class="src-doc">&nbsp;*</span></div></li> <li><div class="src-line"><a name="a249"></a><span class="src-doc">&nbsp;*&nbsp;</span><span class="src-doc-coretag">@package</span><span class="src-doc">&nbsp;&nbsp;&nbsp;geshi</span></div></li> <li><div class="src-line"><a name="a250"></a><span class="src-doc">&nbsp;*&nbsp;</span><span class="src-doc-coretag">@author</span><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;Nigel&nbsp;McNie&nbsp;&lt;nigel@geshi.org&gt;,&nbsp;Benny&nbsp;Baumann&nbsp;&lt;BenBE@omorphia.de&gt;</span></div></li> <li><div class="src-line"><a name="a251"></a><span class="src-doc">&nbsp;*&nbsp;</span><span class="src-doc-coretag">@copyright</span><span class="src-doc">&nbsp;(C)&nbsp;2004&nbsp;-&nbsp;2007&nbsp;Nigel&nbsp;McNie,&nbsp;(C)&nbsp;2007&nbsp;-&nbsp;2008&nbsp;Benny&nbsp;Baumann</span></div></li> <li><div class="src-line"><a name="a252"></a><span class="src-doc">&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a253"></a><span class="src-key">class&nbsp;</span><a href="../geshi/core/GeSHi.html">GeSHi</a>&nbsp;<span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a254"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">/**#@+</span></div></li> <li><div class="src-line"><a name="a255"></a><span class="src-comm">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@access&nbsp;private</span></div></li> <li><div class="src-line"><a name="a256"></a><span class="src-comm">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a257"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a258"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;source&nbsp;code&nbsp;to&nbsp;highlight</span></div></li> <li><div class="src-line"><a name="a259"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a260"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a261"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$source&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a262"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a263"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a264"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;language&nbsp;to&nbsp;use&nbsp;when&nbsp;highlighting</span></div></li> <li><div class="src-line"><a name="a265"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a266"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a267"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$language&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a268"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a269"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a270"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;data&nbsp;for&nbsp;the&nbsp;language&nbsp;used</span></div></li> <li><div class="src-line"><a name="a271"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">array&nbsp;</span></div></li> <li><div class="src-line"><a name="a272"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a273"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$language_data&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a274"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a275"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a276"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;path&nbsp;to&nbsp;the&nbsp;language&nbsp;files</span></div></li> <li><div class="src-line"><a name="a277"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a278"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a279"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$language_path&nbsp;</span>=&nbsp;<span class="src-id">GESHI_LANG_ROOT</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a280"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a281"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a282"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;error&nbsp;message&nbsp;associated&nbsp;with&nbsp;an&nbsp;error</span></div></li> <li><div class="src-line"><a name="a283"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a284"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@todo</span><span class="src-doc">&nbsp;check&nbsp;err&nbsp;reporting&nbsp;works</span></div></li> <li><div class="src-line"><a name="a285"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a286"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$error&nbsp;</span>=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a287"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a288"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a289"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Possible&nbsp;error&nbsp;messages</span></div></li> <li><div class="src-line"><a name="a290"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">array&nbsp;</span></div></li> <li><div class="src-line"><a name="a291"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a292"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$error_messages&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></div></li> <li><div class="src-line"><a name="a293"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_ERROR_NO_SUCH_LANG&nbsp;</span>=&gt;&nbsp;<span class="src-str">'GeSHi&nbsp;could&nbsp;not&nbsp;find&nbsp;the&nbsp;language&nbsp;{LANGUAGE}&nbsp;(using&nbsp;path&nbsp;{PATH})'</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a294"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_ERROR_FILE_NOT_READABLE&nbsp;</span>=&gt;&nbsp;<span class="src-str">'The&nbsp;file&nbsp;specified&nbsp;for&nbsp;load_from_file&nbsp;was&nbsp;not&nbsp;readable'</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a295"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_ERROR_INVALID_HEADER_TYPE&nbsp;</span>=&gt;&nbsp;<span class="src-str">'The&nbsp;header&nbsp;type&nbsp;specified&nbsp;is&nbsp;invalid'</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a296"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_ERROR_INVALID_LINE_NUMBER_TYPE&nbsp;</span>=&gt;&nbsp;<span class="src-str">'The&nbsp;line&nbsp;number&nbsp;type&nbsp;specified&nbsp;is&nbsp;invalid'</span></div></li> <li><div class="src-line"><a name="a297"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a298"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a299"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a300"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Whether&nbsp;highlighting&nbsp;is&nbsp;strict&nbsp;or&nbsp;not</span></div></li> <li><div class="src-line"><a name="a301"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span></div></li> <li><div class="src-line"><a name="a302"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a303"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$strict_mode&nbsp;</span>=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a304"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a305"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a306"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Whether&nbsp;to&nbsp;use&nbsp;CSS&nbsp;classes&nbsp;in&nbsp;output</span></div></li> <li><div class="src-line"><a name="a307"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span></div></li> <li><div class="src-line"><a name="a308"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a309"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$use_classes&nbsp;</span>=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a310"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a311"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a312"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;type&nbsp;of&nbsp;header&nbsp;to&nbsp;use.&nbsp;Can&nbsp;be&nbsp;one&nbsp;of&nbsp;the&nbsp;following</span></div></li> <li><div class="src-line"><a name="a313"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;values:</span></div></li> <li><div class="src-line"><a name="a314"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a315"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;-&nbsp;GESHI_HEADER_PRE:&nbsp;Source&nbsp;is&nbsp;outputted&nbsp;in&nbsp;a&nbsp;&quot;pre&quot;&nbsp;HTML&nbsp;element.</span></div></li> <li><div class="src-line"><a name="a316"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;-&nbsp;GESHI_HEADER_DIV:&nbsp;Source&nbsp;is&nbsp;outputted&nbsp;in&nbsp;a&nbsp;&quot;div&quot;&nbsp;HTML&nbsp;element.</span></div></li> <li><div class="src-line"><a name="a317"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;-&nbsp;GESHI_HEADER_NONE:&nbsp;No&nbsp;header&nbsp;is&nbsp;outputted.</span></div></li> <li><div class="src-line"><a name="a318"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a319"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">int&nbsp;</span></div></li> <li><div class="src-line"><a name="a320"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a321"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$header_type&nbsp;</span>=&nbsp;<span class="src-id">GESHI_HEADER_PRE</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a322"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a323"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a324"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Array&nbsp;of&nbsp;permissions&nbsp;for&nbsp;which&nbsp;lexics&nbsp;should&nbsp;be&nbsp;highlighted</span></div></li> <li><div class="src-line"><a name="a325"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">array&nbsp;</span></div></li> <li><div class="src-line"><a name="a326"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a327"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$lexic_permissions&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></div></li> <li><div class="src-line"><a name="a328"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'KEYWORDS'&nbsp;</span>=&gt;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a329"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'COMMENTS'&nbsp;</span>=&gt;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'MULTI'&nbsp;</span>=&gt;&nbsp;<span class="src-id">true</span><span class="src-sym">)</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a330"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'REGEXPS'&nbsp;</span>=&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a331"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'ESCAPE_CHAR'&nbsp;</span>=&gt;&nbsp;<span class="src-id">true</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a332"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'BRACKETS'&nbsp;</span>=&gt;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">true</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a333"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'SYMBOLS'&nbsp;</span>=&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">false</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a334"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'STRINGS'&nbsp;</span>=&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">true</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a335"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'NUMBERS'&nbsp;</span>=&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">true</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a336"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'METHODS'&nbsp;</span>=&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">true</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a337"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'SCRIPT'&nbsp;</span>=&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">true</span></div></li> <li><div class="src-line"><a name="a338"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a339"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a340"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a341"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;time&nbsp;it&nbsp;took&nbsp;to&nbsp;parse&nbsp;the&nbsp;code</span></div></li> <li><div class="src-line"><a name="a342"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">double&nbsp;</span></div></li> <li><div class="src-line"><a name="a343"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a344"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$time&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a345"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a346"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a347"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;content&nbsp;of&nbsp;the&nbsp;header&nbsp;block</span></div></li> <li><div class="src-line"><a name="a348"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a349"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a350"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$header_content&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a351"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a352"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a353"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;content&nbsp;of&nbsp;the&nbsp;footer&nbsp;block</span></div></li> <li><div class="src-line"><a name="a354"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a355"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a356"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$footer_content&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a357"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a358"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a359"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;style&nbsp;of&nbsp;the&nbsp;header&nbsp;block</span></div></li> <li><div class="src-line"><a name="a360"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a361"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a362"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$header_content_style&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a363"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a364"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a365"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;style&nbsp;of&nbsp;the&nbsp;footer&nbsp;block</span></div></li> <li><div class="src-line"><a name="a366"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a367"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a368"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$footer_content_style&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a369"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a370"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a371"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Tells&nbsp;if&nbsp;a&nbsp;block&nbsp;around&nbsp;the&nbsp;highlighted&nbsp;source&nbsp;should&nbsp;be&nbsp;forced</span></div></li> <li><div class="src-line"><a name="a372"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;if&nbsp;not&nbsp;using&nbsp;line&nbsp;numbering</span></div></li> <li><div class="src-line"><a name="a373"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span></div></li> <li><div class="src-line"><a name="a374"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a375"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$force_code_block&nbsp;</span>=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a376"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a377"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a378"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;styles&nbsp;for&nbsp;hyperlinks&nbsp;in&nbsp;the&nbsp;code</span></div></li> <li><div class="src-line"><a name="a379"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">array&nbsp;</span></div></li> <li><div class="src-line"><a name="a380"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a381"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$link_styles&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a382"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a383"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a384"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Whether&nbsp;important&nbsp;blocks&nbsp;should&nbsp;be&nbsp;recognised&nbsp;or&nbsp;not</span></div></li> <li><div class="src-line"><a name="a385"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span></div></li> <li><div class="src-line"><a name="a386"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@deprecated</span></div></li> <li><div class="src-line"><a name="a387"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@todo</span><span class="src-doc">&nbsp;REMOVE&nbsp;THIS&nbsp;FUNCTIONALITY!</span></div></li> <li><div class="src-line"><a name="a388"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a389"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$enable_important_blocks&nbsp;</span>=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a390"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a391"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a392"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Styles&nbsp;for&nbsp;important&nbsp;parts&nbsp;of&nbsp;the&nbsp;code</span></div></li> <li><div class="src-line"><a name="a393"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a394"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@deprecated</span></div></li> <li><div class="src-line"><a name="a395"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@todo</span><span class="src-doc">&nbsp;As&nbsp;above&nbsp;-&nbsp;rethink&nbsp;the&nbsp;whole&nbsp;idea&nbsp;of&nbsp;important&nbsp;blocks&nbsp;as&nbsp;it&nbsp;is&nbsp;buggy&nbsp;and</span></div></li> <li><div class="src-line"><a name="a396"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;will&nbsp;be&nbsp;hard&nbsp;to&nbsp;implement&nbsp;in&nbsp;1.2</span></div></li> <li><div class="src-line"><a name="a397"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a398"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$important_styles&nbsp;</span>=&nbsp;<span class="src-str">'font-weight:&nbsp;bold;&nbsp;color:&nbsp;red;'</span><span class="src-sym">;&nbsp;</span><span class="src-comm">//&nbsp;Styles&nbsp;for&nbsp;important&nbsp;parts&nbsp;of&nbsp;the&nbsp;code</span></div></li> <li><div class="src-line"><a name="a399"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a400"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a401"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Whether&nbsp;CSS&nbsp;IDs&nbsp;should&nbsp;be&nbsp;added&nbsp;to&nbsp;the&nbsp;code</span></div></li> <li><div class="src-line"><a name="a402"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span></div></li> <li><div class="src-line"><a name="a403"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a404"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$add_ids&nbsp;</span>=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a405"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a406"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a407"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Lines&nbsp;that&nbsp;should&nbsp;be&nbsp;highlighted&nbsp;extra</span></div></li> <li><div class="src-line"><a name="a408"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">array&nbsp;</span></div></li> <li><div class="src-line"><a name="a409"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a410"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$highlight_extra_lines&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a411"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a412"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a413"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Styles&nbsp;of&nbsp;lines&nbsp;that&nbsp;should&nbsp;be&nbsp;highlighted&nbsp;extra</span></div></li> <li><div class="src-line"><a name="a414"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">array&nbsp;</span></div></li> <li><div class="src-line"><a name="a415"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a416"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$highlight_extra_lines_styles&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a417"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a418"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a419"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Styles&nbsp;of&nbsp;extra-highlighted&nbsp;lines</span></div></li> <li><div class="src-line"><a name="a420"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a421"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a422"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$highlight_extra_lines_style&nbsp;</span>=&nbsp;<span class="src-str">'background-color:&nbsp;#ffc;'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a423"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a424"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a425"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;line&nbsp;ending</span></div></li> <li><div class="src-line"><a name="a426"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;If&nbsp;null,&nbsp;nl2br()&nbsp;will&nbsp;be&nbsp;used&nbsp;on&nbsp;the&nbsp;result&nbsp;string.</span></div></li> <li><div class="src-line"><a name="a427"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Otherwise,&nbsp;all&nbsp;instances&nbsp;of&nbsp;\n&nbsp;will&nbsp;be&nbsp;replaced&nbsp;with&nbsp;$line_ending</span></div></li> <li><div class="src-line"><a name="a428"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a429"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a430"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$line_ending&nbsp;</span>=&nbsp;<span class="src-id">null</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a431"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a432"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a433"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Number&nbsp;at&nbsp;which&nbsp;line&nbsp;numbers&nbsp;should&nbsp;start&nbsp;at</span></div></li> <li><div class="src-line"><a name="a434"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">int&nbsp;</span></div></li> <li><div class="src-line"><a name="a435"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a436"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$line_numbers_start&nbsp;</span>=&nbsp;<span class="src-num">1</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a437"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a438"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a439"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;overall&nbsp;style&nbsp;for&nbsp;this&nbsp;code&nbsp;block</span></div></li> <li><div class="src-line"><a name="a440"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a441"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a442"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$overall_style&nbsp;</span>=&nbsp;<span class="src-str">'font-family:monospace;'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a443"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a444"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a445"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;The&nbsp;style&nbsp;for&nbsp;the&nbsp;actual&nbsp;code</span></div></li> <li><div class="src-line"><a name="a446"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a447"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a448"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$code_style&nbsp;</span>=&nbsp;<span class="src-str">'font:&nbsp;normal&nbsp;normal&nbsp;1em/1.2em&nbsp;monospace;&nbsp;margin:0;&nbsp;padding:0;&nbsp;background:none;&nbsp;vertical-align:top;'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a449"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a450"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a451"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;overall&nbsp;class&nbsp;for&nbsp;this&nbsp;code&nbsp;block</span></div></li> <li><div class="src-line"><a name="a452"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a453"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a454"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$overall_class&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a455"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a456"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a457"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;overall&nbsp;ID&nbsp;for&nbsp;this&nbsp;code&nbsp;block</span></div></li> <li><div class="src-line"><a name="a458"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a459"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a460"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$overall_id&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a461"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a462"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a463"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Line&nbsp;number&nbsp;styles</span></div></li> <li><div class="src-line"><a name="a464"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a465"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a466"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$line_style1&nbsp;</span>=&nbsp;<span class="src-str">'font-weight:&nbsp;normal;&nbsp;vertical-align:top;'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a467"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a468"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a469"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Line&nbsp;number&nbsp;styles&nbsp;for&nbsp;fancy&nbsp;lines</span></div></li> <li><div class="src-line"><a name="a470"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a471"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a472"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$line_style2&nbsp;</span>=&nbsp;<span class="src-str">'font-weight:&nbsp;bold;&nbsp;vertical-align:top;'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a473"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a474"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a475"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Style&nbsp;for&nbsp;line&nbsp;numbers&nbsp;when&nbsp;GESHI_HEADER_PRE_TABLE&nbsp;is&nbsp;chosen</span></div></li> <li><div class="src-line"><a name="a476"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a477"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a478"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$table_linenumber_style&nbsp;</span>=&nbsp;<span class="src-str">'width:1px;text-align:right;margin:0;padding:0&nbsp;2px;vertical-align:top;'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a479"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a480"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a481"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Flag&nbsp;for&nbsp;how&nbsp;line&nbsp;numbers&nbsp;are&nbsp;displayed</span></div></li> <li><div class="src-line"><a name="a482"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span></div></li> <li><div class="src-line"><a name="a483"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a484"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$line_numbers&nbsp;</span>=&nbsp;<span class="src-id">GESHI_NO_LINE_NUMBERS</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a485"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a486"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a487"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Flag&nbsp;to&nbsp;decide&nbsp;if&nbsp;multi&nbsp;line&nbsp;spans&nbsp;are&nbsp;allowed.&nbsp;Set&nbsp;it&nbsp;to&nbsp;false&nbsp;to&nbsp;make&nbsp;sure</span></div></li> <li><div class="src-line"><a name="a488"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;each&nbsp;tag&nbsp;is&nbsp;closed&nbsp;before&nbsp;and&nbsp;reopened&nbsp;after&nbsp;each&nbsp;linefeed.</span></div></li> <li><div class="src-line"><a name="a489"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span></div></li> <li><div class="src-line"><a name="a490"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a491"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$allow_multiline_span&nbsp;</span>=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a492"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a493"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a494"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;&quot;nth&quot;&nbsp;value&nbsp;for&nbsp;fancy&nbsp;line&nbsp;highlighting</span></div></li> <li><div class="src-line"><a name="a495"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">int&nbsp;</span></div></li> <li><div class="src-line"><a name="a496"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a497"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$line_nth_row&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a498"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a499"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a500"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;size&nbsp;of&nbsp;tab&nbsp;stops</span></div></li> <li><div class="src-line"><a name="a501"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">int&nbsp;</span></div></li> <li><div class="src-line"><a name="a502"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a503"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$tab_width&nbsp;</span>=&nbsp;<span class="src-num">8</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a504"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a505"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a506"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Should&nbsp;we&nbsp;use&nbsp;language-defined&nbsp;tab&nbsp;stop&nbsp;widths?</span></div></li> <li><div class="src-line"><a name="a507"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">int&nbsp;</span></div></li> <li><div class="src-line"><a name="a508"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a509"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$use_language_tab_width&nbsp;</span>=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a510"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a511"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a512"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Default&nbsp;target&nbsp;for&nbsp;keyword&nbsp;links</span></div></li> <li><div class="src-line"><a name="a513"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a514"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a515"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$link_target&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a516"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a517"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a518"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;encoding&nbsp;to&nbsp;use&nbsp;for&nbsp;entity&nbsp;encoding</span></div></li> <li><div class="src-line"><a name="a519"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;NOTE:&nbsp;Used&nbsp;with&nbsp;Escape&nbsp;Char&nbsp;Sequences&nbsp;to&nbsp;fix&nbsp;UTF-8&nbsp;handling&nbsp;(cf.&nbsp;SF#2037598)</span></div></li> <li><div class="src-line"><a name="a520"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a521"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a522"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$encoding&nbsp;</span>=&nbsp;<span class="src-str">'utf-8'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a523"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a524"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a525"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Should&nbsp;keywords&nbsp;be&nbsp;linked?</span></div></li> <li><div class="src-line"><a name="a526"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span></div></li> <li><div class="src-line"><a name="a527"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a528"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$keyword_links&nbsp;</span>=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a529"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a530"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a531"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Currently&nbsp;loaded&nbsp;language&nbsp;file</span></div></li> <li><div class="src-line"><a name="a532"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a533"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.7.22</span></div></li> <li><div class="src-line"><a name="a534"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a535"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$loaded_language&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a536"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a537"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a538"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Wether&nbsp;the&nbsp;caches&nbsp;needed&nbsp;for&nbsp;parsing&nbsp;are&nbsp;built&nbsp;or&nbsp;not</span></div></li> <li><div class="src-line"><a name="a539"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a540"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">bool&nbsp;</span></div></li> <li><div class="src-line"><a name="a541"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.8</span></div></li> <li><div class="src-line"><a name="a542"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a543"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$parse_cache_built&nbsp;</span>=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a544"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a545"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a546"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Work&nbsp;around&nbsp;for&nbsp;Suhosin&nbsp;Patch&nbsp;with&nbsp;disabled&nbsp;/e&nbsp;modifier</span></div></li> <li><div class="src-line"><a name="a547"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a548"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Note&nbsp;from&nbsp;suhosins&nbsp;author&nbsp;in&nbsp;config&nbsp;file:</span></div></li> <li><div class="src-line"><a name="a549"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&lt;blockquote&gt;</span></div></li> <li><div class="src-line"><a name="a550"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;The&nbsp;/e&nbsp;modifier&nbsp;inside&nbsp;&lt;code&gt;preg_replace()&lt;/code&gt;&nbsp;allows&nbsp;code&nbsp;execution.</span></div></li> <li><div class="src-line"><a name="a551"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;Often&nbsp;it&nbsp;is&nbsp;the&nbsp;cause&nbsp;for&nbsp;remote&nbsp;code&nbsp;execution&nbsp;exploits.&nbsp;It&nbsp;is&nbsp;wise&nbsp;to</span></div></li> <li><div class="src-line"><a name="a552"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;deactivate&nbsp;this&nbsp;feature&nbsp;and&nbsp;test&nbsp;where&nbsp;in&nbsp;the&nbsp;application&nbsp;it&nbsp;is&nbsp;used.</span></div></li> <li><div class="src-line"><a name="a553"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;The&nbsp;developer&nbsp;using&nbsp;the&nbsp;/e&nbsp;modifier&nbsp;should&nbsp;be&nbsp;made&nbsp;aware&nbsp;that&nbsp;he&nbsp;should</span></div></li> <li><div class="src-line"><a name="a554"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;use&nbsp;&lt;code&gt;preg_replace_callback()&lt;/code&gt;&nbsp;instead</span></div></li> <li><div class="src-line"><a name="a555"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&lt;/blockquote&gt;</span></div></li> <li><div class="src-line"><a name="a556"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a557"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">array&nbsp;</span></div></li> <li><div class="src-line"><a name="a558"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.8</span></div></li> <li><div class="src-line"><a name="a559"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a560"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$_kw_replace_group&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a561"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$_rx_key&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a562"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a563"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a564"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;some&nbsp;&quot;callback&nbsp;parameters&quot;&nbsp;for&nbsp;handle_multiline_regexps</span></div></li> <li><div class="src-line"><a name="a565"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a566"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.8</span></div></li> <li><div class="src-line"><a name="a567"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@access</span><span class="src-doc">&nbsp;private</span></div></li> <li><div class="src-line"><a name="a568"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@var&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a569"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a570"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$_hmr_before&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a571"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$_hmr_replace&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a572"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$_hmr_after&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a573"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">var&nbsp;</span><span class="src-var">$_hmr_key&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a574"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a575"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">/**#@-*/</span></div></li> <li><div class="src-line"><a name="a576"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a577"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a578"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Creates&nbsp;a&nbsp;new&nbsp;GeSHi&nbsp;object,&nbsp;with&nbsp;source&nbsp;and&nbsp;language</span></div></li> <li><div class="src-line"><a name="a579"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a580"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;source&nbsp;code&nbsp;to&nbsp;highlight</span></div></li> <li><div class="src-line"><a name="a581"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;language&nbsp;to&nbsp;highlight&nbsp;the&nbsp;source&nbsp;with</span></div></li> <li><div class="src-line"><a name="a582"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;path&nbsp;to&nbsp;the&nbsp;language&nbsp;file&nbsp;directory.&nbsp;&lt;b&gt;This</span></div></li> <li><div class="src-line"><a name="a583"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;is&nbsp;deprecated!&lt;/b&gt;&nbsp;I've&nbsp;backported&nbsp;the&nbsp;auto&nbsp;path</span></div></li> <li><div class="src-line"><a name="a584"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;detection&nbsp;from&nbsp;the&nbsp;1.1.X&nbsp;dev&nbsp;branch,&nbsp;so&nbsp;now&nbsp;it</span></div></li> <li><div class="src-line"><a name="a585"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;should&nbsp;be&nbsp;automatically&nbsp;set&nbsp;correctly.&nbsp;If&nbsp;you&nbsp;have</span></div></li> <li><div class="src-line"><a name="a586"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;renamed&nbsp;the&nbsp;language&nbsp;directory&nbsp;however,&nbsp;you&nbsp;will</span></div></li> <li><div class="src-line"><a name="a587"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;still&nbsp;need&nbsp;to&nbsp;set&nbsp;the&nbsp;path&nbsp;using&nbsp;this&nbsp;parameter&nbsp;or</span></div></li> <li><div class="src-line"><a name="a588"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-doc-inlinetag">{@link&nbsp;GeSHi-&gt;set_language_path()}</span></div></li> <li><div class="src-line"><a name="a589"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a590"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a591"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function&nbsp;</span><a href="../geshi/core/GeSHi.html#methodGeSHi">GeSHi</a><span class="src-sym">(</span><span class="src-var">$source&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">,&nbsp;</span><span class="src-var">$language&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">,&nbsp;</span><span class="src-var">$path&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a592"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$source</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a593"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodset_source">set_source</a><span class="src-sym">(</span><span class="src-var">$source</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a594"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a595"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$language</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a596"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodset_language">set_language</a><span class="src-sym">(</span><span class="src-var">$language</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a597"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a598"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodset_language_path">set_language_path</a><span class="src-sym">(</span><span class="src-var">$path</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a599"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a600"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a601"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-doc">/**</span></div></li> <li><div class="src-line"><a name="a602"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Returns&nbsp;an&nbsp;error&nbsp;message&nbsp;associated&nbsp;with&nbsp;the&nbsp;last&nbsp;GeSHi&nbsp;operation,</span></div></li> <li><div class="src-line"><a name="a603"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;or&nbsp;false&nbsp;if&nbsp;no&nbsp;error&nbsp;has&nbsp;occured</span></div></li> <li><div class="src-line"><a name="a604"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a605"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@return&nbsp;</span><span class="src-doc-type">string</span><span class="src-doc">|</span><span class="src-doc-type">false</span><span class="src-doc">An&nbsp;error&nbsp;message&nbsp;if&nbsp;there&nbsp;has&nbsp;been&nbsp;an&nbsp;error,&nbsp;else&nbsp;false</span></div></li> <li><div class="src-line"><a name="a606"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a607"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a608"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function&nbsp;</span><a href="../geshi/core/GeSHi.html#methoderror">error</a><span class="src-sym">(</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a609"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">error</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a610"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Put&nbsp;some&nbsp;template&nbsp;variables&nbsp;for&nbsp;debugging&nbsp;here&nbsp;...</span></div></li> <li><div class="src-line"><a name="a611"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$debug_tpl_vars&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></div></li> <li><div class="src-line"><a name="a612"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'{LANGUAGE}'&nbsp;</span>=&gt;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a613"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'{PATH}'&nbsp;</span>=&gt;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_path</span></div></li> <li><div class="src-line"><a name="a614"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a615"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$msg&nbsp;</span>=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span></div></li> <li><div class="src-line"><a name="a616"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/array_keys">array_keys</a><span class="src-sym">(</span><span class="src-var">$debug_tpl_vars</span><span class="src-sym">)</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a617"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/array_values">array_values</a><span class="src-sym">(</span><span class="src-var">$debug_tpl_vars</span><span class="src-sym">)</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a618"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">error_messages</span><span class="src-sym">[</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">error</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a619"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a620"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><span class="src-str">&quot;</span><span class="src-str">&lt;br&nbsp;/&gt;&lt;strong&gt;GeSHi&nbsp;Error:&lt;/strong&gt;&nbsp;<span class="src-var">$msg</span>&nbsp;(code&nbsp;{<span class="src-var">$this</span></span><span class="src-sym">-&gt;</span><span class="src-var">error</span><span class="src-sym">}</span>)&lt;br&nbsp;/&gt;</span><span class="src-str"><span class="src-str">"</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a621"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a622"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a623"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a624"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a625"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a626"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Gets&nbsp;a&nbsp;human-readable&nbsp;language&nbsp;name&nbsp;(thanks&nbsp;to&nbsp;Simon&nbsp;Patterson</span></div></li> <li><div class="src-line"><a name="a627"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;for&nbsp;the&nbsp;idea&nbsp;:))</span></div></li> <li><div class="src-line"><a name="a628"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a629"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@return&nbsp;string&nbsp;The&nbsp;name&nbsp;for&nbsp;the&nbsp;current&nbsp;language</span></div></li> <li><div class="src-line"><a name="a630"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a631"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a632"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">get_language_name</span><span class="src-sym">(</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a633"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">GESHI_ERROR_NO_SUCH_LANG</span>&nbsp;==&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">error</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a634"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'LANG_NAME'</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&nbsp;(Unknown&nbsp;Language)'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a635"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a636"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'LANG_NAME'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a637"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a638"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a639"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a640"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;source&nbsp;code&nbsp;for&nbsp;this&nbsp;object</span></div></li> <li><div class="src-line"><a name="a641"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a642"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;source&nbsp;code&nbsp;to&nbsp;highlight</span></div></li> <li><div class="src-line"><a name="a643"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a644"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a645"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_source">set_source</a><span class="src-sym">(</span><span class="src-var">$source</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a646"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">source</span>&nbsp;=&nbsp;<span class="src-var">$source</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a647"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">highlight_extra_lines</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a648"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a649"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a650"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a651"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;language&nbsp;for&nbsp;this&nbsp;object</span></div></li> <li><div class="src-line"><a name="a652"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a653"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-tag">@note</span><span class="src-doc">&nbsp;since&nbsp;1.0.8&nbsp;this&nbsp;function&nbsp;won't&nbsp;reset&nbsp;language-settings&nbsp;by&nbsp;default&nbsp;anymore!</span></div></li> <li><div class="src-line"><a name="a654"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if&nbsp;you&nbsp;need&nbsp;this&nbsp;set&nbsp;$force_reset&nbsp;=&nbsp;true</span></div></li> <li><div class="src-line"><a name="a655"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a656"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;name&nbsp;of&nbsp;the&nbsp;language&nbsp;to&nbsp;use</span></div></li> <li><div class="src-line"><a name="a657"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a658"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a659"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_language">set_language</a><span class="src-sym">(</span><span class="src-var">$language</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$force_reset</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a660"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$force_reset</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a661"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">loaded_language</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a662"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a663"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a664"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Clean&nbsp;up&nbsp;the&nbsp;language&nbsp;name&nbsp;to&nbsp;prevent&nbsp;malicious&nbsp;code&nbsp;injection</span></span></div></li> <li><div class="src-line"><a name="a665"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$language</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_replace">preg_replace</a><span class="src-sym">(</span><span class="src-str">'#[^a-zA-Z0-9\-_]#'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">''</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$language</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a666"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a667"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$language</span>&nbsp;=&nbsp;<a href="http://www.php.net/strtolower">strtolower</a><span class="src-sym">(</span><span class="src-var">$language</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a668"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a669"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Retreive&nbsp;the&nbsp;full&nbsp;filename</span></span></div></li> <li><div class="src-line"><a name="a670"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$file_name</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_path</span>&nbsp;.&nbsp;<span class="src-var">$language</span>&nbsp;.&nbsp;<span class="src-str">'.php'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a671"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$file_name</span>&nbsp;==&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">loaded_language</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a672"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;this&nbsp;language&nbsp;is&nbsp;already&nbsp;loaded!</span></span></div></li> <li><div class="src-line"><a name="a673"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a674"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a675"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a676"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language</span>&nbsp;=&nbsp;<span class="src-var">$language</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a677"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a678"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">error</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a679"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">strict_mode</span>&nbsp;=&nbsp;<span class="src-id">GESHI_NEVER</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a680"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a681"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;we&nbsp;can&nbsp;read&nbsp;the&nbsp;desired&nbsp;file</span></span></div></li> <li><div class="src-line"><a name="a682"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><a href="http://www.php.net/is_readable">is_readable</a><span class="src-sym">(</span><span class="src-var">$file_name</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a683"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">error</span>&nbsp;=&nbsp;<span class="src-id">GESHI_ERROR_NO_SUCH_LANG</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a684"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a685"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a686"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a687"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Load&nbsp;the&nbsp;language&nbsp;for&nbsp;parsing</span></span></div></li> <li><div class="src-line"><a name="a688"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">load_language</span><span class="src-sym">(</span><span class="src-var">$file_name</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a689"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a690"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a691"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a692"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;path&nbsp;to&nbsp;the&nbsp;directory&nbsp;containing&nbsp;the&nbsp;language&nbsp;files.&nbsp;Note</span></div></li> <li><div class="src-line"><a name="a693"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;that&nbsp;this&nbsp;path&nbsp;is&nbsp;relative&nbsp;to&nbsp;the&nbsp;directory&nbsp;of&nbsp;the&nbsp;script&nbsp;that&nbsp;included</span></div></li> <li><div class="src-line"><a name="a694"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;geshi.php,&nbsp;NOT&nbsp;geshi.php&nbsp;itself.</span></div></li> <li><div class="src-line"><a name="a695"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a696"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;path&nbsp;to&nbsp;the&nbsp;language&nbsp;directory</span></div></li> <li><div class="src-line"><a name="a697"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a698"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@deprecated</span><span class="src-doc">&nbsp;The&nbsp;path&nbsp;to&nbsp;the&nbsp;language&nbsp;files&nbsp;should&nbsp;now&nbsp;be&nbsp;automatically</span></div></li> <li><div class="src-line"><a name="a699"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;detected,&nbsp;so&nbsp;this&nbsp;method&nbsp;should&nbsp;no&nbsp;longer&nbsp;be&nbsp;needed.&nbsp;The</span></div></li> <li><div class="src-line"><a name="a700"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1.1.X&nbsp;branch&nbsp;handles&nbsp;manual&nbsp;setting&nbsp;of&nbsp;the&nbsp;path&nbsp;differently</span></div></li> <li><div class="src-line"><a name="a701"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;so&nbsp;this&nbsp;method&nbsp;will&nbsp;disappear&nbsp;in&nbsp;1.2.0.</span></div></li> <li><div class="src-line"><a name="a702"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a703"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_language_path">set_language_path</a><span class="src-sym">(</span><span class="src-var">$path</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a704"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$path</span><span class="src-sym">,</span><span class="src-str">':'</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a705"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Security&nbsp;Fix&nbsp;to&nbsp;prevent&nbsp;external&nbsp;directories&nbsp;using&nbsp;fopen&nbsp;wrappers.</span></span></div></li> <li><div class="src-line"><a name="a706"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-id">DIRECTORY_SEPARATOR</span>&nbsp;==&nbsp;<span class="src-str">&quot;\\&quot;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a707"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-sym">!</span><a href="http://www.php.net/preg_match">preg_match</a><span class="src-sym">(</span><span class="src-str">'#^[a-zA-Z]:#'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$path</span><span class="src-sym">)</span>&nbsp;||&nbsp;<span class="src-id">false</span>&nbsp;!==&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$path</span><span class="src-sym">,</span>&nbsp;<span class="src-str">':'</span><span class="src-sym">,</span>&nbsp;<span class="src-num">2</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a708"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a709"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a710"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a711"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a712"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a713"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a714"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><a href="http://www.php.net/preg_match">preg_match</a><span class="src-sym">(</span><span class="src-str">'#[^/a-zA-Z0-9_\.\-\\\s:]#'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$path</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a715"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Security&nbsp;Fix&nbsp;to&nbsp;prevent&nbsp;external&nbsp;directories&nbsp;using&nbsp;fopen&nbsp;wrappers.</span></span></div></li> <li><div class="src-line"><a name="a716"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a717"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a718"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_SECURITY_PARANOID&quot;&gt;GESHI_SECURITY_PARANOID&lt;/a&gt;</span>&nbsp;&amp;&amp;&nbsp;<span class="src-id">false</span>&nbsp;!==&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$path</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'/.'</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a719"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Security&nbsp;Fix&nbsp;to&nbsp;prevent&nbsp;external&nbsp;directories&nbsp;using&nbsp;fopen&nbsp;wrappers.</span></span></div></li> <li><div class="src-line"><a name="a720"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a721"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a722"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_SECURITY_PARANOID&quot;&gt;GESHI_SECURITY_PARANOID&lt;/a&gt;</span>&nbsp;&amp;&amp;&nbsp;<span class="src-id">false</span>&nbsp;!==&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$path</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'..'</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a723"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Security&nbsp;Fix&nbsp;to&nbsp;prevent&nbsp;external&nbsp;directories&nbsp;using&nbsp;fopen&nbsp;wrappers.</span></span></div></li> <li><div class="src-line"><a name="a724"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a725"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a726"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$path</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a727"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_path</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-str">'/'</span>&nbsp;==&nbsp;<span class="src-var">$path</span><span class="src-sym">[</span><a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$path</span><span class="src-sym">)</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-var">$path</span>&nbsp;:&nbsp;<span class="src-var">$path</span>&nbsp;.&nbsp;<span class="src-str">'/'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a728"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodset_language">set_language</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language</span><span class="src-sym">)</span><span class="src-sym">;</span>&nbsp;<span class="src-comm">//&nbsp;otherwise&nbsp;set_language_path&nbsp;has&nbsp;no&nbsp;effect</span></span></div></li> <li><div class="src-line"><a name="a729"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a730"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a731"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a732"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a733"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;type&nbsp;of&nbsp;header&nbsp;to&nbsp;be&nbsp;used.</span></div></li> <li><div class="src-line"><a name="a734"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a735"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;If&nbsp;GESHI_HEADER_DIV&nbsp;is&nbsp;used,&nbsp;the&nbsp;code&nbsp;is&nbsp;surrounded&nbsp;in&nbsp;a&nbsp;&quot;div&quot;.This</span></div></li> <li><div class="src-line"><a name="a736"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;means&nbsp;more&nbsp;source&nbsp;code&nbsp;but&nbsp;more&nbsp;control&nbsp;over&nbsp;tab&nbsp;width&nbsp;and&nbsp;line-wrapping.</span></div></li> <li><div class="src-line"><a name="a737"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;GESHI_HEADER_PRE&nbsp;means&nbsp;that&nbsp;a&nbsp;&quot;pre&quot;&nbsp;is&nbsp;used&nbsp;-&nbsp;less&nbsp;source,&nbsp;but&nbsp;less</span></div></li> <li><div class="src-line"><a name="a738"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;control.&nbsp;Default&nbsp;is&nbsp;GESHI_HEADER_PRE.</span></div></li> <li><div class="src-line"><a name="a739"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a740"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;From&nbsp;1.0.7.2,&nbsp;you&nbsp;can&nbsp;use&nbsp;GESHI_HEADER_NONE&nbsp;to&nbsp;specify&nbsp;that&nbsp;no&nbsp;header&nbsp;code</span></div></li> <li><div class="src-line"><a name="a741"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;should&nbsp;be&nbsp;outputted.</span></div></li> <li><div class="src-line"><a name="a742"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a743"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">The&nbsp;type&nbsp;of&nbsp;header&nbsp;to&nbsp;be&nbsp;used</span></div></li> <li><div class="src-line"><a name="a744"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a745"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a746"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_header_type">set_header_type</a><span class="src-sym">(</span><span class="src-var">$type</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a747"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;we&nbsp;got&nbsp;a&nbsp;valid&nbsp;header&nbsp;type</span></span></div></li> <li><div class="src-line"><a name="a748"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><a href="http://www.php.net/in_array">in_array</a><span class="src-sym">(</span><span class="src-var">$type</span><span class="src-sym">,</span>&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_NONE&quot;&gt;GESHI_HEADER_NONE&lt;/a&gt;</span><span class="src-sym">,</span>&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_DIV&quot;&gt;GESHI_HEADER_DIV&lt;/a&gt;</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a749"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE&quot;&gt;GESHI_HEADER_PRE&lt;/a&gt;</span><span class="src-sym">,</span>&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_VALID&quot;&gt;GESHI_HEADER_PRE_VALID&lt;/a&gt;</span><span class="src-sym">,</span>&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_TABLE&quot;&gt;GESHI_HEADER_PRE_TABLE&lt;/a&gt;</span><span class="src-sym">)))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a750"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">error</span>&nbsp;=&nbsp;<span class="src-id">GESHI_ERROR_INVALID_HEADER_TYPE</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a751"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a752"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a753"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a754"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Set&nbsp;that&nbsp;new&nbsp;header&nbsp;type</span></span></div></li> <li><div class="src-line"><a name="a755"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">header_type</span>&nbsp;=&nbsp;<span class="src-var">$type</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a756"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a757"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a758"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a759"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;styles&nbsp;for&nbsp;the&nbsp;code&nbsp;that&nbsp;will&nbsp;be&nbsp;outputted</span></div></li> <li><div class="src-line"><a name="a760"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;when&nbsp;this&nbsp;object&nbsp;is&nbsp;parsed.&nbsp;The&nbsp;style&nbsp;should&nbsp;be&nbsp;a</span></div></li> <li><div class="src-line"><a name="a761"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;string&nbsp;of&nbsp;valid&nbsp;stylesheet&nbsp;declarations</span></div></li> <li><div class="src-line"><a name="a762"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a763"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">&nbsp;The&nbsp;overall&nbsp;style&nbsp;for&nbsp;the&nbsp;outputted&nbsp;code&nbsp;block</span></div></li> <li><div class="src-line"><a name="a764"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;merge&nbsp;the&nbsp;styles&nbsp;with&nbsp;the&nbsp;current&nbsp;styles&nbsp;or&nbsp;not</span></div></li> <li><div class="src-line"><a name="a765"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a766"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a767"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_overall_style">set_overall_style</a><span class="src-sym">(</span><span class="src-var">$style</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a768"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$preserve_defaults</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a769"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">overall_style</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a770"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a771"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">overall_style</span>&nbsp;.=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a772"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a773"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a774"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a775"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a776"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;overall&nbsp;classname&nbsp;for&nbsp;this&nbsp;block&nbsp;of&nbsp;code.&nbsp;This</span></div></li> <li><div class="src-line"><a name="a777"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;class&nbsp;can&nbsp;then&nbsp;be&nbsp;used&nbsp;in&nbsp;a&nbsp;stylesheet&nbsp;to&nbsp;style&nbsp;this&nbsp;object's</span></div></li> <li><div class="src-line"><a name="a778"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;output</span></div></li> <li><div class="src-line"><a name="a779"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a780"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;class&nbsp;name&nbsp;to&nbsp;use&nbsp;for&nbsp;this&nbsp;block&nbsp;of&nbsp;code</span></div></li> <li><div class="src-line"><a name="a781"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a782"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a783"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_overall_class">set_overall_class</a><span class="src-sym">(</span><span class="src-var">$class</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a784"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">overall_class</span>&nbsp;=&nbsp;<span class="src-var">$class</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a785"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a786"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a787"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a788"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;overall&nbsp;id&nbsp;for&nbsp;this&nbsp;block&nbsp;of&nbsp;code.&nbsp;This&nbsp;id&nbsp;can&nbsp;then</span></div></li> <li><div class="src-line"><a name="a789"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;be&nbsp;used&nbsp;in&nbsp;a&nbsp;stylesheet&nbsp;to&nbsp;style&nbsp;this&nbsp;object's&nbsp;output</span></div></li> <li><div class="src-line"><a name="a790"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a791"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;ID&nbsp;to&nbsp;use&nbsp;for&nbsp;this&nbsp;block&nbsp;of&nbsp;code</span></div></li> <li><div class="src-line"><a name="a792"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a793"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a794"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_overall_id">set_overall_id</a><span class="src-sym">(</span><span class="src-var">$id</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a795"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">overall_id</span>&nbsp;=&nbsp;<span class="src-var">$id</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a796"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a797"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a798"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a799"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;whether&nbsp;CSS&nbsp;classes&nbsp;should&nbsp;be&nbsp;used&nbsp;to&nbsp;highlight&nbsp;the&nbsp;source.&nbsp;Default</span></div></li> <li><div class="src-line"><a name="a800"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;is&nbsp;off,&nbsp;calling&nbsp;this&nbsp;method&nbsp;with&nbsp;no&nbsp;arguments&nbsp;will&nbsp;turn&nbsp;it&nbsp;on</span></div></li> <li><div class="src-line"><a name="a801"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a802"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;turn&nbsp;classes&nbsp;on&nbsp;or&nbsp;not</span></div></li> <li><div class="src-line"><a name="a803"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a804"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a805"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodenable_classes">enable_classes</a><span class="src-sym">(</span><span class="src-var">$flag</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a806"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">use_classes</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a807"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a808"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a809"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a810"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;style&nbsp;for&nbsp;the&nbsp;actual&nbsp;code.&nbsp;This&nbsp;should&nbsp;be&nbsp;a&nbsp;string</span></div></li> <li><div class="src-line"><a name="a811"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;containing&nbsp;valid&nbsp;stylesheet&nbsp;declarations.&nbsp;If&nbsp;$preserve_defaults&nbsp;is</span></div></li> <li><div class="src-line"><a name="a812"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;true,&nbsp;then&nbsp;styles&nbsp;are&nbsp;merged&nbsp;with&nbsp;the&nbsp;default&nbsp;styles,&nbsp;with&nbsp;the</span></div></li> <li><div class="src-line"><a name="a813"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;user&nbsp;defined&nbsp;styles&nbsp;having&nbsp;priority</span></div></li> <li><div class="src-line"><a name="a814"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a815"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Note:&nbsp;Use&nbsp;this&nbsp;method&nbsp;to&nbsp;override&nbsp;any&nbsp;style&nbsp;changes&nbsp;you&nbsp;made&nbsp;to</span></div></li> <li><div class="src-line"><a name="a816"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;the&nbsp;line&nbsp;numbers&nbsp;if&nbsp;you&nbsp;are&nbsp;using&nbsp;line&nbsp;numbers,&nbsp;else&nbsp;the&nbsp;line&nbsp;of</span></div></li> <li><div class="src-line"><a name="a817"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;code&nbsp;will&nbsp;have&nbsp;the&nbsp;same&nbsp;style&nbsp;as&nbsp;the&nbsp;line&nbsp;number!&nbsp;Consult&nbsp;the</span></div></li> <li><div class="src-line"><a name="a818"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;GeSHi&nbsp;documentation&nbsp;for&nbsp;more&nbsp;information&nbsp;about&nbsp;this.</span></div></li> <li><div class="src-line"><a name="a819"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a820"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">&nbsp;The&nbsp;style&nbsp;to&nbsp;use&nbsp;for&nbsp;actual&nbsp;code</span></div></li> <li><div class="src-line"><a name="a821"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;merge&nbsp;the&nbsp;current&nbsp;styles&nbsp;with&nbsp;the&nbsp;new&nbsp;styles</span></div></li> <li><div class="src-line"><a name="a822"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a823"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a824"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_code_style">set_code_style</a><span class="src-sym">(</span><span class="src-var">$style</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a825"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$preserve_defaults</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a826"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">code_style</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a827"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a828"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">code_style</span>&nbsp;.=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a829"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a830"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a831"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a832"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a833"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;styles&nbsp;for&nbsp;the&nbsp;line&nbsp;numbers.</span></div></li> <li><div class="src-line"><a name="a834"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a835"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;style&nbsp;for&nbsp;the&nbsp;line&nbsp;numbers&nbsp;that&nbsp;are&nbsp;&quot;normal&quot;</span></div></li> <li><div class="src-line"><a name="a836"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string</span><span class="src-doc">|</span><span class="src-doc-type">boolean</span><span class="src-doc">If&nbsp;a&nbsp;string,&nbsp;this&nbsp;is&nbsp;the&nbsp;style&nbsp;of&nbsp;the&nbsp;line</span></div></li> <li><div class="src-line"><a name="a837"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;numbers&nbsp;that&nbsp;are&nbsp;&quot;fancy&quot;,&nbsp;otherwise&nbsp;if&nbsp;boolean&nbsp;then&nbsp;this</span></div></li> <li><div class="src-line"><a name="a838"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;defines&nbsp;whether&nbsp;the&nbsp;normal&nbsp;styles&nbsp;should&nbsp;be&nbsp;merged&nbsp;with&nbsp;the</span></div></li> <li><div class="src-line"><a name="a839"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;new&nbsp;normal&nbsp;styles&nbsp;or&nbsp;not</span></div></li> <li><div class="src-line"><a name="a840"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">If&nbsp;set,&nbsp;is&nbsp;the&nbsp;flag&nbsp;for&nbsp;whether&nbsp;to&nbsp;merge&nbsp;the&nbsp;&quot;fancy&quot;</span></div></li> <li><div class="src-line"><a name="a841"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;styles&nbsp;with&nbsp;the&nbsp;current&nbsp;styles&nbsp;or&nbsp;not</span></div></li> <li><div class="src-line"><a name="a842"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a843"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a844"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_line_style">set_line_style</a><span class="src-sym">(</span><span class="src-var">$style1</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$style2</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a845"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;we&nbsp;got&nbsp;2&nbsp;or&nbsp;three&nbsp;parameters</span></span></div></li> <li><div class="src-line"><a name="a846"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_bool">is_bool</a><span class="src-sym">(</span><span class="src-var">$style2</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a847"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-var">$style2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a848"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$style2</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a849"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a850"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a851"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Actually&nbsp;set&nbsp;the&nbsp;new&nbsp;styles</span></span></div></li> <li><div class="src-line"><a name="a852"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$preserve_defaults</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a853"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">line_style1</span>&nbsp;=&nbsp;<span class="src-var">$style1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a854"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">line_style2</span>&nbsp;=&nbsp;<span class="src-var">$style2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a855"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a856"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">line_style1</span>&nbsp;.=&nbsp;<span class="src-var">$style1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a857"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">line_style2</span>&nbsp;.=&nbsp;<span class="src-var">$style2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a858"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a859"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a860"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a861"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a862"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;whether&nbsp;line&nbsp;numbers&nbsp;should&nbsp;be&nbsp;displayed.</span></div></li> <li><div class="src-line"><a name="a863"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a864"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Valid&nbsp;values&nbsp;for&nbsp;the&nbsp;first&nbsp;parameter&nbsp;are:</span></div></li> <li><div class="src-line"><a name="a865"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a866"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;-&nbsp;GESHI_NO_LINE_NUMBERS:&nbsp;Line&nbsp;numbers&nbsp;will&nbsp;not&nbsp;be&nbsp;displayed</span></div></li> <li><div class="src-line"><a name="a867"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;-&nbsp;GESHI_NORMAL_LINE_NUMBERS:&nbsp;Line&nbsp;numbers&nbsp;will&nbsp;be&nbsp;displayed</span></div></li> <li><div class="src-line"><a name="a868"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;-&nbsp;GESHI_FANCY_LINE_NUMBERS:&nbsp;Fancy&nbsp;line&nbsp;numbers&nbsp;will&nbsp;be&nbsp;displayed</span></div></li> <li><div class="src-line"><a name="a869"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a870"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;For&nbsp;fancy&nbsp;line&nbsp;numbers,&nbsp;the&nbsp;second&nbsp;parameter&nbsp;is&nbsp;used&nbsp;to&nbsp;signal&nbsp;which&nbsp;lines</span></div></li> <li><div class="src-line"><a name="a871"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;are&nbsp;to&nbsp;be&nbsp;fancy.&nbsp;For&nbsp;example,&nbsp;if&nbsp;the&nbsp;value&nbsp;of&nbsp;this&nbsp;parameter&nbsp;is&nbsp;5&nbsp;then&nbsp;every</span></div></li> <li><div class="src-line"><a name="a872"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;5th&nbsp;line&nbsp;will&nbsp;be&nbsp;fancy.</span></div></li> <li><div class="src-line"><a name="a873"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a874"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">How&nbsp;line&nbsp;numbers&nbsp;should&nbsp;be&nbsp;displayed</span></div></li> <li><div class="src-line"><a name="a875"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">Defines&nbsp;which&nbsp;lines&nbsp;are&nbsp;fancy</span></div></li> <li><div class="src-line"><a name="a876"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a877"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a878"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodenable_line_numbers">enable_line_numbers</a><span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$nth_row</span>&nbsp;=&nbsp;<span class="src-num">5</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a879"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS&quot;&gt;GESHI_NO_LINE_NUMBERS&lt;/a&gt;</span>&nbsp;!=&nbsp;<span class="src-var">$flag</span>&nbsp;&amp;&amp;&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_NORMAL_LINE_NUMBERS&quot;&gt;GESHI_NORMAL_LINE_NUMBERS&lt;/a&gt;</span>&nbsp;!=&nbsp;<span class="src-var">$flag</span></span></div></li> <li><div class="src-line"><a name="a880"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&amp;&amp;&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_FANCY_LINE_NUMBERS&quot;&gt;GESHI_FANCY_LINE_NUMBERS&lt;/a&gt;</span>&nbsp;!=&nbsp;<span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a881"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">error</span>&nbsp;=&nbsp;<span class="src-id">GESHI_ERROR_INVALID_LINE_NUMBER_TYPE</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a882"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a883"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">line_numbers</span>&nbsp;=&nbsp;<span class="src-var">$flag</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a884"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">line_nth_row</span>&nbsp;=&nbsp;<span class="src-var">$nth_row</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a885"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a886"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a887"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a888"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;wether&nbsp;spans&nbsp;and&nbsp;other&nbsp;HTML&nbsp;markup&nbsp;generated&nbsp;by&nbsp;GeSHi&nbsp;can</span></div></li> <li><div class="src-line"><a name="a889"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;span&nbsp;over&nbsp;multiple&nbsp;lines&nbsp;or&nbsp;not.&nbsp;Defaults&nbsp;to&nbsp;true&nbsp;to&nbsp;reduce&nbsp;overhead.</span></div></li> <li><div class="src-line"><a name="a890"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Set&nbsp;it&nbsp;to&nbsp;false&nbsp;if&nbsp;you&nbsp;want&nbsp;to&nbsp;manipulate&nbsp;the&nbsp;output&nbsp;or&nbsp;manually&nbsp;display</span></div></li> <li><div class="src-line"><a name="a891"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;the&nbsp;code&nbsp;in&nbsp;an&nbsp;ordered&nbsp;list.</span></div></li> <li><div class="src-line"><a name="a892"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a893"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Wether&nbsp;multiline&nbsp;spans&nbsp;are&nbsp;allowed&nbsp;or&nbsp;not</span></div></li> <li><div class="src-line"><a name="a894"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.7.22</span></div></li> <li><div class="src-line"><a name="a895"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a896"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodenable_multiline_span">enable_multiline_span</a><span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a897"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">allow_multiline_span</span>&nbsp;=&nbsp;(bool)&nbsp;<span class="src-var">$flag</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a898"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a899"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a900"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a901"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Get&nbsp;current&nbsp;setting&nbsp;for&nbsp;multiline&nbsp;spans,&nbsp;see&nbsp;GeSHi-&gt;enable_multiline_span().</span></div></li> <li><div class="src-line"><a name="a902"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a903"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@see</span><span class="src-doc">&nbsp;enable_multiline_span</span></div></li> <li><div class="src-line"><a name="a904"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@return&nbsp;</span><span class="src-doc-type">bool&nbsp;</span></div></li> <li><div class="src-line"><a name="a905"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a906"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodget_multiline_span">get_multiline_span</a><span class="src-sym">(</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a907"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">allow_multiline_span</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a908"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a909"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a910"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a911"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;style&nbsp;for&nbsp;a&nbsp;keyword&nbsp;group.&nbsp;If&nbsp;$preserve_defaults&nbsp;is</span></div></li> <li><div class="src-line"><a name="a912"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;true,&nbsp;then&nbsp;styles&nbsp;are&nbsp;merged&nbsp;with&nbsp;the&nbsp;default&nbsp;styles,&nbsp;with&nbsp;the</span></div></li> <li><div class="src-line"><a name="a913"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;user&nbsp;defined&nbsp;styles&nbsp;having&nbsp;priority</span></div></li> <li><div class="src-line"><a name="a914"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a915"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;keyword&nbsp;group&nbsp;to&nbsp;change&nbsp;the&nbsp;styles&nbsp;of</span></div></li> <li><div class="src-line"><a name="a916"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">&nbsp;The&nbsp;style&nbsp;to&nbsp;make&nbsp;the&nbsp;keywords</span></div></li> <li><div class="src-line"><a name="a917"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;merge&nbsp;the&nbsp;new&nbsp;styles&nbsp;with&nbsp;the&nbsp;old&nbsp;or&nbsp;just</span></div></li> <li><div class="src-line"><a name="a918"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;to&nbsp;overwrite&nbsp;them</span></div></li> <li><div class="src-line"><a name="a919"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a920"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a921"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_keyword_group_style">set_keyword_group_style</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$style</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a922"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Set&nbsp;the&nbsp;style&nbsp;for&nbsp;this&nbsp;keyword&nbsp;group</span></span></div></li> <li><div class="src-line"><a name="a923"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$preserve_defaults</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a924"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a925"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a926"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a927"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a928"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a929"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Update&nbsp;the&nbsp;lexic&nbsp;permissions</span></span></div></li> <li><div class="src-line"><a name="a930"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a931"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a932"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a933"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a934"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a935"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a936"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Turns&nbsp;highlighting&nbsp;on/off&nbsp;for&nbsp;a&nbsp;keyword&nbsp;group</span></div></li> <li><div class="src-line"><a name="a937"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a938"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;keyword&nbsp;group&nbsp;to&nbsp;turn&nbsp;on&nbsp;or&nbsp;off</span></div></li> <li><div class="src-line"><a name="a939"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;turn&nbsp;highlighting&nbsp;for&nbsp;that&nbsp;group&nbsp;on&nbsp;or&nbsp;off</span></div></li> <li><div class="src-line"><a name="a940"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a941"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a942"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_keyword_group_highlighting">set_keyword_group_highlighting</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$flag</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a943"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a944"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a945"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a946"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a947"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;styles&nbsp;for&nbsp;comment&nbsp;groups.&nbsp;&nbsp;If&nbsp;$preserve_defaults&nbsp;is</span></div></li> <li><div class="src-line"><a name="a948"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;true,&nbsp;then&nbsp;styles&nbsp;are&nbsp;merged&nbsp;with&nbsp;the&nbsp;default&nbsp;styles,&nbsp;with&nbsp;the</span></div></li> <li><div class="src-line"><a name="a949"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;user&nbsp;defined&nbsp;styles&nbsp;having&nbsp;priority</span></div></li> <li><div class="src-line"><a name="a950"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a951"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;comment&nbsp;group&nbsp;to&nbsp;change&nbsp;the&nbsp;styles&nbsp;of</span></div></li> <li><div class="src-line"><a name="a952"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">&nbsp;The&nbsp;style&nbsp;to&nbsp;make&nbsp;the&nbsp;comments</span></div></li> <li><div class="src-line"><a name="a953"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;merge&nbsp;the&nbsp;new&nbsp;styles&nbsp;with&nbsp;the&nbsp;old&nbsp;or&nbsp;just</span></div></li> <li><div class="src-line"><a name="a954"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;to&nbsp;overwrite&nbsp;them</span></div></li> <li><div class="src-line"><a name="a955"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a956"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a957"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_comments_style">set_comments_style</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$style</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a958"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$preserve_defaults</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a959"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a960"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a961"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a962"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a963"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a964"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a965"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a966"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Turns&nbsp;highlighting&nbsp;on/off&nbsp;for&nbsp;comment&nbsp;groups</span></div></li> <li><div class="src-line"><a name="a967"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a968"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;comment&nbsp;group&nbsp;to&nbsp;turn&nbsp;on&nbsp;or&nbsp;off</span></div></li> <li><div class="src-line"><a name="a969"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;turn&nbsp;highlighting&nbsp;for&nbsp;that&nbsp;group&nbsp;on&nbsp;or&nbsp;off</span></div></li> <li><div class="src-line"><a name="a970"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a971"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a972"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_comments_highlighting">set_comments_highlighting</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$flag</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a973"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a974"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a975"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a976"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a977"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;styles&nbsp;for&nbsp;escaped&nbsp;characters.&nbsp;If&nbsp;$preserve_defaults&nbsp;is</span></div></li> <li><div class="src-line"><a name="a978"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;true,&nbsp;then&nbsp;styles&nbsp;are&nbsp;merged&nbsp;with&nbsp;the&nbsp;default&nbsp;styles,&nbsp;with&nbsp;the</span></div></li> <li><div class="src-line"><a name="a979"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;user&nbsp;defined&nbsp;styles&nbsp;having&nbsp;priority</span></div></li> <li><div class="src-line"><a name="a980"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a981"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">&nbsp;The&nbsp;style&nbsp;to&nbsp;make&nbsp;the&nbsp;escape&nbsp;characters</span></div></li> <li><div class="src-line"><a name="a982"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;merge&nbsp;the&nbsp;new&nbsp;styles&nbsp;with&nbsp;the&nbsp;old&nbsp;or&nbsp;just</span></div></li> <li><div class="src-line"><a name="a983"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;to&nbsp;overwrite&nbsp;them</span></div></li> <li><div class="src-line"><a name="a984"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a985"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a986"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_escape_characters_style">set_escape_characters_style</a><span class="src-sym">(</span><span class="src-var">$style</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a987"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$preserve_defaults</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a988"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a989"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a990"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a991"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a992"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a993"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a994"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a995"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Turns&nbsp;highlighting&nbsp;on/off&nbsp;for&nbsp;escaped&nbsp;characters</span></div></li> <li><div class="src-line"><a name="a996"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a997"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;turn&nbsp;highlighting&nbsp;for&nbsp;escape&nbsp;characters&nbsp;on&nbsp;or&nbsp;off</span></div></li> <li><div class="src-line"><a name="a998"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a999"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1000"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_escape_characters_highlighting">set_escape_characters_highlighting</a><span class="src-sym">(</span><span class="src-var">$flag</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1001"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1002"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1003"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1004"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1005"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;styles&nbsp;for&nbsp;brackets.&nbsp;If&nbsp;$preserve_defaults&nbsp;is</span></div></li> <li><div class="src-line"><a name="a1006"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;true,&nbsp;then&nbsp;styles&nbsp;are&nbsp;merged&nbsp;with&nbsp;the&nbsp;default&nbsp;styles,&nbsp;with&nbsp;the</span></div></li> <li><div class="src-line"><a name="a1007"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;user&nbsp;defined&nbsp;styles&nbsp;having&nbsp;priority</span></div></li> <li><div class="src-line"><a name="a1008"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1009"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;This&nbsp;method&nbsp;is&nbsp;DEPRECATED:&nbsp;use&nbsp;set_symbols_style&nbsp;instead.</span></div></li> <li><div class="src-line"><a name="a1010"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;This&nbsp;method&nbsp;will&nbsp;be&nbsp;removed&nbsp;in&nbsp;1.2.X</span></div></li> <li><div class="src-line"><a name="a1011"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1012"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">&nbsp;The&nbsp;style&nbsp;to&nbsp;make&nbsp;the&nbsp;brackets</span></div></li> <li><div class="src-line"><a name="a1013"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;merge&nbsp;the&nbsp;new&nbsp;styles&nbsp;with&nbsp;the&nbsp;old&nbsp;or&nbsp;just</span></div></li> <li><div class="src-line"><a name="a1014"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;to&nbsp;overwrite&nbsp;them</span></div></li> <li><div class="src-line"><a name="a1015"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1016"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@deprecated</span><span class="src-doc">&nbsp;In&nbsp;favour&nbsp;of&nbsp;set_symbols_style</span></div></li> <li><div class="src-line"><a name="a1017"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1018"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_brackets_style">set_brackets_style</a><span class="src-sym">(</span><span class="src-var">$style</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1019"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$preserve_defaults</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1020"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1021"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1022"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1023"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1024"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1025"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1026"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1027"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Turns&nbsp;highlighting&nbsp;on/off&nbsp;for&nbsp;brackets</span></div></li> <li><div class="src-line"><a name="a1028"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1029"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;This&nbsp;method&nbsp;is&nbsp;DEPRECATED:&nbsp;use&nbsp;set_symbols_highlighting&nbsp;instead.</span></div></li> <li><div class="src-line"><a name="a1030"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;This&nbsp;method&nbsp;will&nbsp;be&nbsp;remove&nbsp;in&nbsp;1.2.X</span></div></li> <li><div class="src-line"><a name="a1031"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1032"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;turn&nbsp;highlighting&nbsp;for&nbsp;brackets&nbsp;on&nbsp;or&nbsp;off</span></div></li> <li><div class="src-line"><a name="a1033"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1034"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@deprecated</span><span class="src-doc">&nbsp;In&nbsp;favour&nbsp;of&nbsp;set_symbols_highlighting</span></div></li> <li><div class="src-line"><a name="a1035"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1036"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_brackets_highlighting">set_brackets_highlighting</a><span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1037"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1038"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1039"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1040"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1041"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;styles&nbsp;for&nbsp;symbols.&nbsp;If&nbsp;$preserve_defaults&nbsp;is</span></div></li> <li><div class="src-line"><a name="a1042"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;true,&nbsp;then&nbsp;styles&nbsp;are&nbsp;merged&nbsp;with&nbsp;the&nbsp;default&nbsp;styles,&nbsp;with&nbsp;the</span></div></li> <li><div class="src-line"><a name="a1043"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;user&nbsp;defined&nbsp;styles&nbsp;having&nbsp;priority</span></div></li> <li><div class="src-line"><a name="a1044"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1045"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">&nbsp;The&nbsp;style&nbsp;to&nbsp;make&nbsp;the&nbsp;symbols</span></div></li> <li><div class="src-line"><a name="a1046"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;merge&nbsp;the&nbsp;new&nbsp;styles&nbsp;with&nbsp;the&nbsp;old&nbsp;or&nbsp;just</span></div></li> <li><div class="src-line"><a name="a1047"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;to&nbsp;overwrite&nbsp;them</span></div></li> <li><div class="src-line"><a name="a1048"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;Tells&nbsp;the&nbsp;group&nbsp;of&nbsp;symbols&nbsp;for&nbsp;which&nbsp;style&nbsp;should&nbsp;be&nbsp;set.</span></div></li> <li><div class="src-line"><a name="a1049"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.1</span></div></li> <li><div class="src-line"><a name="a1050"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1051"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_symbols_style">set_symbols_style</a><span class="src-sym">(</span><span class="src-var">$style</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$group</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1052"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Update&nbsp;the&nbsp;style&nbsp;of&nbsp;symbols</span></span></div></li> <li><div class="src-line"><a name="a1053"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$preserve_defaults</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1054"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1055"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1056"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1057"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1058"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1059"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;For&nbsp;backward&nbsp;compatibility</span></span></div></li> <li><div class="src-line"><a name="a1060"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-num">0</span>&nbsp;==&nbsp;<span class="src-var">$group</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1061"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodset_brackets_style">set_brackets_style</a>&nbsp;<span class="src-sym">(</span><span class="src-var">$style</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1062"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1063"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1064"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1065"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1066"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Turns&nbsp;highlighting&nbsp;on/off&nbsp;for&nbsp;symbols</span></div></li> <li><div class="src-line"><a name="a1067"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1068"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;turn&nbsp;highlighting&nbsp;for&nbsp;symbols&nbsp;on&nbsp;or&nbsp;off</span></div></li> <li><div class="src-line"><a name="a1069"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1070"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1071"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_symbols_highlighting">set_symbols_highlighting</a><span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1072"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Update&nbsp;lexic&nbsp;permissions&nbsp;for&nbsp;this&nbsp;symbol&nbsp;group</span></span></div></li> <li><div class="src-line"><a name="a1073"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1074"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1075"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;For&nbsp;backward&nbsp;compatibility</span></span></div></li> <li><div class="src-line"><a name="a1076"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodset_brackets_highlighting">set_brackets_highlighting</a>&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1077"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1078"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1079"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1080"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;styles&nbsp;for&nbsp;strings.&nbsp;If&nbsp;$preserve_defaults&nbsp;is</span></div></li> <li><div class="src-line"><a name="a1081"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;true,&nbsp;then&nbsp;styles&nbsp;are&nbsp;merged&nbsp;with&nbsp;the&nbsp;default&nbsp;styles,&nbsp;with&nbsp;the</span></div></li> <li><div class="src-line"><a name="a1082"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;user&nbsp;defined&nbsp;styles&nbsp;having&nbsp;priority</span></div></li> <li><div class="src-line"><a name="a1083"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1084"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">&nbsp;The&nbsp;style&nbsp;to&nbsp;make&nbsp;the&nbsp;escape&nbsp;characters</span></div></li> <li><div class="src-line"><a name="a1085"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;merge&nbsp;the&nbsp;new&nbsp;styles&nbsp;with&nbsp;the&nbsp;old&nbsp;or&nbsp;just</span></div></li> <li><div class="src-line"><a name="a1086"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;to&nbsp;overwrite&nbsp;them</span></div></li> <li><div class="src-line"><a name="a1087"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1088"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1089"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_strings_style">set_strings_style</a><span class="src-sym">(</span><span class="src-var">$style</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1090"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$preserve_defaults</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1091"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'STRINGS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1092"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1093"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'STRINGS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1094"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1095"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1096"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1097"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1098"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Turns&nbsp;highlighting&nbsp;on/off&nbsp;for&nbsp;strings</span></div></li> <li><div class="src-line"><a name="a1099"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1100"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;turn&nbsp;highlighting&nbsp;for&nbsp;strings&nbsp;on&nbsp;or&nbsp;off</span></div></li> <li><div class="src-line"><a name="a1101"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1102"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1103"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_strings_highlighting">set_strings_highlighting</a><span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1104"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'STRINGS'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1105"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1106"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1107"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1108"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;styles&nbsp;for&nbsp;numbers.&nbsp;If&nbsp;$preserve_defaults&nbsp;is</span></div></li> <li><div class="src-line"><a name="a1109"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;true,&nbsp;then&nbsp;styles&nbsp;are&nbsp;merged&nbsp;with&nbsp;the&nbsp;default&nbsp;styles,&nbsp;with&nbsp;the</span></div></li> <li><div class="src-line"><a name="a1110"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;user&nbsp;defined&nbsp;styles&nbsp;having&nbsp;priority</span></div></li> <li><div class="src-line"><a name="a1111"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1112"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">&nbsp;The&nbsp;style&nbsp;to&nbsp;make&nbsp;the&nbsp;numbers</span></div></li> <li><div class="src-line"><a name="a1113"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;merge&nbsp;the&nbsp;new&nbsp;styles&nbsp;with&nbsp;the&nbsp;old&nbsp;or&nbsp;just</span></div></li> <li><div class="src-line"><a name="a1114"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;to&nbsp;overwrite&nbsp;them</span></div></li> <li><div class="src-line"><a name="a1115"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1116"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1117"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_numbers_style">set_numbers_style</a><span class="src-sym">(</span><span class="src-var">$style</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1118"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$preserve_defaults</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1119"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1120"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1121"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1122"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1123"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1124"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1125"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1126"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Turns&nbsp;highlighting&nbsp;on/off&nbsp;for&nbsp;numbers</span></div></li> <li><div class="src-line"><a name="a1127"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1128"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;turn&nbsp;highlighting&nbsp;for&nbsp;numbers&nbsp;on&nbsp;or&nbsp;off</span></div></li> <li><div class="src-line"><a name="a1129"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1130"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1131"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_numbers_highlighting">set_numbers_highlighting</a><span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1132"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1133"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1134"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1135"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1136"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;styles&nbsp;for&nbsp;methods.&nbsp;$key&nbsp;is&nbsp;a&nbsp;number&nbsp;that&nbsp;references&nbsp;the</span></div></li> <li><div class="src-line"><a name="a1137"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;appropriate&nbsp;&quot;object&nbsp;splitter&quot;&nbsp;-&nbsp;see&nbsp;the&nbsp;language&nbsp;file&nbsp;for&nbsp;the&nbsp;language</span></div></li> <li><div class="src-line"><a name="a1138"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;you&nbsp;are&nbsp;highlighting&nbsp;to&nbsp;get&nbsp;this&nbsp;number.&nbsp;If&nbsp;$preserve_defaults&nbsp;is</span></div></li> <li><div class="src-line"><a name="a1139"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;true,&nbsp;then&nbsp;styles&nbsp;are&nbsp;merged&nbsp;with&nbsp;the&nbsp;default&nbsp;styles,&nbsp;with&nbsp;the</span></div></li> <li><div class="src-line"><a name="a1140"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;user&nbsp;defined&nbsp;styles&nbsp;having&nbsp;priority</span></div></li> <li><div class="src-line"><a name="a1141"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1142"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;object&nbsp;splitter&nbsp;to&nbsp;change&nbsp;the&nbsp;styles&nbsp;of</span></div></li> <li><div class="src-line"><a name="a1143"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">&nbsp;The&nbsp;style&nbsp;to&nbsp;make&nbsp;the&nbsp;methods</span></div></li> <li><div class="src-line"><a name="a1144"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;merge&nbsp;the&nbsp;new&nbsp;styles&nbsp;with&nbsp;the&nbsp;old&nbsp;or&nbsp;just</span></div></li> <li><div class="src-line"><a name="a1145"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;to&nbsp;overwrite&nbsp;them</span></div></li> <li><div class="src-line"><a name="a1146"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1147"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1148"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_methods_style">set_methods_style</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$style</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1149"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$preserve_defaults</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1150"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'METHODS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1151"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1152"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'METHODS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1153"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1154"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1155"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1156"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1157"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Turns&nbsp;highlighting&nbsp;on/off&nbsp;for&nbsp;methods</span></div></li> <li><div class="src-line"><a name="a1158"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1159"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;turn&nbsp;highlighting&nbsp;for&nbsp;methods&nbsp;on&nbsp;or&nbsp;off</span></div></li> <li><div class="src-line"><a name="a1160"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1161"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1162"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_methods_highlighting">set_methods_highlighting</a><span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1163"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'METHODS'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1164"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1165"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1166"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1167"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;styles&nbsp;for&nbsp;regexps.&nbsp;If&nbsp;$preserve_defaults&nbsp;is</span></div></li> <li><div class="src-line"><a name="a1168"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;true,&nbsp;then&nbsp;styles&nbsp;are&nbsp;merged&nbsp;with&nbsp;the&nbsp;default&nbsp;styles,&nbsp;with&nbsp;the</span></div></li> <li><div class="src-line"><a name="a1169"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;user&nbsp;defined&nbsp;styles&nbsp;having&nbsp;priority</span></div></li> <li><div class="src-line"><a name="a1170"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1171"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">&nbsp;The&nbsp;style&nbsp;to&nbsp;make&nbsp;the&nbsp;regular&nbsp;expression&nbsp;matches</span></div></li> <li><div class="src-line"><a name="a1172"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;merge&nbsp;the&nbsp;new&nbsp;styles&nbsp;with&nbsp;the&nbsp;old&nbsp;or&nbsp;just</span></div></li> <li><div class="src-line"><a name="a1173"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;to&nbsp;overwrite&nbsp;them</span></div></li> <li><div class="src-line"><a name="a1174"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1175"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1176"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_regexps_style">set_regexps_style</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$style</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$preserve_defaults</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1177"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$preserve_defaults</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1178"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1179"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1180"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1181"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1182"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1183"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1184"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1185"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Turns&nbsp;highlighting&nbsp;on/off&nbsp;for&nbsp;regexps</span></div></li> <li><div class="src-line"><a name="a1186"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1187"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;regular&nbsp;expression&nbsp;group&nbsp;to&nbsp;turn&nbsp;on&nbsp;or&nbsp;off</span></div></li> <li><div class="src-line"><a name="a1188"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;turn&nbsp;highlighting&nbsp;for&nbsp;the&nbsp;regular&nbsp;expression&nbsp;group&nbsp;on&nbsp;or&nbsp;off</span></div></li> <li><div class="src-line"><a name="a1189"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1190"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1191"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_regexps_highlighting">set_regexps_highlighting</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1192"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1193"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1194"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1195"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1196"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;whether&nbsp;a&nbsp;set&nbsp;of&nbsp;keywords&nbsp;are&nbsp;checked&nbsp;for&nbsp;in&nbsp;a&nbsp;case&nbsp;sensitive&nbsp;manner</span></div></li> <li><div class="src-line"><a name="a1197"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1198"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">The&nbsp;key&nbsp;of&nbsp;the&nbsp;keyword&nbsp;group&nbsp;to&nbsp;change&nbsp;the&nbsp;case&nbsp;sensitivity&nbsp;of</span></div></li> <li><div class="src-line"><a name="a1199"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;check&nbsp;in&nbsp;a&nbsp;case&nbsp;sensitive&nbsp;manner&nbsp;or&nbsp;not</span></div></li> <li><div class="src-line"><a name="a1200"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1201"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1202"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_case_sensitivity">set_case_sensitivity</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$case</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1203"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'CASE_SENSITIVE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$case</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1204"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1205"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1206"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1207"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;case&nbsp;that&nbsp;keywords&nbsp;should&nbsp;use&nbsp;when&nbsp;found.&nbsp;Use&nbsp;the&nbsp;constants:</span></div></li> <li><div class="src-line"><a name="a1208"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1209"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;-&nbsp;GESHI_CAPS_NO_CHANGE:&nbsp;leave&nbsp;keywords&nbsp;as-is</span></div></li> <li><div class="src-line"><a name="a1210"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;-&nbsp;GESHI_CAPS_UPPER:&nbsp;convert&nbsp;all&nbsp;keywords&nbsp;to&nbsp;uppercase&nbsp;where&nbsp;found</span></div></li> <li><div class="src-line"><a name="a1211"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;-&nbsp;GESHI_CAPS_LOWER:&nbsp;convert&nbsp;all&nbsp;keywords&nbsp;to&nbsp;lowercase&nbsp;where&nbsp;found</span></div></li> <li><div class="src-line"><a name="a1212"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1213"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">A&nbsp;constant&nbsp;specifying&nbsp;what&nbsp;to&nbsp;do&nbsp;with&nbsp;matched&nbsp;keywords</span></div></li> <li><div class="src-line"><a name="a1214"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.1</span></div></li> <li><div class="src-line"><a name="a1215"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1216"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_case_keywords">set_case_keywords</a><span class="src-sym">(</span><span class="src-var">$case</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1217"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/in_array">in_array</a><span class="src-sym">(</span><span class="src-var">$case</span><span class="src-sym">,</span>&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a1218"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_CAPS_NO_CHANGE&quot;&gt;GESHI_CAPS_NO_CHANGE&lt;/a&gt;</span><span class="src-sym">,</span>&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_CAPS_UPPER&quot;&gt;GESHI_CAPS_UPPER&lt;/a&gt;</span><span class="src-sym">,</span>&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_CAPS_LOWER&quot;&gt;GESHI_CAPS_LOWER&lt;/a&gt;</span><span class="src-sym">)))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1219"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'CASE_KEYWORDS'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$case</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1220"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1221"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1222"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1223"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1224"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;how&nbsp;many&nbsp;spaces&nbsp;a&nbsp;tab&nbsp;is&nbsp;substituted&nbsp;for</span></div></li> <li><div class="src-line"><a name="a1225"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1226"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Widths&nbsp;below&nbsp;zero&nbsp;are&nbsp;ignored</span></div></li> <li><div class="src-line"><a name="a1227"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1228"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">The&nbsp;tab&nbsp;width</span></div></li> <li><div class="src-line"><a name="a1229"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1230"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1231"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_tab_width">set_tab_width</a><span class="src-sym">(</span><span class="src-var">$width</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1232"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">tab_width</span>&nbsp;=&nbsp;<a href="http://www.php.net/intval">intval</a><span class="src-sym">(</span><span class="src-var">$width</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1233"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1234"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;it&nbsp;fit's&nbsp;the&nbsp;constraints:</span></span></div></li> <li><div class="src-line"><a name="a1235"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">tab_width</span>&nbsp;<&nbsp;<span class="src-num">1</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1236"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Return&nbsp;it&nbsp;to&nbsp;the&nbsp;default</span></span></div></li> <li><div class="src-line"><a name="a1237"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">tab_width</span>&nbsp;=&nbsp;<span class="src-num">8</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1238"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1239"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1240"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1241"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1242"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;whether&nbsp;or&nbsp;not&nbsp;to&nbsp;use&nbsp;tab-stop&nbsp;width&nbsp;specifed&nbsp;by&nbsp;language</span></div></li> <li><div class="src-line"><a name="a1243"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1244"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;use&nbsp;language-specific&nbsp;tab-stop&nbsp;widths</span></div></li> <li><div class="src-line"><a name="a1245"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.7.20</span></div></li> <li><div class="src-line"><a name="a1246"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1247"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_use_language_tab_width">set_use_language_tab_width</a><span class="src-sym">(</span><span class="src-var">$use</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1248"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">use_language_tab_width</span>&nbsp;=&nbsp;(bool)&nbsp;<span class="src-var">$use</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1249"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1250"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1251"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1252"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Returns&nbsp;the&nbsp;tab&nbsp;width&nbsp;to&nbsp;use,&nbsp;based&nbsp;on&nbsp;the&nbsp;current&nbsp;language&nbsp;and&nbsp;user</span></div></li> <li><div class="src-line"><a name="a1253"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;preference</span></div></li> <li><div class="src-line"><a name="a1254"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1255"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@return&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">Tab&nbsp;width</span></div></li> <li><div class="src-line"><a name="a1256"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.7.20</span></div></li> <li><div class="src-line"><a name="a1257"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1258"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodget_real_tab_width">get_real_tab_width</a><span class="src-sym">(</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1259"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">use_language_tab_width</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a1260"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'TAB_WIDTH'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1261"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">tab_width</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1262"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1263"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'TAB_WIDTH'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1264"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1265"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1266"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1267"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1268"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Enables/disables&nbsp;strict&nbsp;highlighting.&nbsp;Default&nbsp;is&nbsp;off,&nbsp;calling&nbsp;this</span></div></li> <li><div class="src-line"><a name="a1269"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;method&nbsp;without&nbsp;parameters&nbsp;will&nbsp;turn&nbsp;it&nbsp;on.&nbsp;See&nbsp;documentation</span></div></li> <li><div class="src-line"><a name="a1270"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;for&nbsp;more&nbsp;details&nbsp;on&nbsp;strict&nbsp;mode&nbsp;and&nbsp;where&nbsp;to&nbsp;use&nbsp;it.</span></div></li> <li><div class="src-line"><a name="a1271"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1272"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;to&nbsp;enable&nbsp;strict&nbsp;mode&nbsp;or&nbsp;not</span></div></li> <li><div class="src-line"><a name="a1273"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1274"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1275"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodenable_strict_mode">enable_strict_mode</a><span class="src-sym">(</span><span class="src-var">$mode</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1276"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">GESHI_MAYBE</span>&nbsp;==&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STRICT_MODE_APPLIES'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1277"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">strict_mode</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$mode</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">GESHI_ALWAYS</span>&nbsp;:&nbsp;<span class="src-id">GESHI_NEVER</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1278"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1279"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1280"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1281"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1282"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Disables&nbsp;all&nbsp;highlighting</span></div></li> <li><div class="src-line"><a name="a1283"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1284"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1285"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@todo</span><span class="src-doc">&nbsp;&nbsp;Rewrite&nbsp;with&nbsp;array&nbsp;traversal</span></div></li> <li><div class="src-line"><a name="a1286"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@deprecated</span><span class="src-doc">&nbsp;In&nbsp;favour&nbsp;of&nbsp;enable_highlighting</span></div></li> <li><div class="src-line"><a name="a1287"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1288"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methoddisable_highlighting">disable_highlighting</a><span class="src-sym">(</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1289"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodenable_highlighting">enable_highlighting</a><span class="src-sym">(</span><span class="src-id">false</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1290"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1291"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1292"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1293"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Enables&nbsp;all&nbsp;highlighting</span></div></li> <li><div class="src-line"><a name="a1294"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1295"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;optional&nbsp;flag&nbsp;parameter&nbsp;was&nbsp;added&nbsp;in&nbsp;version&nbsp;1.0.7.21&nbsp;and&nbsp;can&nbsp;be&nbsp;used</span></div></li> <li><div class="src-line"><a name="a1296"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;to&nbsp;enable&nbsp;(true)&nbsp;or&nbsp;disable&nbsp;(false)&nbsp;all&nbsp;highlighting.</span></div></li> <li><div class="src-line"><a name="a1297"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1298"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1299"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">A&nbsp;flag&nbsp;specifying&nbsp;whether&nbsp;to&nbsp;enable&nbsp;or&nbsp;disable&nbsp;all&nbsp;highlighting</span></div></li> <li><div class="src-line"><a name="a1300"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@todo</span><span class="src-doc">&nbsp;&nbsp;Rewrite&nbsp;with&nbsp;array&nbsp;traversal</span></div></li> <li><div class="src-line"><a name="a1301"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1302"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodenable_highlighting">enable_highlighting</a><span class="src-sym">(</span><span class="src-var">$flag</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1303"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$flag</span>&nbsp;=&nbsp;<span class="src-var">$flag</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1304"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span>&nbsp;=&gt;&nbsp;<span class="src-var">$value</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1305"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$value</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1306"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$value</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$k</span>&nbsp;=&gt;&nbsp;<span class="src-var">$v</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1307"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$flag</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1308"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1309"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1310"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$flag</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1311"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1312"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1313"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1314"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Context&nbsp;blocks</span></span></div></li> <li><div class="src-line"><a name="a1315"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">enable_important_blocks</span>&nbsp;=&nbsp;<span class="src-var">$flag</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1316"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1317"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1318"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1319"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Given&nbsp;a&nbsp;file&nbsp;extension,&nbsp;this&nbsp;method&nbsp;returns&nbsp;either&nbsp;a&nbsp;valid&nbsp;geshi&nbsp;language</span></div></li> <li><div class="src-line"><a name="a1320"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;name,&nbsp;or&nbsp;the&nbsp;empty&nbsp;string&nbsp;if&nbsp;it&nbsp;couldn't&nbsp;be&nbsp;found</span></div></li> <li><div class="src-line"><a name="a1321"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1322"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;extension&nbsp;to&nbsp;get&nbsp;a&nbsp;language&nbsp;name&nbsp;for</span></div></li> <li><div class="src-line"><a name="a1323"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">array&nbsp;</span><span class="src-doc">&nbsp;A&nbsp;lookup&nbsp;array&nbsp;to&nbsp;use&nbsp;instead&nbsp;of&nbsp;the&nbsp;default&nbsp;one</span></div></li> <li><div class="src-line"><a name="a1324"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.5</span></div></li> <li><div class="src-line"><a name="a1325"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@todo</span><span class="src-doc">&nbsp;Re-think&nbsp;about&nbsp;how&nbsp;this&nbsp;method&nbsp;works&nbsp;(maybe&nbsp;make&nbsp;it&nbsp;private&nbsp;and/or&nbsp;make&nbsp;it</span></div></li> <li><div class="src-line"><a name="a1326"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;a&nbsp;extension-&gt;lang&nbsp;lookup?)</span></div></li> <li><div class="src-line"><a name="a1327"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@todo</span><span class="src-doc">&nbsp;static?</span></div></li> <li><div class="src-line"><a name="a1328"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1329"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodget_language_name_from_extension">get_language_name_from_extension</a><span class="src-sym">(</span>&nbsp;<span class="src-var">$extension</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$lookup</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1330"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>&nbsp;<span class="src-sym">!</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$lookup</span><span class="src-sym">)</span>&nbsp;||&nbsp;<span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$lookup</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1331"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$lookup</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a1332"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'actionscript'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'as'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1333"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'ada'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'a'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'ada'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'adb'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'ads'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1334"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'apache'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'conf'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1335"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'asm'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'ash'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'asm'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'inc'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1336"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'asp'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'asp'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1337"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'bash'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'sh'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1338"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'bf'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'bf'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1339"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'c'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'c'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'h'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1340"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'c_mac'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'c'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'h'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1341"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'caddcl'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1342"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'cadlisp'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1343"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'cdfg'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'cdfg'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1344"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'cobol'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'cbl'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1345"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'cpp'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'cpp'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'hpp'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'C'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'H'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'CPP'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'HPP'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1346"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'csharp'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'cs'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1347"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'css'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'css'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1348"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'d'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'d'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1349"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'delphi'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'dpk'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'dpr'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'pp'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'pas'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1350"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'diff'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'diff'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'patch'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1351"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'dos'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'bat'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'cmd'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1352"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'gettext'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'po'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'pot'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1353"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'gml'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'gml'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1354"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'gnuplot'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'plt'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1355"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'groovy'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'groovy'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1356"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'haskell'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'hs'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1357"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'html4strict'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'html'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'htm'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1358"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'ini'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'ini'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'desktop'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1359"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'java'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'java'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1360"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'javascript'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'js'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1361"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'klonec'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'kl1'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1362"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'klonecpp'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'klx'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1363"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'latex'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'tex'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1364"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'lisp'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'lisp'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1365"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'lua'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'lua'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1366"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'matlab'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'m'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1367"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'mpasm'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1368"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'mysql'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'sql'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1369"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'nsis'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1370"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'objc'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1371"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'oobas'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1372"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'oracle8'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1373"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'oracle10'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1374"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'pascal'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'pas'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1375"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'perl'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'pl'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'pm'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1376"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'php'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'php'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'php5'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'phtml'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'phps'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1377"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'povray'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'pov'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1378"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'providex'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'pvc'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'pvx'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1379"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'prolog'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'pl'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1380"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'python'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'py'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1381"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'qbasic'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'bi'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1382"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'reg'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'reg'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1383"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'ruby'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'rb'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1384"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'sas'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'sas'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1385"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'scala'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'scala'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1386"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'scheme'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'scm'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1387"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'scilab'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'sci'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1388"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'smalltalk'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'st'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1389"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'smarty'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1390"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'tcl'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'tcl'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1391"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'vb'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'bas'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1392"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'vbnet'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1393"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'visualfoxpro'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1394"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'whitespace'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'ws'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1395"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'xml'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'xml'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'svg'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1396"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'z80'</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'z80'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'asm'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'inc'</span><span class="src-sym">)</span></span></div></li> <li><div class="src-line"><a name="a1397"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1398"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1399"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1400"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$lookup</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$lang</span>&nbsp;=&gt;&nbsp;<span class="src-var">$extensions</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1401"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/in_array">in_array</a><span class="src-sym">(</span><span class="src-var">$extension</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$extensions</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1402"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$lang</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1403"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1404"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1405"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1406"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1407"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1408"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1409"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Given&nbsp;a&nbsp;file&nbsp;name,&nbsp;this&nbsp;method&nbsp;loads&nbsp;its&nbsp;contents&nbsp;in,&nbsp;and&nbsp;attempts</span></div></li> <li><div class="src-line"><a name="a1410"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;to&nbsp;set&nbsp;the&nbsp;language&nbsp;automatically.&nbsp;An&nbsp;optional&nbsp;lookup&nbsp;table&nbsp;can&nbsp;be</span></div></li> <li><div class="src-line"><a name="a1411"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;passed&nbsp;for&nbsp;looking&nbsp;up&nbsp;the&nbsp;language&nbsp;name.&nbsp;If&nbsp;not&nbsp;specified&nbsp;a&nbsp;default</span></div></li> <li><div class="src-line"><a name="a1412"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;table&nbsp;is&nbsp;used</span></div></li> <li><div class="src-line"><a name="a1413"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1414"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;language&nbsp;table&nbsp;is&nbsp;in&nbsp;the&nbsp;form</span></div></li> <li><div class="src-line"><a name="a1415"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&lt;pre&gt;array(</span></div></li> <li><div class="src-line"><a name="a1416"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;'lang_name'&nbsp;=&gt;&nbsp;array('extension',&nbsp;'extension',&nbsp;...),</span></div></li> <li><div class="src-line"><a name="a1417"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;'lang_name'&nbsp;...</span></div></li> <li><div class="src-line"><a name="a1418"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;);&lt;/pre&gt;</span></div></li> <li><div class="src-line"><a name="a1419"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1420"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;filename&nbsp;to&nbsp;load&nbsp;the&nbsp;source&nbsp;from</span></div></li> <li><div class="src-line"><a name="a1421"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">array&nbsp;</span><span class="src-doc">&nbsp;A&nbsp;lookup&nbsp;array&nbsp;to&nbsp;use&nbsp;instead&nbsp;of&nbsp;the&nbsp;default&nbsp;one</span></div></li> <li><div class="src-line"><a name="a1422"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@todo</span><span class="src-doc">&nbsp;Complete&nbsp;rethink&nbsp;of&nbsp;this&nbsp;and&nbsp;above&nbsp;method</span></div></li> <li><div class="src-line"><a name="a1423"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.5</span></div></li> <li><div class="src-line"><a name="a1424"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1425"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodload_from_file">load_from_file</a><span class="src-sym">(</span><span class="src-var">$file_name</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$lookup</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1426"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_readable">is_readable</a><span class="src-sym">(</span><span class="src-var">$file_name</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1427"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodset_source">set_source</a><span class="src-sym">(</span><a href="http://www.php.net/file_get_contents">file_get_contents</a><span class="src-sym">(</span><span class="src-var">$file_name</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1428"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodset_language">set_language</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodget_language_name_from_extension">get_language_name_from_extension</a><span class="src-sym">(</span><a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><a href="http://www.php.net/strrchr">strrchr</a><span class="src-sym">(</span><span class="src-var">$file_name</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'.'</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$lookup</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1429"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1430"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">error</span>&nbsp;=&nbsp;<span class="src-id">GESHI_ERROR_FILE_NOT_READABLE</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1431"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1432"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1433"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1434"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1435"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Adds&nbsp;a&nbsp;keyword&nbsp;to&nbsp;a&nbsp;keyword&nbsp;group&nbsp;for&nbsp;highlighting</span></div></li> <li><div class="src-line"><a name="a1436"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1437"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">&nbsp;&nbsp;&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;keyword&nbsp;group&nbsp;to&nbsp;add&nbsp;the&nbsp;keyword&nbsp;to</span></div></li> <li><div class="src-line"><a name="a1438"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;word&nbsp;to&nbsp;add&nbsp;to&nbsp;the&nbsp;keyword&nbsp;group</span></div></li> <li><div class="src-line"><a name="a1439"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1440"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1441"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodadd_keyword">add_keyword</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$word</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1442"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><a href="http://www.php.net/in_array">in_array</a><span class="src-sym">(</span><span class="src-var">$word</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1443"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$word</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1444"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1445"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//NEW&nbsp;in&nbsp;1.0.8&nbsp;don't&nbsp;recompile&nbsp;the&nbsp;whole&nbsp;optimized&nbsp;regexp,&nbsp;simply&nbsp;append&nbsp;it</span></span></div></li> <li><div class="src-line"><a name="a1446"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">parse_cache_built</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1447"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$subkey</span>&nbsp;=&nbsp;<a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'CACHED_KEYWORD_LISTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1448"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'CACHED_KEYWORD_LISTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$subkey</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-str">'|'</span>&nbsp;.&nbsp;<a href="http://www.php.net/preg_quote">preg_quote</a><span class="src-sym">(</span><span class="src-var">$word</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'/'</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1449"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1450"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1451"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1452"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1453"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1454"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Removes&nbsp;a&nbsp;keyword&nbsp;from&nbsp;a&nbsp;keyword&nbsp;group</span></div></li> <li><div class="src-line"><a name="a1455"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1456"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">&nbsp;&nbsp;&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;keyword&nbsp;group&nbsp;to&nbsp;remove&nbsp;the&nbsp;keyword&nbsp;from</span></div></li> <li><div class="src-line"><a name="a1457"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;word&nbsp;to&nbsp;remove&nbsp;from&nbsp;the&nbsp;keyword&nbsp;group</span></div></li> <li><div class="src-line"><a name="a1458"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">bool&nbsp;</span><span class="src-doc">&nbsp;&nbsp;Wether&nbsp;to&nbsp;automatically&nbsp;recompile&nbsp;the&nbsp;optimized&nbsp;regexp&nbsp;list&nbsp;or&nbsp;not.</span></div></li> <li><div class="src-line"><a name="a1459"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Note:&nbsp;if&nbsp;you&nbsp;set&nbsp;this&nbsp;to&nbsp;false&nbsp;and&nbsp;@see&nbsp;GeSHi-&gt;parse_code()&nbsp;was&nbsp;already&nbsp;called&nbsp;once,</span></div></li> <li><div class="src-line"><a name="a1460"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for&nbsp;the&nbsp;current&nbsp;language,&nbsp;you&nbsp;have&nbsp;to&nbsp;manually&nbsp;call&nbsp;@see&nbsp;GeSHi-&gt;optimize_keyword_group()</span></div></li> <li><div class="src-line"><a name="a1461"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;or&nbsp;the&nbsp;removed&nbsp;keyword&nbsp;will&nbsp;stay&nbsp;in&nbsp;cache&nbsp;and&nbsp;still&nbsp;be&nbsp;highlighted!&nbsp;On&nbsp;the&nbsp;other&nbsp;hand</span></div></li> <li><div class="src-line"><a name="a1462"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;it&nbsp;might&nbsp;be&nbsp;too&nbsp;expensive&nbsp;to&nbsp;recompile&nbsp;the&nbsp;regexp&nbsp;list&nbsp;for&nbsp;every&nbsp;removal&nbsp;if&nbsp;you&nbsp;want&nbsp;to</span></div></li> <li><div class="src-line"><a name="a1463"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;remove&nbsp;a&nbsp;lot&nbsp;of&nbsp;keywords.</span></div></li> <li><div class="src-line"><a name="a1464"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1465"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1466"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodremove_keyword">remove_keyword</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$word</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$recompile</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1467"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$key_to_remove</span>&nbsp;=&nbsp;<a href="http://www.php.net/array_search">array_search</a><span class="src-sym">(</span><span class="src-var">$word</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1468"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$key_to_remove</span>&nbsp;!==&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1469"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key_to_remove</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1470"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1471"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//NEW&nbsp;in&nbsp;1.0.8,&nbsp;optionally&nbsp;recompile&nbsp;keyword&nbsp;group</span></span></div></li> <li><div class="src-line"><a name="a1472"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$recompile</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">parse_cache_built</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1473"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodoptimize_keyword_group">optimize_keyword_group</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1474"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1475"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1476"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1477"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1478"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1479"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Creates&nbsp;a&nbsp;new&nbsp;keyword&nbsp;group</span></div></li> <li><div class="src-line"><a name="a1480"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1481"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">&nbsp;&nbsp;&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;keyword&nbsp;group&nbsp;to&nbsp;create</span></div></li> <li><div class="src-line"><a name="a1482"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;styles&nbsp;for&nbsp;the&nbsp;keyword&nbsp;group</span></div></li> <li><div class="src-line"><a name="a1483"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Whether&nbsp;the&nbsp;keyword&nbsp;group&nbsp;is&nbsp;case&nbsp;sensitive&nbsp;ornot</span></div></li> <li><div class="src-line"><a name="a1484"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">array&nbsp;</span><span class="src-doc">&nbsp;The&nbsp;words&nbsp;to&nbsp;use&nbsp;for&nbsp;the&nbsp;keyword&nbsp;group</span></div></li> <li><div class="src-line"><a name="a1485"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1486"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1487"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodadd_keyword_group">add_keyword_group</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$styles</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$case_sensitive</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$words</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1488"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$words</span>&nbsp;=&nbsp;(array)&nbsp;<span class="src-var">$words</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1489"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$words</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1490"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;empty&nbsp;word&nbsp;lists&nbsp;mess&nbsp;up&nbsp;highlighting</span></span></div></li> <li><div class="src-line"><a name="a1491"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1492"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1493"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1494"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Add&nbsp;the&nbsp;new&nbsp;keyword&nbsp;group&nbsp;internally</span></span></div></li> <li><div class="src-line"><a name="a1495"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$words</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1496"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1497"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'CASE_SENSITIVE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$case_sensitive</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1498"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$styles</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1499"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1500"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//NEW&nbsp;in&nbsp;1.0.8,&nbsp;cache&nbsp;keyword&nbsp;regexp</span></span></div></li> <li><div class="src-line"><a name="a1501"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">parse_cache_built</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1502"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodoptimize_keyword_group">optimize_keyword_group</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1503"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1504"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1505"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1506"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1507"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Removes&nbsp;a&nbsp;keyword&nbsp;group</span></div></li> <li><div class="src-line"><a name="a1508"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1509"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">&nbsp;&nbsp;&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;keyword&nbsp;group&nbsp;to&nbsp;remove</span></div></li> <li><div class="src-line"><a name="a1510"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1511"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1512"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodremove_keyword_group">remove_keyword_group</a>&nbsp;<span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1513"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Remove&nbsp;the&nbsp;keyword&nbsp;group&nbsp;internally</span></span></div></li> <li><div class="src-line"><a name="a1514"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1515"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1516"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'CASE_SENSITIVE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1517"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1518"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1519"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//NEW&nbsp;in&nbsp;1.0.8</span></span></div></li> <li><div class="src-line"><a name="a1520"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'CACHED_KEYWORD_LISTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1521"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1522"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1523"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1524"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;compile&nbsp;optimized&nbsp;regexp&nbsp;list&nbsp;for&nbsp;keyword&nbsp;group</span></div></li> <li><div class="src-line"><a name="a1525"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1526"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">&nbsp;&nbsp;The&nbsp;key&nbsp;of&nbsp;the&nbsp;keyword&nbsp;group&nbsp;to&nbsp;compile&nbsp;&amp;&nbsp;optimize</span></div></li> <li><div class="src-line"><a name="a1527"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.8</span></div></li> <li><div class="src-line"><a name="a1528"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1529"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodoptimize_keyword_group">optimize_keyword_group</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1530"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'CACHED_KEYWORD_LISTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=</span></div></li> <li><div class="src-line"><a name="a1531"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">optimize_regexp_list</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1532"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1533"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1534"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1535"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;content&nbsp;of&nbsp;the&nbsp;header&nbsp;block</span></div></li> <li><div class="src-line"><a name="a1536"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1537"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;content&nbsp;of&nbsp;the&nbsp;header&nbsp;block</span></div></li> <li><div class="src-line"><a name="a1538"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1539"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1540"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_header_content">set_header_content</a><span class="src-sym">(</span><span class="src-var">$content</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1541"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">header_content</span>&nbsp;=&nbsp;<span class="src-var">$content</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1542"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1543"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1544"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1545"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;content&nbsp;of&nbsp;the&nbsp;footer&nbsp;block</span></div></li> <li><div class="src-line"><a name="a1546"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1547"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;content&nbsp;of&nbsp;the&nbsp;footer&nbsp;block</span></div></li> <li><div class="src-line"><a name="a1548"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1549"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1550"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_footer_content">set_footer_content</a><span class="src-sym">(</span><span class="src-var">$content</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1551"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">footer_content</span>&nbsp;=&nbsp;<span class="src-var">$content</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1552"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1553"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1554"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1555"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;style&nbsp;for&nbsp;the&nbsp;header&nbsp;content</span></div></li> <li><div class="src-line"><a name="a1556"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1557"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;style&nbsp;for&nbsp;the&nbsp;header&nbsp;content</span></div></li> <li><div class="src-line"><a name="a1558"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1559"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1560"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_header_content_style">set_header_content_style</a><span class="src-sym">(</span><span class="src-var">$style</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1561"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">header_content_style</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1562"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1563"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1564"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1565"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;style&nbsp;for&nbsp;the&nbsp;footer&nbsp;content</span></div></li> <li><div class="src-line"><a name="a1566"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1567"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;style&nbsp;for&nbsp;the&nbsp;footer&nbsp;content</span></div></li> <li><div class="src-line"><a name="a1568"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1569"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1570"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_footer_content_style">set_footer_content_style</a><span class="src-sym">(</span><span class="src-var">$style</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1571"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">footer_content_style</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1572"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1573"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1574"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1575"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;whether&nbsp;to&nbsp;force&nbsp;a&nbsp;surrounding&nbsp;block&nbsp;around</span></div></li> <li><div class="src-line"><a name="a1576"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;the&nbsp;highlighted&nbsp;code&nbsp;or&nbsp;not</span></div></li> <li><div class="src-line"><a name="a1577"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1578"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Tells&nbsp;whether&nbsp;to&nbsp;enable&nbsp;or&nbsp;disable&nbsp;this&nbsp;feature</span></div></li> <li><div class="src-line"><a name="a1579"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.7.20</span></div></li> <li><div class="src-line"><a name="a1580"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1581"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodenable_inner_code_block">enable_inner_code_block</a><span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1582"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">force_code_block</span>&nbsp;=&nbsp;(bool)<span class="src-var">$flag</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1583"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1584"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1585"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1586"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;base&nbsp;URL&nbsp;to&nbsp;be&nbsp;used&nbsp;for&nbsp;keywords</span></div></li> <li><div class="src-line"><a name="a1587"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1588"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">The&nbsp;key&nbsp;of&nbsp;the&nbsp;keyword&nbsp;group&nbsp;to&nbsp;set&nbsp;the&nbsp;URL&nbsp;for</span></div></li> <li><div class="src-line"><a name="a1589"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;URL&nbsp;to&nbsp;set&nbsp;for&nbsp;the&nbsp;group.&nbsp;If&nbsp;{FNAME}&nbsp;is&nbsp;in</span></div></li> <li><div class="src-line"><a name="a1590"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;the&nbsp;url&nbsp;somewhere,&nbsp;it&nbsp;is&nbsp;replaced&nbsp;by&nbsp;the&nbsp;keyword</span></div></li> <li><div class="src-line"><a name="a1591"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;that&nbsp;the&nbsp;URL&nbsp;is&nbsp;being&nbsp;made&nbsp;for</span></div></li> <li><div class="src-line"><a name="a1592"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1593"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1594"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_url_for_keyword_group">set_url_for_keyword_group</a><span class="src-sym">(</span><span class="src-var">$group</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$url</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1595"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'URLS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$url</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1596"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1597"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1598"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1599"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;styles&nbsp;for&nbsp;links&nbsp;in&nbsp;code</span></div></li> <li><div class="src-line"><a name="a1600"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1601"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">A&nbsp;constant&nbsp;that&nbsp;specifies&nbsp;what&nbsp;state&nbsp;the&nbsp;style&nbsp;is&nbsp;being</span></div></li> <li><div class="src-line"><a name="a1602"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;set&nbsp;for&nbsp;-&nbsp;e.g.&nbsp;:hover&nbsp;or&nbsp;:visited</span></div></li> <li><div class="src-line"><a name="a1603"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;styles&nbsp;to&nbsp;use&nbsp;for&nbsp;that&nbsp;state</span></div></li> <li><div class="src-line"><a name="a1604"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1605"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1606"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_link_styles">set_link_styles</a><span class="src-sym">(</span><span class="src-var">$type</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$styles</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1607"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">link_styles</span><span class="src-sym">[</span><span class="src-var">$type</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$styles</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1608"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1609"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1610"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1611"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;target&nbsp;for&nbsp;links&nbsp;in&nbsp;code</span></div></li> <li><div class="src-line"><a name="a1612"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1613"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;target&nbsp;for&nbsp;links&nbsp;in&nbsp;the&nbsp;code,&nbsp;e.g.&nbsp;_blank</span></div></li> <li><div class="src-line"><a name="a1614"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.3</span></div></li> <li><div class="src-line"><a name="a1615"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1616"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_link_target">set_link_target</a><span class="src-sym">(</span><span class="src-var">$target</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1617"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$target</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1618"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">link_target</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1619"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1620"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">link_target</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;target=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$target</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&nbsp;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1621"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1622"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1623"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1624"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1625"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;styles&nbsp;for&nbsp;important&nbsp;parts&nbsp;of&nbsp;the&nbsp;code</span></div></li> <li><div class="src-line"><a name="a1626"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1627"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;styles&nbsp;to&nbsp;use&nbsp;on&nbsp;important&nbsp;parts&nbsp;of&nbsp;the&nbsp;code</span></div></li> <li><div class="src-line"><a name="a1628"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1629"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1630"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_important_styles">set_important_styles</a><span class="src-sym">(</span><span class="src-var">$styles</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1631"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">important_styles</span>&nbsp;=&nbsp;<span class="src-var">$styles</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1632"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1633"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1634"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1635"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;whether&nbsp;context-important&nbsp;blocks&nbsp;are&nbsp;highlighted</span></div></li> <li><div class="src-line"><a name="a1636"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1637"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">Tells&nbsp;whether&nbsp;to&nbsp;enable&nbsp;or&nbsp;disable&nbsp;highlighting&nbsp;of&nbsp;important&nbsp;blocks</span></div></li> <li><div class="src-line"><a name="a1638"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@todo</span><span class="src-doc">&nbsp;REMOVE&nbsp;THIS&nbsp;SHIZ&nbsp;FROM&nbsp;GESHI!</span></div></li> <li><div class="src-line"><a name="a1639"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@deprecated</span></div></li> <li><div class="src-line"><a name="a1640"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1641"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1642"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodenable_important_blocks">enable_important_blocks</a><span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1643"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">enable_important_blocks</span>&nbsp;=&nbsp;<span class="src-sym">(</span>&nbsp;<span class="src-var">$flag</span>&nbsp;<span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1644"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1645"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1646"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1647"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Whether&nbsp;CSS&nbsp;IDs&nbsp;should&nbsp;be&nbsp;added&nbsp;to&nbsp;each&nbsp;line</span></div></li> <li><div class="src-line"><a name="a1648"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1649"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">If&nbsp;true,&nbsp;IDs&nbsp;will&nbsp;be&nbsp;added&nbsp;to&nbsp;each&nbsp;line.</span></div></li> <li><div class="src-line"><a name="a1650"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1651"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1652"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodenable_ids">enable_ids</a><span class="src-sym">(</span><span class="src-var">$flag</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1653"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">add_ids</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-id">true</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1654"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1655"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1656"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1657"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Specifies&nbsp;which&nbsp;lines&nbsp;to&nbsp;highlight&nbsp;extra</span></div></li> <li><div class="src-line"><a name="a1658"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1659"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;extra&nbsp;style&nbsp;parameter&nbsp;was&nbsp;added&nbsp;in&nbsp;1.0.7.21.</span></div></li> <li><div class="src-line"><a name="a1660"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1661"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">mixed&nbsp;</span><span class="src-doc">An&nbsp;array&nbsp;of&nbsp;line&nbsp;numbers&nbsp;to&nbsp;highlight,&nbsp;or&nbsp;just&nbsp;a&nbsp;line</span></div></li> <li><div class="src-line"><a name="a1662"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;number&nbsp;on&nbsp;its&nbsp;own.</span></div></li> <li><div class="src-line"><a name="a1663"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">A&nbsp;string&nbsp;specifying&nbsp;the&nbsp;style&nbsp;to&nbsp;use&nbsp;for&nbsp;this&nbsp;line.</span></div></li> <li><div class="src-line"><a name="a1664"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;If&nbsp;null&nbsp;is&nbsp;specified,&nbsp;the&nbsp;default&nbsp;style&nbsp;is&nbsp;used.</span></div></li> <li><div class="src-line"><a name="a1665"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;If&nbsp;false&nbsp;is&nbsp;specified,&nbsp;the&nbsp;line&nbsp;will&nbsp;be&nbsp;removed&nbsp;from</span></div></li> <li><div class="src-line"><a name="a1666"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;special&nbsp;highlighting</span></div></li> <li><div class="src-line"><a name="a1667"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1668"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@todo</span><span class="src-doc">&nbsp;&nbsp;Some&nbsp;data&nbsp;replication&nbsp;here&nbsp;that&nbsp;could&nbsp;be&nbsp;cut&nbsp;down&nbsp;on</span></div></li> <li><div class="src-line"><a name="a1669"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1670"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodhighlight_lines_extra">highlight_lines_extra</a><span class="src-sym">(</span><span class="src-var">$lines</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$style</span>&nbsp;=&nbsp;<span class="src-id">null</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1671"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$lines</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1672"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Split&nbsp;up&nbsp;the&nbsp;job&nbsp;using&nbsp;single&nbsp;lines&nbsp;at&nbsp;a&nbsp;time</span></span></div></li> <li><div class="src-line"><a name="a1673"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$lines</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$line</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1674"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodhighlight_lines_extra">highlight_lines_extra</a><span class="src-sym">(</span><span class="src-var">$line</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$style</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1675"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1676"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1677"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Mark&nbsp;the&nbsp;line&nbsp;as&nbsp;being&nbsp;highlighted&nbsp;specially</span></span></div></li> <li><div class="src-line"><a name="a1678"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$lines</span>&nbsp;=&nbsp;<a href="http://www.php.net/intval">intval</a><span class="src-sym">(</span><span class="src-var">$lines</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1679"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">highlight_extra_lines</span><span class="src-sym">[</span><span class="src-var">$lines</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$lines</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1680"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1681"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Decide&nbsp;on&nbsp;which&nbsp;style&nbsp;to&nbsp;use</span></span></div></li> <li><div class="src-line"><a name="a1682"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$style</span>&nbsp;===&nbsp;<span class="src-id">null</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span>&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;we&nbsp;should&nbsp;use&nbsp;default&nbsp;style</span></span></div></li> <li><div class="src-line"><a name="a1683"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">highlight_extra_lines_styles</span><span class="src-sym">[</span><span class="src-var">$lines</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1684"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$style</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span>&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;to&nbsp;remove&nbsp;this&nbsp;line</span></span></div></li> <li><div class="src-line"><a name="a1685"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">highlight_extra_lines</span><span class="src-sym">[</span><span class="src-var">$lines</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1686"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">highlight_extra_lines_styles</span><span class="src-sym">[</span><span class="src-var">$lines</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1687"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1688"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">highlight_extra_lines_styles</span><span class="src-sym">[</span><span class="src-var">$lines</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$style</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1689"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1690"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1691"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1692"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1693"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1694"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;style&nbsp;for&nbsp;extra-highlighted&nbsp;lines</span></div></li> <li><div class="src-line"><a name="a1695"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1696"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;style&nbsp;for&nbsp;extra-highlighted&nbsp;lines</span></div></li> <li><div class="src-line"><a name="a1697"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1698"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1699"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_highlight_lines_extra_style">set_highlight_lines_extra_style</a><span class="src-sym">(</span><span class="src-var">$styles</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1700"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">highlight_extra_lines_style</span>&nbsp;=&nbsp;<span class="src-var">$styles</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1701"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1702"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1703"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1704"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;line-ending</span></div></li> <li><div class="src-line"><a name="a1705"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1706"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;new&nbsp;line-ending</span></div></li> <li><div class="src-line"><a name="a1707"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1708"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1709"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_line_ending">set_line_ending</a><span class="src-sym">(</span><span class="src-var">$line_ending</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1710"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">line_ending</span>&nbsp;=&nbsp;(string)<span class="src-var">$line_ending</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1711"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1712"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1713"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1714"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;what&nbsp;number&nbsp;line&nbsp;numbers&nbsp;should&nbsp;start&nbsp;at.&nbsp;Should</span></div></li> <li><div class="src-line"><a name="a1715"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;be&nbsp;a&nbsp;positive&nbsp;integer,&nbsp;and&nbsp;will&nbsp;be&nbsp;converted&nbsp;to&nbsp;one.</span></div></li> <li><div class="src-line"><a name="a1716"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1717"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&lt;b&gt;Warning:&lt;/b&gt;&nbsp;Using&nbsp;this&nbsp;method&nbsp;will&nbsp;add&nbsp;the&nbsp;&quot;start&quot;</span></div></li> <li><div class="src-line"><a name="a1718"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;attribute&nbsp;to&nbsp;the&nbsp;&amp;lt;ol&amp;gt;&nbsp;that&nbsp;is&nbsp;used&nbsp;for&nbsp;line&nbsp;numbering.</span></div></li> <li><div class="src-line"><a name="a1719"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;This&nbsp;is&nbsp;&lt;b&gt;not&lt;/b&gt;&nbsp;valid&nbsp;XHTML&nbsp;strict,&nbsp;so&nbsp;if&nbsp;that's&nbsp;what&nbsp;you</span></div></li> <li><div class="src-line"><a name="a1720"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;care&nbsp;about&nbsp;then&nbsp;don't&nbsp;use&nbsp;this&nbsp;method.&nbsp;Firefox&nbsp;is&nbsp;getting</span></div></li> <li><div class="src-line"><a name="a1721"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;support&nbsp;for&nbsp;the&nbsp;CSS&nbsp;method&nbsp;of&nbsp;doing&nbsp;this&nbsp;in&nbsp;1.1&nbsp;and&nbsp;Opera</span></div></li> <li><div class="src-line"><a name="a1722"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;has&nbsp;support&nbsp;for&nbsp;the&nbsp;CSS&nbsp;method,&nbsp;but&nbsp;(of&nbsp;course)&nbsp;IE&nbsp;doesn't</span></div></li> <li><div class="src-line"><a name="a1723"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;so&nbsp;it's&nbsp;not&nbsp;worth&nbsp;doing&nbsp;it&nbsp;the&nbsp;CSS&nbsp;way&nbsp;yet.</span></div></li> <li><div class="src-line"><a name="a1724"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1725"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">int&nbsp;</span><span class="src-doc">The&nbsp;number&nbsp;to&nbsp;start&nbsp;line&nbsp;numbers&nbsp;at</span></div></li> <li><div class="src-line"><a name="a1726"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1727"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1728"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodstart_line_numbers_at">start_line_numbers_at</a><span class="src-sym">(</span><span class="src-var">$number</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1729"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">line_numbers_start</span>&nbsp;=&nbsp;<a href="http://www.php.net/abs">abs</a><span class="src-sym">(</span><a href="http://www.php.net/intval">intval</a><span class="src-sym">(</span><span class="src-var">$number</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1730"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1731"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1732"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1733"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;encoding&nbsp;used&nbsp;for&nbsp;htmlspecialchars(),&nbsp;for&nbsp;international</span></div></li> <li><div class="src-line"><a name="a1734"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;support.</span></div></li> <li><div class="src-line"><a name="a1735"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1736"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;NOTE:&nbsp;This&nbsp;is&nbsp;not&nbsp;needed&nbsp;for&nbsp;now&nbsp;because&nbsp;htmlspecialchars()&nbsp;is&nbsp;not</span></div></li> <li><div class="src-line"><a name="a1737"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;being&nbsp;used&nbsp;(it&nbsp;has&nbsp;a&nbsp;security&nbsp;hole&nbsp;in&nbsp;PHP4&nbsp;that&nbsp;has&nbsp;not&nbsp;been&nbsp;patched).</span></div></li> <li><div class="src-line"><a name="a1738"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Maybe&nbsp;in&nbsp;a&nbsp;future&nbsp;version&nbsp;it&nbsp;may&nbsp;make&nbsp;a&nbsp;return&nbsp;for&nbsp;speed&nbsp;reasons,&nbsp;but</span></div></li> <li><div class="src-line"><a name="a1739"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;I&nbsp;doubt&nbsp;it.</span></div></li> <li><div class="src-line"><a name="a1740"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1741"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;encoding&nbsp;to&nbsp;use&nbsp;for&nbsp;the&nbsp;source</span></div></li> <li><div class="src-line"><a name="a1742"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.3</span></div></li> <li><div class="src-line"><a name="a1743"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1744"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodset_encoding">set_encoding</a><span class="src-sym">(</span><span class="src-var">$encoding</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1745"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$encoding</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1746"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">encoding</span>&nbsp;=&nbsp;<a href="http://www.php.net/strtolower">strtolower</a><span class="src-sym">(</span><span class="src-var">$encoding</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1747"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1748"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1749"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1750"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1751"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Turns&nbsp;linking&nbsp;of&nbsp;keywords&nbsp;on&nbsp;or&nbsp;off.</span></div></li> <li><div class="src-line"><a name="a1752"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1753"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">boolean&nbsp;</span><span class="src-doc">If&nbsp;true,&nbsp;links&nbsp;will&nbsp;be&nbsp;added&nbsp;to&nbsp;keywords</span></div></li> <li><div class="src-line"><a name="a1754"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a1755"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1756"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodenable_keyword_links">enable_keyword_links</a><span class="src-sym">(</span><span class="src-var">$enable</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1757"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">keyword_links</span>&nbsp;=&nbsp;(bool)&nbsp;<span class="src-var">$enable</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1758"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1759"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1760"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1761"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Setup&nbsp;caches&nbsp;needed&nbsp;for&nbsp;styling.&nbsp;This&nbsp;is&nbsp;automatically&nbsp;called&nbsp;in</span></div></li> <li><div class="src-line"><a name="a1762"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;parse_code()&nbsp;and&nbsp;get_stylesheet()&nbsp;when&nbsp;appropriate.&nbsp;This&nbsp;function&nbsp;helps</span></div></li> <li><div class="src-line"><a name="a1763"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;stylesheet&nbsp;generators&nbsp;as&nbsp;they&nbsp;rely&nbsp;on&nbsp;some&nbsp;style&nbsp;information&nbsp;being</span></div></li> <li><div class="src-line"><a name="a1764"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;preprocessed</span></div></li> <li><div class="src-line"><a name="a1765"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1766"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.8</span></div></li> <li><div class="src-line"><a name="a1767"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@access</span><span class="src-doc">&nbsp;private</span></div></li> <li><div class="src-line"><a name="a1768"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1769"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">build_style_cache</span><span class="src-sym">(</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1770"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Build&nbsp;the&nbsp;style&nbsp;cache&nbsp;needed&nbsp;to&nbsp;highlight&nbsp;numbers&nbsp;appropriate</span></span></div></li> <li><div class="src-line"><a name="a1771"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1772"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//First&nbsp;check&nbsp;what&nbsp;way&nbsp;highlighting&nbsp;information&nbsp;for&nbsp;numbers&nbsp;are&nbsp;given</span></span></div></li> <li><div class="src-line"><a name="a1773"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1774"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1775"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1776"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1777"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1778"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_CACHE'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1779"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1780"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_CACHE'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1781"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1782"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span>&nbsp;=</span></div></li> <li><div class="src-line"><a name="a1783"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_INT_BASIC</span>&nbsp;|</span></div></li> <li><div class="src-line"><a name="a1784"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_FLT_NONSCI</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1785"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1786"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1787"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span><span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$j</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$j</span>&nbsp;>&nbsp;<span class="src-num">0</span><span class="src-sym">;</span>&nbsp;++<span class="src-var">$i</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$j</span>&gt;&gt;=<span class="src-num">1</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1788"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Rearrange&nbsp;style&nbsp;indices&nbsp;if&nbsp;required&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a1789"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span>&lt;&lt;<span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1790"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span>&nbsp;=</span></div></li> <li><div class="src-line"><a name="a1791"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span>&lt;&lt;<span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1792"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span>&lt;&lt;<span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1793"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1794"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1795"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;this&nbsp;bit&nbsp;is&nbsp;set&nbsp;for&nbsp;highlighting</span></span></div></li> <li><div class="src-line"><a name="a1796"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-var">$j</span><span class="src-sym">&</span><span class="src-num">1</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1797"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//So&nbsp;this&nbsp;bit&nbsp;is&nbsp;set&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a1798"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;it&nbsp;belongs&nbsp;to&nbsp;group&nbsp;0&nbsp;or&nbsp;the&nbsp;actual&nbsp;stylegroup</span></span></div></li> <li><div class="src-line"><a name="a1799"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1800"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_CACHE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-num">1</span>&nbsp;&lt;&lt;&nbsp;<span class="src-var">$i</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1801"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1802"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_CACHE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1803"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_CACHE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1804"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1805"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_CACHE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;|=&nbsp;<span class="src-num">1</span>&nbsp;&lt;&lt;&nbsp;<span class="src-var">$i</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1806"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1807"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1808"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1809"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1810"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1811"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1812"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1813"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a1814"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Setup&nbsp;caches&nbsp;needed&nbsp;for&nbsp;parsing.&nbsp;This&nbsp;is&nbsp;automatically&nbsp;called&nbsp;in&nbsp;parse_code()&nbsp;when&nbsp;appropriate.</span></div></li> <li><div class="src-line"><a name="a1815"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;This&nbsp;function&nbsp;makes&nbsp;stylesheet&nbsp;generators&nbsp;much&nbsp;faster&nbsp;as&nbsp;they&nbsp;do&nbsp;not&nbsp;need&nbsp;these&nbsp;caches.</span></div></li> <li><div class="src-line"><a name="a1816"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1817"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.8</span></div></li> <li><div class="src-line"><a name="a1818"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@access</span><span class="src-doc">&nbsp;private</span></div></li> <li><div class="src-line"><a name="a1819"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a1820"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">build_parse_cache</span><span class="src-sym">(</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1821"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;cache&nbsp;symbol&nbsp;regexp</span></span></div></li> <li><div class="src-line"><a name="a1822"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//As&nbsp;this&nbsp;is&nbsp;a&nbsp;costy&nbsp;operation,&nbsp;we&nbsp;avoid&nbsp;doing&nbsp;it&nbsp;for&nbsp;multiple&nbsp;groups&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a1823"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Instead&nbsp;we&nbsp;perform&nbsp;it&nbsp;for&nbsp;all&nbsp;symbols&nbsp;at&nbsp;once.</span></span></div></li> <li><div class="src-line"><a name="a1824"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//</span></span></div></li> <li><div class="src-line"><a name="a1825"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//For&nbsp;this&nbsp;to&nbsp;work,&nbsp;we&nbsp;need&nbsp;to&nbsp;reorganize&nbsp;the&nbsp;data&nbsp;arrays.</span></span></div></li> <li><div class="src-line"><a name="a1826"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]</span>&nbsp;&amp;&amp;&nbsp;<span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1827"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'MULTIPLE_SYMBOL_GROUPS'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;>&nbsp;<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1828"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1829"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOL_DATA'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1830"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_preg_multi</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span>&nbsp;<span class="src-comm">//&nbsp;multi&nbsp;char&nbsp;symbols</span></span></div></li> <li><div class="src-line"><a name="a1831"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_preg_single</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span>&nbsp;<span class="src-comm">//&nbsp;single&nbsp;char&nbsp;symbols</span></span></div></li> <li><div class="src-line"><a name="a1832"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span>&nbsp;=&gt;&nbsp;<span class="src-var">$symbols</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1833"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$symbols</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1834"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$symbols</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$sym</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1835"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$sym</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$sym</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1836"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOL_DATA'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$sym</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1837"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOL_DATA'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$sym</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$key</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1838"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$sym</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span>&nbsp;<span class="src-comm">//&nbsp;multiple&nbsp;chars</span></span></div></li> <li><div class="src-line"><a name="a1839"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_preg_multi</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_quote">preg_quote</a><span class="src-sym">(</span><span class="src-var">$sym</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'/'</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1840"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span>&nbsp;<span class="src-comm">//&nbsp;single&nbsp;char</span></span></div></li> <li><div class="src-line"><a name="a1841"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$sym</span>&nbsp;==&nbsp;<span class="src-str">'-'</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1842"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;don't&nbsp;trigger&nbsp;range&nbsp;out&nbsp;of&nbsp;order&nbsp;error</span></span></div></li> <li><div class="src-line"><a name="a1843"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_preg_single</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'\-'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1844"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1845"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_preg_single</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_quote">preg_quote</a><span class="src-sym">(</span><span class="src-var">$sym</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'/'</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1846"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1847"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1848"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1849"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1850"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1851"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbols</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$symbols</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1852"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOL_DATA'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$symbols</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1853"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOL_DATA'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$symbols</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1854"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$symbols</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span>&nbsp;<span class="src-comm">//&nbsp;multiple&nbsp;chars</span></span></div></li> <li><div class="src-line"><a name="a1855"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_preg_multi</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_quote">preg_quote</a><span class="src-sym">(</span><span class="src-var">$symbols</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'/'</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1856"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$symbols</span>&nbsp;==&nbsp;<span class="src-str">'-'</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1857"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;don't&nbsp;trigger&nbsp;range&nbsp;out&nbsp;of&nbsp;order&nbsp;error</span></span></div></li> <li><div class="src-line"><a name="a1858"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_preg_single</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'\-'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1859"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span>&nbsp;<span class="src-comm">//&nbsp;single&nbsp;char</span></span></div></li> <li><div class="src-line"><a name="a1860"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_preg_single</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_quote">preg_quote</a><span class="src-sym">(</span><span class="src-var">$symbols</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'/'</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1861"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1862"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1863"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1864"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1865"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1866"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Now&nbsp;we&nbsp;have&nbsp;an&nbsp;array&nbsp;with&nbsp;each&nbsp;possible&nbsp;symbol&nbsp;as&nbsp;the&nbsp;key&nbsp;and&nbsp;the&nbsp;style&nbsp;as&nbsp;the&nbsp;actual&nbsp;data.</span></span></div></li> <li><div class="src-line"><a name="a1867"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//This&nbsp;way&nbsp;we&nbsp;can&nbsp;set&nbsp;the&nbsp;correct&nbsp;style&nbsp;just&nbsp;the&nbsp;moment&nbsp;we&nbsp;highlight&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a1868"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//</span></span></div></li> <li><div class="src-line"><a name="a1869"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Now&nbsp;we&nbsp;need&nbsp;to&nbsp;rewrite&nbsp;our&nbsp;array&nbsp;to&nbsp;get&nbsp;a&nbsp;search&nbsp;string&nbsp;that</span></span></div></li> <li><div class="src-line"><a name="a1870"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_preg</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1871"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$symbol_preg_multi</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1872"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/rsort">rsort</a><span class="src-sym">(</span><span class="src-var">$symbol_preg_multi</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1873"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_preg</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<a href="http://www.php.net/implode">implode</a><span class="src-sym">(</span><span class="src-str">'|'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$symbol_preg_multi</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1874"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1875"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$symbol_preg_single</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1876"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/rsort">rsort</a><span class="src-sym">(</span><span class="src-var">$symbol_preg_single</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1877"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_preg</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'['</span>&nbsp;.&nbsp;<a href="http://www.php.net/implode">implode</a><span class="src-sym">(</span><span class="src-str">''</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$symbol_preg_single</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">']'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1878"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1879"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOL_SEARCH'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<a href="http://www.php.net/implode">implode</a><span class="src-sym">(</span><span class="src-str">&quot;|&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$symbol_preg</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1880"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1881"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1882"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;cache&nbsp;optimized&nbsp;regexp&nbsp;for&nbsp;keyword&nbsp;matching</span></span></div></li> <li><div class="src-line"><a name="a1883"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;remove&nbsp;old&nbsp;cache</span></span></div></li> <li><div class="src-line"><a name="a1884"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'CACHED_KEYWORD_LISTS'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1885"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/array_keys">array_keys</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1886"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a1887"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1888"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodoptimize_keyword_group">optimize_keyword_group</a><span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1889"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1890"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1891"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1892"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;brackets</span></span></div></li> <li><div class="src-line"><a name="a1893"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1894"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'CACHE_BRACKET_MATCH'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'['</span><span class="src-sym">,</span>&nbsp;<span class="src-str">']'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'('</span><span class="src-sym">,</span>&nbsp;<span class="src-str">')'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'{'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'}'</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1895"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">use_classes</span>&nbsp;&amp;&amp;&nbsp;isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1896"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'CACHE_BRACKET_REPLACE'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a1897"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;|&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&gt;&amp;#91;|&gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1898"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;|&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&gt;&amp;#93;|&gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1899"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;|&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&gt;&amp;#40;|&gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1900"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;|&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&gt;&amp;#41;|&gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1901"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;|&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&gt;&amp;#123;|&gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1902"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;|&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&gt;&amp;#125;|&gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1903"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1904"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1905"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1906"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'CACHE_BRACKET_REPLACE'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a1907"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;|&nbsp;class=&quot;br0&quot;&gt;&amp;#91;|&gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1908"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;|&nbsp;class=&quot;br0&quot;&gt;&amp;#93;|&gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1909"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;|&nbsp;class=&quot;br0&quot;&gt;&amp;#40;|&gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1910"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;|&nbsp;class=&quot;br0&quot;&gt;&amp;#41;|&gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1911"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;|&nbsp;class=&quot;br0&quot;&gt;&amp;#123;|&gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1912"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;|&nbsp;class=&quot;br0&quot;&gt;&amp;#125;|&gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1913"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1914"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1915"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1916"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1917"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Build&nbsp;the&nbsp;parse&nbsp;cache&nbsp;needed&nbsp;to&nbsp;highlight&nbsp;numbers&nbsp;appropriate</span></span></div></li> <li><div class="src-line"><a name="a1918"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1919"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;the&nbsp;style&nbsp;rearrangements&nbsp;have&nbsp;been&nbsp;processed&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a1920"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//This&nbsp;also&nbsp;does&nbsp;some&nbsp;preprocessing&nbsp;to&nbsp;check&nbsp;which&nbsp;style&nbsp;groups&nbsp;are&nbsp;useable&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a1921"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_CACHE'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1922"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">build_style_cache</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1923"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1924"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1925"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Number&nbsp;format&nbsp;specification</span></span></div></li> <li><div class="src-line"><a name="a1926"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//All&nbsp;this&nbsp;formats&nbsp;are&nbsp;matched&nbsp;case-insensitively!</span></span></div></li> <li><div class="src-line"><a name="a1927"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">static</span>&nbsp;<span class="src-var">$numbers_format</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a1928"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_INT_BASIC</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1929"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.%])(?&lt;![\d\.]e[+\-])([1-9]\d*?|0)(?![0-9a-z\.])'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1930"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_INT_CSTYLE</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1931"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.%])(?&lt;![\d\.]e[+\-])([1-9]\d*?|0)l(?![0-9a-z\.])'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1932"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_BIN_SUFFIX</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1933"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.])(?&lt;![\d\.]e[+\-])[01]+?b(?![0-9a-z\.])'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1934"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_BIN_PREFIX_PERCENT</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1935"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.%])(?&lt;![\d\.]e[+\-])%[01]+?(?![0-9a-z\.])'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1936"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_BIN_PREFIX_0B</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1937"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.%])(?&lt;![\d\.]e[+\-])0b[01]+?(?![0-9a-z\.])'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1938"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_OCT_PREFIX</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1939"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.])(?&lt;![\d\.]e[+\-])0[0-7]+?(?![0-9a-z\.])'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1940"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_OCT_SUFFIX</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1941"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.])(?&lt;![\d\.]e[+\-])[0-7]+?o(?![0-9a-z\.])'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1942"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_HEX_PREFIX</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1943"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.])(?&lt;![\d\.]e[+\-])0x[0-9a-f]+?(?![0-9a-z\.])'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1944"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_HEX_SUFFIX</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1945"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.])(?&lt;![\d\.]e[+\-])\d[0-9a-f]*?h(?![0-9a-z\.])'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1946"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_FLT_NONSCI</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1947"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.])(?&lt;![\d\.]e[+\-])\d+?\.\d+?(?![0-9a-z\.])'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1948"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_FLT_NONSCI_F</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1949"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.])(?&lt;![\d\.]e[+\-])(?:\d+?(?:\.\d*?)?|\.\d+?)f(?![0-9a-z\.])'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1950"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_FLT_SCI_SHORT</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1951"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.])(?&lt;![\d\.]e[+\-])\.\d+?(?:e[+\-]?\d+?)?(?![0-9a-z\.])'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a1952"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GESHI_NUMBER_FLT_SCI_ZERO</span>&nbsp;=&gt;</span></div></li> <li><div class="src-line"><a name="a1953"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'(?&lt;![0-9a-z_\.])(?&lt;![\d\.]e[+\-])(?:\d+?(?:\.\d*?)?|\.\d+?)(?:e[+\-]?\d+?)?(?![0-9a-z\.])'</span></span></div></li> <li><div class="src-line"><a name="a1954"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1955"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1956"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//At&nbsp;this&nbsp;step&nbsp;we&nbsp;have&nbsp;an&nbsp;associative&nbsp;array&nbsp;with&nbsp;flag&nbsp;groups&nbsp;for&nbsp;a</span></span></div></li> <li><div class="src-line"><a name="a1957"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//specific&nbsp;style&nbsp;or&nbsp;an&nbsp;string&nbsp;denoting&nbsp;a&nbsp;regexp&nbsp;given&nbsp;its&nbsp;index.</span></span></div></li> <li><div class="src-line"><a name="a1958"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_RXCACHE'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1959"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_CACHE'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span>&nbsp;=&gt;&nbsp;<span class="src-var">$rxdata</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1960"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-id">is_string</span><span class="src-sym">(</span><span class="src-var">$rxdata</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1961"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$regexp</span>&nbsp;=&nbsp;<span class="src-var">$rxdata</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1962"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1963"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//This&nbsp;is&nbsp;a&nbsp;bitfield&nbsp;of&nbsp;number&nbsp;flags&nbsp;to&nbsp;highlight:</span></span></div></li> <li><div class="src-line"><a name="a1964"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Build&nbsp;an&nbsp;array,&nbsp;implode&nbsp;them&nbsp;together&nbsp;and&nbsp;make&nbsp;this&nbsp;the&nbsp;actual&nbsp;RX</span></span></div></li> <li><div class="src-line"><a name="a1965"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$rxuse</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1966"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span><span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-num">1</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$i</span>&nbsp;&lt;=&nbsp;<span class="src-var">$rxdata</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$i</span>&lt;&lt;=<span class="src-num">1</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1967"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-var">$rxdata</span>&nbsp;<span class="src-sym">&</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1968"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$rxuse</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$numbers_format</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1969"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1970"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1971"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$regexp</span>&nbsp;=&nbsp;<a href="http://www.php.net/implode">implode</a><span class="src-sym">(</span><span class="src-str">&quot;|&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$rxuse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1972"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1973"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1974"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_RXCACHE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=</span></div></li> <li><div class="src-line"><a name="a1975"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">"</span></span>/(?&lt;!&lt;\|\/NUM!)(?&lt;!\d\/&gt;)(<span class="src-var">$regexp</span>)(?!\|&gt;)/i<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1976"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1977"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1978"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1979"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">parse_cache_built</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1980"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a1981"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1982"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a1983"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Returns&nbsp;the&nbsp;code&nbsp;in&nbsp;$this-&gt;source,&nbsp;highlighted&nbsp;and&nbsp;surrounded&nbsp;by&nbsp;the</span></div></li> <li><div class="src-line"><a name="a1984"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;nessecary&nbsp;HTML.</span></div></li> <li><div class="src-line"><a name="a1985"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1986"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;This&nbsp;should&nbsp;only&nbsp;be&nbsp;called&nbsp;ONCE,&nbsp;cos&nbsp;it's&nbsp;SLOW!&nbsp;If&nbsp;you&nbsp;want&nbsp;to&nbsp;highlight</span></div></li> <li><div class="src-line"><a name="a1987"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;the&nbsp;same&nbsp;source&nbsp;multiple&nbsp;times,&nbsp;you're&nbsp;better&nbsp;off&nbsp;doing&nbsp;a&nbsp;whole&nbsp;lot&nbsp;of</span></div></li> <li><div class="src-line"><a name="a1988"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;str_replaces&nbsp;to&nbsp;replace&nbsp;the&nbsp;&amp;lt;span&amp;gt;s</span></div></li> <li><div class="src-line"><a name="a1989"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a1990"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a1991"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a1992"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">parse_code</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1993"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Start&nbsp;the&nbsp;timer</span></span></div></li> <li><div class="src-line"><a name="a1994"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start_time</span>&nbsp;=&nbsp;<span class="src-id">microtime</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a1995"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a1996"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Firstly,&nbsp;if&nbsp;there&nbsp;is&nbsp;an&nbsp;error,&nbsp;we&nbsp;won't&nbsp;highlight</span></span></div></li> <li><div class="src-line"><a name="a1997"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">error</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a1998"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Escape&nbsp;the&nbsp;source&nbsp;for&nbsp;output</span></span></div></li> <li><div class="src-line"><a name="a1999"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-var">source</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2000"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2001"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//This&nbsp;fix&nbsp;is&nbsp;related&nbsp;to&nbsp;SF#1923020,&nbsp;but&nbsp;has&nbsp;to&nbsp;be&nbsp;applied&nbsp;regardless&nbsp;of</span></span></div></li> <li><div class="src-line"><a name="a2002"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//actually&nbsp;highlighting&nbsp;symbols.</span></span></div></li> <li><div class="src-line"><a name="a2003"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;=&nbsp;<span class="src-id">str_replace</span><span class="src-sym">(</span><span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'&lt;SEMI&gt;'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&lt;PIPE&gt;'</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">';'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'|'</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$result</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2004"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2005"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Timing&nbsp;is&nbsp;irrelevant</span></span></div></li> <li><div class="src-line"><a name="a2006"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">set_time</span><span class="src-sym">(</span><span class="src-var">$start_time</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start_time</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2007"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">finalise</span><span class="src-sym">(</span><span class="src-var">$result</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2008"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$result</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2009"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2010"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2011"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;make&nbsp;sure&nbsp;the&nbsp;parse&nbsp;cache&nbsp;is&nbsp;up2date</span></span></div></li> <li><div class="src-line"><a name="a2012"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">parse_cache_built</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2013"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">build_parse_cache</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2014"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2015"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2016"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Replace&nbsp;all&nbsp;newlines&nbsp;to&nbsp;a&nbsp;common&nbsp;form.</span></span></div></li> <li><div class="src-line"><a name="a2017"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$code</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">&quot;\r\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">source</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2018"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$code</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">&quot;\r&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$code</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2019"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2020"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Add&nbsp;spaces&nbsp;for&nbsp;regular&nbsp;expression&nbsp;matching&nbsp;and&nbsp;line&nbsp;numbers</span></span></div></li> <li><div class="src-line"><a name="a2021"></a></span><span class="src-str"><span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$code&nbsp;=&nbsp;&quot;\n&quot;&nbsp;.&nbsp;$code&nbsp;.&nbsp;&quot;\n&quot;;</span></span></div></li> <li><div class="src-line"><a name="a2022"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a2023"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Initialise&nbsp;various&nbsp;stuff</span></span></div></li> <li><div class="src-line"><a name="a2024"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$length</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2025"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$COMMENT_MATCHED</span>&nbsp;&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2026"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;&nbsp;&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2027"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$endresult</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2028"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2029"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;&quot;Important&quot;&nbsp;selections&nbsp;are&nbsp;handled&nbsp;like&nbsp;multiline&nbsp;comments</span></span></div></li> <li><div class="src-line"><a name="a2030"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;@todo&nbsp;GET&nbsp;RID&nbsp;OF&nbsp;THIS&nbsp;SHIZ</span></span></div></li> <li><div class="src-line"><a name="a2031"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodenable_important_blocks">enable_important_blocks</a><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2032"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'COMMENT_MULTI'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_START_IMPORTANT&quot;&gt;GESHI_START_IMPORTANT&lt;/a&gt;</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_END_IMPORTANT&quot;&gt;GESHI_END_IMPORTANT&lt;/a&gt;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2033"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2034"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2035"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">strict_mode</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2036"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Break&nbsp;the&nbsp;source&nbsp;into&nbsp;bits.&nbsp;Each&nbsp;bit&nbsp;will&nbsp;be&nbsp;a&nbsp;portion&nbsp;of&nbsp;the&nbsp;code</span></span></div></li> <li><div class="src-line"><a name="a2037"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;within&nbsp;script&nbsp;delimiters&nbsp;-&nbsp;for&nbsp;example,&nbsp;HTML&nbsp;between&nbsp;&lt;&nbsp;and&nbsp;&gt;</span></span></div></li> <li><div class="src-line"><a name="a2038"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$k</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2039"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parts</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2040"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$matches</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2041"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_match_pointer</span>&nbsp;=&nbsp;<span class="src-id">null</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2042"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;we&nbsp;use&nbsp;a&nbsp;copy&nbsp;to&nbsp;unset&nbsp;delimiters&nbsp;on&nbsp;demand&nbsp;(when&nbsp;they&nbsp;are&nbsp;not&nbsp;found)</span></span></div></li> <li><div class="src-line"><a name="a2043"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$delim_copy</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'SCRIPT_DELIMITERS'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2044"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2045"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">while</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;<&nbsp;<span class="src-var">$length</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2046"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_match_pos</span>&nbsp;=&nbsp;<span class="src-var">$length</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">;</span>&nbsp;<span class="src-comm">//&nbsp;never&nbsp;true</span></span></div></li> <li><div class="src-line"><a name="a2047"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$delim_copy</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$dk</span>&nbsp;=&gt;&nbsp;<span class="src-var">$delimiters</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2048"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$delimiters</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2049"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$delimiters</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$open</span>&nbsp;=&gt;&nbsp;<span class="src-var">$close</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2050"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;make&nbsp;sure&nbsp;the&nbsp;cache&nbsp;is&nbsp;setup&nbsp;properly</span></span></div></li> <li><div class="src-line"><a name="a2051"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2052"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2053"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'next_match'</span>&nbsp;=&gt;&nbsp;-<span class="src-num">1</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2054"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'dk'</span>&nbsp;=&gt;&nbsp;<span class="src-var">$dk</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2055"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2056"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'open'</span>&nbsp;=&gt;&nbsp;<span class="src-var">$open</span><span class="src-sym">,</span>&nbsp;<span class="src-comm">//&nbsp;needed&nbsp;for&nbsp;grouping&nbsp;of&nbsp;adjacent&nbsp;code&nbsp;blocks&nbsp;(see&nbsp;below)</span></span></div></li> <li><div class="src-line"><a name="a2057"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'open_strlen'</span>&nbsp;=&gt;&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$open</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2058"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2059"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'close'</span>&nbsp;=&gt;&nbsp;<span class="src-var">$close</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2060"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'close_strlen'</span>&nbsp;=&gt;&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$close</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2061"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2062"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2063"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Get&nbsp;the&nbsp;next&nbsp;little&nbsp;bit&nbsp;for&nbsp;this&nbsp;opening&nbsp;string</span></span></div></li> <li><div class="src-line"><a name="a2064"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'next_match'</span><span class="src-sym">]</span>&nbsp;<&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2065"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;only&nbsp;find&nbsp;the&nbsp;next&nbsp;pos&nbsp;if&nbsp;it&nbsp;was&nbsp;not&nbsp;already&nbsp;cached</span></span></div></li> <li><div class="src-line"><a name="a2066"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$open_pos</span>&nbsp;=&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$open</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2067"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$open_pos</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2068"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;no&nbsp;match&nbsp;for&nbsp;this&nbsp;delimiter&nbsp;ever</span></span></div></li> <li><div class="src-line"><a name="a2069"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$delim_copy</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2070"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2071"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2072"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'next_match'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$open_pos</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2073"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2074"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'next_match'</span><span class="src-sym">]</span>&nbsp;<&nbsp;<span class="src-var">$next_match_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2075"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//So&nbsp;we&nbsp;got&nbsp;a&nbsp;new&nbsp;match,&nbsp;update&nbsp;the&nbsp;close_pos</span></span></div></li> <li><div class="src-line"><a name="a2076"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'close_pos'</span><span class="src-sym">]</span>&nbsp;=</span></div></li> <li><div class="src-line"><a name="a2077"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$close</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'next_match'</span><span class="src-sym">]</span>+<span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2078"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2079"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_match_pointer</span>&nbsp;=<span class="src-sym">&</span>&nbsp;<span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2080"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_match_pos</span>&nbsp;=&nbsp;<span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'next_match'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2081"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2082"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2083"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2084"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//So&nbsp;we&nbsp;should&nbsp;match&nbsp;an&nbsp;RegExp&nbsp;as&nbsp;Strict&nbsp;Block&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2085"></a><span class="src-doc">/**</span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a2086"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;value&nbsp;in&nbsp;$delimiters&nbsp;is&nbsp;expected&nbsp;to&nbsp;be&nbsp;an&nbsp;RegExp</span></div></li> <li><div class="src-line"><a name="a2087"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;containing&nbsp;exactly&nbsp;2&nbsp;matching&nbsp;groups:</span></div></li> <li><div class="src-line"><a name="a2088"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;-&nbsp;Group&nbsp;1&nbsp;is&nbsp;the&nbsp;opener</span></div></li> <li><div class="src-line"><a name="a2089"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;-&nbsp;Group&nbsp;2&nbsp;is&nbsp;the&nbsp;closer</span></div></li> <li><div class="src-line"><a name="a2090"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a2091"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-sym">!</span><span class="src-id">GESHI_PHP_PRE_433</span>&nbsp;&amp;&amp;&nbsp;<span class="src-comm">//Needs&nbsp;proper&nbsp;rewrite&nbsp;to&nbsp;work&nbsp;with&nbsp;PHP&nbsp;&gt;=4.3.0;&nbsp;4.3.3&nbsp;is&nbsp;guaranteed&nbsp;to&nbsp;work.</span></span></div></li> <li><div class="src-line"><a name="a2092"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/preg_match">preg_match</a><span class="src-sym">(</span><span class="src-var">$delimiters</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$code</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$matches_rx</span><span class="src-sym">,</span>&nbsp;<span class="src-id">PREG_OFFSET_CAPTURE</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2093"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//We&nbsp;got&nbsp;a&nbsp;match&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2094"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2095"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'next_match'</span>&nbsp;=&gt;&nbsp;<span class="src-var">$matches_rx</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2096"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'dk'</span>&nbsp;=&gt;&nbsp;<span class="src-var">$dk</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2097"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2098"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'close_strlen'</span>&nbsp;=&gt;&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$matches_rx</span><span class="src-sym">[</span><span class="src-num">2</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2099"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'close_pos'</span>&nbsp;=&gt;&nbsp;<span class="src-var">$matches_rx</span><span class="src-sym">[</span><span class="src-num">2</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2100"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2101"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2102"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;no&nbsp;match&nbsp;for&nbsp;this&nbsp;delimiter&nbsp;ever</span></span></div></li> <li><div class="src-line"><a name="a2103"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$delim_copy</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2104"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2105"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2106"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2107"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'next_match'</span><span class="src-sym">]</span>&nbsp;&lt;=&nbsp;<span class="src-var">$next_match_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2108"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_match_pointer</span>&nbsp;=<span class="src-sym">&</span>&nbsp;<span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2109"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_match_pos</span>&nbsp;=&nbsp;<span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-var">$dk</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'next_match'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2110"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2111"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2112"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2113"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;non-highlightable&nbsp;text</span></span></div></li> <li><div class="src-line"><a name="a2114"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parts</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2115"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">1</span>&nbsp;=&gt;&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$next_match_pos</span>&nbsp;-&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span></span></div></li> <li><div class="src-line"><a name="a2116"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2117"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$k</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2118"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2119"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$next_match_pos</span>&nbsp;>&nbsp;<span class="src-var">$length</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2120"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;out&nbsp;of&nbsp;bounds&nbsp;means&nbsp;no&nbsp;next&nbsp;match&nbsp;was&nbsp;found</span></span></div></li> <li><div class="src-line"><a name="a2121"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2122"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2123"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2124"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;highlightable&nbsp;code</span></span></div></li> <li><div class="src-line"><a name="a2125"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parts</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$next_match_pointer</span><span class="src-sym">[</span><span class="src-str">'dk'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2126"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2127"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Only&nbsp;combine&nbsp;for&nbsp;non-rx&nbsp;script&nbsp;blocks</span></span></div></li> <li><div class="src-line"><a name="a2128"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$delim_copy</span><span class="src-sym">[</span><span class="src-var">$next_match_pointer</span><span class="src-sym">[</span><span class="src-str">'dk'</span><span class="src-sym">]]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2129"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;group&nbsp;adjacent&nbsp;script&nbsp;blocks,&nbsp;e.g.&nbsp;&lt;foobar&gt;&lt;asdf&gt;&nbsp;should&nbsp;be&nbsp;one&nbsp;block,&nbsp;not&nbsp;three!</span></span></div></li> <li><div class="src-line"><a name="a2130"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-var">$next_match_pos</span>&nbsp;+&nbsp;<span class="src-var">$next_match_pointer</span><span class="src-sym">[</span><span class="src-str">'open_strlen'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2131"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">while</span>&nbsp;<span class="src-sym">(</span><span class="src-id">true</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2132"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close_pos</span>&nbsp;=&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$next_match_pointer</span><span class="src-sym">[</span><span class="src-str">'close'</span><span class="src-sym">]</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2133"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$close_pos</span>&nbsp;==&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2134"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2135"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2136"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-var">$close_pos</span>&nbsp;+&nbsp;<span class="src-var">$next_match_pointer</span><span class="src-sym">[</span><span class="src-str">'close_strlen'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2137"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;==&nbsp;<span class="src-var">$length</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2138"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2139"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2140"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span>&nbsp;==&nbsp;<span class="src-var">$next_match_pointer</span><span class="src-sym">[</span><span class="src-str">'open'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;&amp;&amp;&nbsp;<span class="src-sym">(</span><span class="src-var">$next_match_pointer</span><span class="src-sym">[</span><span class="src-str">'open_strlen'</span><span class="src-sym">]</span>&nbsp;==&nbsp;<span class="src-num">1</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2141"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$next_match_pointer</span><span class="src-sym">[</span><span class="src-str">'open_strlen'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;==&nbsp;<span class="src-var">$next_match_pointer</span><span class="src-sym">[</span><span class="src-str">'open'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2142"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;merge&nbsp;adjacent&nbsp;but&nbsp;make&nbsp;sure&nbsp;we&nbsp;don't&nbsp;merge&nbsp;things&nbsp;like&nbsp;&lt;tag&gt;&lt;!--&nbsp;comment&nbsp;--&gt;</span></span></div></li> <li><div class="src-line"><a name="a2143"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$matches</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$submatches</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2144"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$submatches</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$match</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2145"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$match</span><span class="src-sym">[</span><span class="src-str">'next_match'</span><span class="src-sym">]</span>&nbsp;==&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2146"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;a&nbsp;different&nbsp;block&nbsp;already&nbsp;matches&nbsp;here!</span></span></div></li> <li><div class="src-line"><a name="a2147"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span>&nbsp;<span class="src-num">3</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2148"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2149"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2150"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2151"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2152"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2153"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2154"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2155"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2156"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close_pos</span>&nbsp;=&nbsp;<span class="src-var">$next_match_pointer</span><span class="src-sym">[</span><span class="src-str">'close_pos'</span><span class="src-sym">]</span>&nbsp;+&nbsp;<span class="src-var">$next_match_pointer</span><span class="src-sym">[</span><span class="src-str">'close_strlen'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2157"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-var">$close_pos</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2158"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2159"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2160"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$close_pos</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2161"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;no&nbsp;closing&nbsp;delimiter&nbsp;found!</span></span></div></li> <li><div class="src-line"><a name="a2162"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parts</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span>&nbsp;=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$next_match_pos</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2163"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$k</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2164"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2165"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2166"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parts</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span>&nbsp;=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$next_match_pos</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span>&nbsp;-&nbsp;<span class="src-var">$next_match_pos</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2167"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$k</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2168"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2169"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2170"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$delim_copy</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$next_match_pointer</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$next_match_pos</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$matches</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2171"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$num_parts</span>&nbsp;=&nbsp;<span class="src-var">$k</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2172"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2173"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$num_parts</span>&nbsp;==&nbsp;<span class="src-num">1</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">strict_mode</span>&nbsp;==&nbsp;<span class="src-id">GESHI_MAYBE</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2174"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;when&nbsp;we&nbsp;have&nbsp;only&nbsp;one&nbsp;part,&nbsp;we&nbsp;don't&nbsp;have&nbsp;anything&nbsp;to&nbsp;highlight&nbsp;at&nbsp;all.</span></span></div></li> <li><div class="src-line"><a name="a2175"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;if&nbsp;we&nbsp;have&nbsp;a&nbsp;&quot;maybe&quot;&nbsp;strict&nbsp;language,&nbsp;this&nbsp;should&nbsp;be&nbsp;handled&nbsp;as&nbsp;highlightable&nbsp;code</span></span></div></li> <li><div class="src-line"><a name="a2176"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parts</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2177"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">0</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2178"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">0</span>&nbsp;=&gt;&nbsp;<span class="src-str">''</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2179"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">1</span>&nbsp;=&gt;&nbsp;<span class="src-str">''</span></span></div></li> <li><div class="src-line"><a name="a2180"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2181"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">1</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2182"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">0</span>&nbsp;=&gt;&nbsp;<span class="src-id">null</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2183"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">1</span>&nbsp;=&gt;&nbsp;<span class="src-var">$parts</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span></span></div></li> <li><div class="src-line"><a name="a2184"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span></span></div></li> <li><div class="src-line"><a name="a2185"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2186"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$num_parts</span>&nbsp;=&nbsp;<span class="src-num">2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2187"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2188"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2189"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2190"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Not&nbsp;strict&nbsp;mode&nbsp;-&nbsp;simply&nbsp;dump&nbsp;the&nbsp;source&nbsp;into</span></span></div></li> <li><div class="src-line"><a name="a2191"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;the&nbsp;array&nbsp;at&nbsp;index&nbsp;1&nbsp;(the&nbsp;first&nbsp;highlightable&nbsp;block)</span></span></div></li> <li><div class="src-line"><a name="a2192"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parts</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2193"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">0</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2194"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">0</span>&nbsp;=&gt;&nbsp;<span class="src-str">''</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2195"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">1</span>&nbsp;=&gt;&nbsp;<span class="src-str">''</span></span></div></li> <li><div class="src-line"><a name="a2196"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2197"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">1</span>&nbsp;=&gt;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2198"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">0</span>&nbsp;=&gt;&nbsp;<span class="src-id">null</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2199"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-num">1</span>&nbsp;=&gt;&nbsp;<span class="src-var">$code</span></span></div></li> <li><div class="src-line"><a name="a2200"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span></span></div></li> <li><div class="src-line"><a name="a2201"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2202"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$num_parts</span>&nbsp;=&nbsp;<span class="src-num">2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2203"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2204"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2205"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Unset&nbsp;variables&nbsp;we&nbsp;won't&nbsp;need&nbsp;any&nbsp;longer</span></span></div></li> <li><div class="src-line"><a name="a2206"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2207"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2208"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Preload&nbsp;some&nbsp;repeatedly&nbsp;used&nbsp;values&nbsp;regarding&nbsp;hardquotes&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2209"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$hq</span>&nbsp;=&nbsp;isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'HARDQUOTE'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'HARDQUOTE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;:&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2210"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$hq_strlen</span>&nbsp;=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$hq</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2211"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2212"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Preload&nbsp;if&nbsp;line&nbsp;numbers&nbsp;are&nbsp;to&nbsp;be&nbsp;generated&nbsp;afterwards</span></span></div></li> <li><div class="src-line"><a name="a2213"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Added&nbsp;a&nbsp;check&nbsp;if&nbsp;line&nbsp;breaks&nbsp;should&nbsp;be&nbsp;forced&nbsp;even&nbsp;without&nbsp;line&nbsp;numbers,&nbsp;fixes&nbsp;SF#1727398</span></span></div></li> <li><div class="src-line"><a name="a2214"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$check_linenumbers</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS&quot;&gt;GESHI_NO_LINE_NUMBERS&lt;/a&gt;</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2215"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines</span><span class="src-sym">)</span>&nbsp;||&nbsp;<span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">allow_multiline_span</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2216"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2217"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//preload&nbsp;the&nbsp;escape&nbsp;char&nbsp;for&nbsp;faster&nbsp;checking&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2218"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escaped_escape_char</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2219"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2220"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;this&nbsp;is&nbsp;used&nbsp;for&nbsp;single-line&nbsp;comments</span></span></div></li> <li><div class="src-line"><a name="a2221"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$sc_disallowed_before</span>&nbsp;=&nbsp;<span class="src-str">&quot;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2222"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$sc_disallowed_after</span>&nbsp;=&nbsp;<span class="src-str">&quot;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2223"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2224"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2225"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2226"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'DISALLOWED_BEFORE'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2227"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$sc_disallowed_before</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'DISALLOWED_BEFORE'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2228"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2229"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'DISALLOWED_AFTER'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2230"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$sc_disallowed_after</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'DISALLOWED_AFTER'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2231"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2232"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2233"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2234"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2235"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Fix&nbsp;for&nbsp;SF#1932083:&nbsp;Multichar&nbsp;Quotemarks&nbsp;unsupported</span></span></div></li> <li><div class="src-line"><a name="a2236"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$is_string_starter</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2237"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'STRINGS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2238"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'QUOTEMARKS'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$quotemark</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2239"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$is_string_starter</span><span class="src-sym">[</span><span class="src-var">$quotemark</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2240"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$is_string_starter</span><span class="src-sym">[</span><span class="src-var">$quotemark</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]]</span>&nbsp;=&nbsp;(string)<span class="src-var">$quotemark</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2241"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_string">is_string</a><span class="src-sym">(</span><span class="src-var">$is_string_starter</span><span class="src-sym">[</span><span class="src-var">$quotemark</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2242"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$is_string_starter</span><span class="src-sym">[</span><span class="src-var">$quotemark</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2243"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$is_string_starter</span><span class="src-sym">[</span><span class="src-var">$quotemark</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]]</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2244"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$quotemark</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2245"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2246"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$is_string_starter</span><span class="src-sym">[</span><span class="src-var">$quotemark</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]]</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$quotemark</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2247"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2248"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2249"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2250"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2251"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Now&nbsp;we&nbsp;go&nbsp;through&nbsp;each&nbsp;part.&nbsp;We&nbsp;know&nbsp;that&nbsp;even-indexed&nbsp;parts&nbsp;are</span></span></div></li> <li><div class="src-line"><a name="a2252"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;code&nbsp;that&nbsp;shouldn't&nbsp;be&nbsp;highlighted,&nbsp;and&nbsp;odd-indexed&nbsp;parts&nbsp;should</span></span></div></li> <li><div class="src-line"><a name="a2253"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;be&nbsp;highlighted</span></span></div></li> <li><div class="src-line"><a name="a2254"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$key</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$key</span>&nbsp;<&nbsp;<span class="src-var">$num_parts</span><span class="src-sym">;</span>&nbsp;++<span class="src-var">$key</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2255"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$STRICTATTRS</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2256"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2257"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;If&nbsp;this&nbsp;block&nbsp;should&nbsp;be&nbsp;highlighted...</span></span></div></li> <li><div class="src-line"><a name="a2258"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-sym">(</span><span class="src-var">$key</span>&nbsp;<span class="src-sym">&</span>&nbsp;<span class="src-num">1</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2259"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Else&nbsp;not&nbsp;a&nbsp;block&nbsp;to&nbsp;highlight</span></span></div></li> <li><div class="src-line"><a name="a2260"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$endresult</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$parts</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2261"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$parts</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2262"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2263"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2264"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2265"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2266"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$part</span>&nbsp;=&nbsp;<span class="src-var">$parts</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2267"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2268"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$highlight_part</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2269"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">strict_mode</span>&nbsp;&amp;&amp;&nbsp;<span class="src-sym">!</span><a href="http://www.php.net/is_null">is_null</a><span class="src-sym">(</span><span class="src-var">$parts</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2270"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;get&nbsp;the&nbsp;class&nbsp;key&nbsp;for&nbsp;this&nbsp;block&nbsp;of&nbsp;code</span></span></div></li> <li><div class="src-line"><a name="a2271"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$script_key</span>&nbsp;=&nbsp;<span class="src-var">$parts</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2272"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$highlight_part</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'HIGHLIGHT_STRICT_BLOCK'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$script_key</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2273"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'SCRIPT'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$script_key</span><span class="src-sym">]</span>&nbsp;!=&nbsp;<span class="src-str">''</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2274"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'SCRIPT'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2275"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Add&nbsp;a&nbsp;span&nbsp;element&nbsp;around&nbsp;the&nbsp;source&nbsp;to</span></span></div></li> <li><div class="src-line"><a name="a2276"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;highlight&nbsp;the&nbsp;overall&nbsp;source&nbsp;block</span></span></div></li> <li><div class="src-line"><a name="a2277"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2278"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'SCRIPT'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$script_key</span><span class="src-sym">]</span>&nbsp;!=&nbsp;<span class="src-str">''</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2279"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'SCRIPT'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$script_key</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2280"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2281"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;sc'</span>&nbsp;.&nbsp;<span class="src-var">$script_key</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2282"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2283"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;.=&nbsp;<span class="src-str">"</span></span>&lt;span<span class="src-var">$attributes</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2284"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$STRICTATTRS</span>&nbsp;=&nbsp;<span class="src-var">$attributes</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2285"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2286"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2287"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2288"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$highlight_part</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2289"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Now,&nbsp;highlight&nbsp;the&nbsp;code&nbsp;in&nbsp;this&nbsp;block.&nbsp;This&nbsp;code</span></span></div></li> <li><div class="src-line"><a name="a2290"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;is&nbsp;really&nbsp;the&nbsp;engine&nbsp;of&nbsp;GeSHi&nbsp;(along&nbsp;with&nbsp;the&nbsp;method</span></span></div></li> <li><div class="src-line"><a name="a2291"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;parse_non_string_part).</span></span></div></li> <li><div class="src-line"><a name="a2292"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a2293"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;cache&nbsp;comment&nbsp;regexps&nbsp;incrementally</span></span></div></li> <li><div class="src-line"><a name="a2294"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_regexp_key</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2295"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_regexp_pos</span>&nbsp;=&nbsp;-<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2296"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_multi_pos</span>&nbsp;=&nbsp;-<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2297"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_single_pos</span>&nbsp;=&nbsp;-<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2298"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_regexp_cache_per_key</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2299"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_multi_cache_per_key</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2300"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_single_cache_per_key</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2301"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_open_comment_multi</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2302"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_single_key</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2303"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_regexp_cache_per_key</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2304"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_escape_regexp_key</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2305"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_escape_regexp_pos</span>&nbsp;=&nbsp;-<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2306"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2307"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$length</span>&nbsp;=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2308"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$i</span>&nbsp;<&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span>&nbsp;++<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2309"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Get&nbsp;the&nbsp;next&nbsp;char</span></span></div></li> <li><div class="src-line"><a name="a2310"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$char</span>&nbsp;=&nbsp;<span class="src-var">$part</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2311"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$char_len</span>&nbsp;=&nbsp;<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2312"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2313"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;update&nbsp;regexp&nbsp;comment&nbsp;cache&nbsp;if&nbsp;needed</span></span></div></li> <li><div class="src-line"><a name="a2314"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'COMMENT_REGEXP'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$next_comment_regexp_pos</span>&nbsp;<&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2315"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_regexp_pos</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2316"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'COMMENT_REGEXP'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$comment_key</span>&nbsp;=&gt;&nbsp;<span class="src-var">$regexp</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2317"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$match_i</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2318"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$comment_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2319"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-var">$comment_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'pos'</span><span class="src-sym">]</span>&nbsp;&gt;=&nbsp;<span class="src-var">$i</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2320"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'pos'</span><span class="src-sym">]</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2321"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;we&nbsp;have&nbsp;already&nbsp;matched&nbsp;something</span></span></div></li> <li><div class="src-line"><a name="a2322"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$comment_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'pos'</span><span class="src-sym">]</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2323"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;this&nbsp;comment&nbsp;is&nbsp;never&nbsp;matched</span></span></div></li> <li><div class="src-line"><a name="a2324"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2325"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2326"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$match_i</span>&nbsp;=&nbsp;<span class="src-var">$comment_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'pos'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2327"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2328"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//This&nbsp;is&nbsp;to&nbsp;allow&nbsp;use&nbsp;of&nbsp;the&nbsp;offset&nbsp;parameter&nbsp;in&nbsp;preg_match&nbsp;and&nbsp;stay&nbsp;as&nbsp;compatible&nbsp;with&nbsp;older&nbsp;PHP&nbsp;versions&nbsp;as&nbsp;possible</span></span></div></li> <li><div class="src-line"><a name="a2329"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-id">GESHI_PHP_PRE_433</span>&nbsp;&amp;&amp;&nbsp;<a href="http://www.php.net/preg_match">preg_match</a><span class="src-sym">(</span><span class="src-var">$regexp</span><span class="src-sym">,</span>&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$match</span><span class="src-sym">,</span>&nbsp;<span class="src-id">PREG_OFFSET_CAPTURE</span><span class="src-sym">))</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2330"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-id">GESHI_PHP_PRE_433</span>&nbsp;&amp;&amp;&nbsp;<a href="http://www.php.net/preg_match">preg_match</a><span class="src-sym">(</span><span class="src-var">$regexp</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$match</span><span class="src-sym">,</span>&nbsp;<span class="src-id">PREG_OFFSET_CAPTURE</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">))</span></span></div></li> <li><div class="src-line"><a name="a2331"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2332"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$match_i</span>&nbsp;=&nbsp;<span class="src-var">$match</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2333"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">GESHI_PHP_PRE_433</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2334"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$match_i</span>&nbsp;+=&nbsp;<span class="src-var">$i</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2335"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2336"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2337"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2338"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'key'</span>&nbsp;=&gt;&nbsp;<span class="src-var">$comment_key</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2339"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'length'</span>&nbsp;=&gt;&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$match</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2340"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'pos'</span>&nbsp;=&gt;&nbsp;<span class="src-var">$match_i</span></span></div></li> <li><div class="src-line"><a name="a2341"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2342"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2343"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'pos'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2344"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2345"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2346"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2347"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$match_i</span>&nbsp;!==&nbsp;<span class="src-id">false</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$match_i</span>&nbsp;<&nbsp;<span class="src-var">$next_comment_regexp_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2348"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_regexp_pos</span>&nbsp;=&nbsp;<span class="src-var">$match_i</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2349"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_regexp_key</span>&nbsp;=&nbsp;<span class="src-var">$comment_key</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2350"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$match_i</span>&nbsp;===&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2351"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2352"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2353"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2354"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2355"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2356"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2357"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string_started</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2358"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2359"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$is_string_starter</span><span class="src-sym">[</span><span class="src-var">$char</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2360"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Possibly&nbsp;the&nbsp;start&nbsp;of&nbsp;a&nbsp;new&nbsp;string&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2361"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a2362"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;which&nbsp;starter&nbsp;it&nbsp;was&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2363"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Fix&nbsp;for&nbsp;SF#1932083:&nbsp;Multichar&nbsp;Quotemarks&nbsp;unsupported</span></span></div></li> <li><div class="src-line"><a name="a2364"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$is_string_starter</span><span class="src-sym">[</span><span class="src-var">$char</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2365"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$char_new</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2366"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$is_string_starter</span><span class="src-sym">[</span><span class="src-var">$char</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$testchar</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2367"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$testchar</span>&nbsp;===&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">,</span>&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$testchar</span><span class="src-sym">))</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2368"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$testchar</span><span class="src-sym">)</span>&nbsp;>&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$char_new</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2369"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$char_new</span>&nbsp;=&nbsp;<span class="src-var">$testchar</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2370"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string_started</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2371"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2372"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2373"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$string_started</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2374"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$char</span>&nbsp;=&nbsp;<span class="src-var">$char_new</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2375"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2376"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2377"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$testchar</span>&nbsp;=&nbsp;<span class="src-var">$is_string_starter</span><span class="src-sym">[</span><span class="src-var">$char</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2378"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$testchar</span>&nbsp;===&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">,</span>&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$testchar</span><span class="src-sym">)))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2379"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$char</span>&nbsp;=&nbsp;<span class="src-var">$testchar</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2380"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string_started</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2381"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2382"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2383"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$char_len</span>&nbsp;=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$char</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2384"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2385"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2386"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$string_started</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$i</span>&nbsp;!=&nbsp;<span class="src-var">$next_comment_regexp_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2387"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Hand&nbsp;out&nbsp;the&nbsp;correct&nbsp;style&nbsp;information&nbsp;for&nbsp;this&nbsp;string</span></span></div></li> <li><div class="src-line"><a name="a2388"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string_key</span>&nbsp;=&nbsp;<a href="http://www.php.net/array_search">array_search</a><span class="src-sym">(</span><span class="src-var">$char</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'QUOTEMARKS'</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2389"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'STRINGS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$string_key</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2390"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$string_key</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2391"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string_key</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2392"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2393"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2394"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;parse&nbsp;the&nbsp;stuff&nbsp;before&nbsp;this</span></span></div></li> <li><div class="src-line"><a name="a2395"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">parse_non_string_part</span><span class="src-sym">(</span><span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2396"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2397"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2398"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2399"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string_attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'STRINGS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$string_key</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2400"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2401"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string_attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;st'</span>.<span class="src-var">$string_key</span>.<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2402"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2403"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2404"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;now&nbsp;handle&nbsp;the&nbsp;string</span></span></div></li> <li><div class="src-line"><a name="a2405"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;=&nbsp;<span class="src-str">"</span></span>&lt;span<span class="src-var">$string_attributes</span>&gt;<span class="src-str">&quot;&nbsp;</span><span class="src-str">.&nbsp;<span class="src-id">GeSHi</span><span class="src-sym">::</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$char</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2406"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-var">$char_len</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2407"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string_open</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2408"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2409"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_REGEXP'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2410"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_escape_regexp_pos</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2411"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2412"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2413"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;do&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2414"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Get&nbsp;the&nbsp;regular&nbsp;ending&nbsp;pos&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2415"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close_pos</span>&nbsp;=&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$char</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2416"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-id">false</span>&nbsp;===&nbsp;<span class="src-var">$close_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2417"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close_pos</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2418"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2419"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2420"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2421"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;update&nbsp;escape&nbsp;regexp&nbsp;cache&nbsp;if&nbsp;needed</span></span></div></li> <li><div class="src-line"><a name="a2422"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_REGEXP'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$next_escape_regexp_pos</span>&nbsp;<&nbsp;<span class="src-var">$start</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2423"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_escape_regexp_pos</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2424"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_REGEXP'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$escape_key</span>&nbsp;=&gt;&nbsp;<span class="src-var">$regexp</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2425"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$match_i</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2426"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$escape_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$escape_key</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2427"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-var">$escape_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$escape_key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'pos'</span><span class="src-sym">]</span>&nbsp;&gt;=&nbsp;<span class="src-var">$start</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2428"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$escape_key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'pos'</span><span class="src-sym">]</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2429"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;we&nbsp;have&nbsp;already&nbsp;matched&nbsp;something</span></span></div></li> <li><div class="src-line"><a name="a2430"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$escape_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$escape_key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'pos'</span><span class="src-sym">]</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2431"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;this&nbsp;comment&nbsp;is&nbsp;never&nbsp;matched</span></span></div></li> <li><div class="src-line"><a name="a2432"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2433"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2434"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$match_i</span>&nbsp;=&nbsp;<span class="src-var">$escape_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$escape_key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'pos'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2435"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2436"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//This&nbsp;is&nbsp;to&nbsp;allow&nbsp;use&nbsp;of&nbsp;the&nbsp;offset&nbsp;parameter&nbsp;in&nbsp;preg_match&nbsp;and&nbsp;stay&nbsp;as&nbsp;compatible&nbsp;with&nbsp;older&nbsp;PHP&nbsp;versions&nbsp;as&nbsp;possible</span></span></div></li> <li><div class="src-line"><a name="a2437"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-id">GESHI_PHP_PRE_433</span>&nbsp;&amp;&amp;&nbsp;<a href="http://www.php.net/preg_match">preg_match</a><span class="src-sym">(</span><span class="src-var">$regexp</span><span class="src-sym">,</span>&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$match</span><span class="src-sym">,</span>&nbsp;<span class="src-id">PREG_OFFSET_CAPTURE</span><span class="src-sym">))</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2438"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-id">GESHI_PHP_PRE_433</span>&nbsp;&amp;&amp;&nbsp;<a href="http://www.php.net/preg_match">preg_match</a><span class="src-sym">(</span><span class="src-var">$regexp</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$match</span><span class="src-sym">,</span>&nbsp;<span class="src-id">PREG_OFFSET_CAPTURE</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start</span><span class="src-sym">))</span></span></div></li> <li><div class="src-line"><a name="a2439"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2440"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$match_i</span>&nbsp;=&nbsp;<span class="src-var">$match</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2441"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">GESHI_PHP_PRE_433</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2442"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$match_i</span>&nbsp;+=&nbsp;<span class="src-var">$start</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2443"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2444"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2445"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$escape_key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2446"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'key'</span>&nbsp;=&gt;&nbsp;<span class="src-var">$escape_key</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2447"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'length'</span>&nbsp;=&gt;&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$match</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2448"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'pos'</span>&nbsp;=&gt;&nbsp;<span class="src-var">$match_i</span></span></div></li> <li><div class="src-line"><a name="a2449"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2450"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2451"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$escape_key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'pos'</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2452"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2453"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2454"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2455"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$match_i</span>&nbsp;!==&nbsp;<span class="src-id">false</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$match_i</span>&nbsp;<&nbsp;<span class="src-var">$next_escape_regexp_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2456"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_escape_regexp_pos</span>&nbsp;=&nbsp;<span class="src-var">$match_i</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2457"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_escape_regexp_key</span>&nbsp;=&nbsp;<span class="src-var">$escape_key</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2458"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$match_i</span>&nbsp;===&nbsp;<span class="src-var">$start</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2459"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2460"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2461"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2462"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2463"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2464"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2465"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Find&nbsp;the&nbsp;next&nbsp;simple&nbsp;escape&nbsp;position</span></span></div></li> <li><div class="src-line"><a name="a2466"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-str">''</span>&nbsp;!=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2467"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$simple_escape</span>&nbsp;=&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2468"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-id">false</span>&nbsp;===&nbsp;<span class="src-var">$simple_escape</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2469"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$simple_escape</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2470"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2471"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2472"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$simple_escape</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2473"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2474"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2475"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_escape_regexp_pos</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2476"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$simple_escape</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2477"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2478"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2479"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-var">$simple_escape</span>&nbsp;<&nbsp;<span class="src-var">$next_escape_regexp_pos</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2480"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$simple_escape</span>&nbsp;<&nbsp;<span class="src-var">$length</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2481"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$simple_escape</span>&nbsp;<&nbsp;<span class="src-var">$close_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2482"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//The&nbsp;nexxt&nbsp;escape&nbsp;sequence&nbsp;is&nbsp;a&nbsp;simple&nbsp;one&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2483"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$es_pos</span>&nbsp;=&nbsp;<span class="src-var">$simple_escape</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2484"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2485"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Add&nbsp;the&nbsp;stuff&nbsp;not&nbsp;in&nbsp;the&nbsp;string&nbsp;yet&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2486"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$es_pos</span>&nbsp;-&nbsp;<span class="src-var">$start</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2487"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2488"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Get&nbsp;the&nbsp;style&nbsp;for&nbsp;this&nbsp;escaped&nbsp;char&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2489"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2490"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_char_attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2491"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2492"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_char_attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;es0&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2493"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2494"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2495"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Add&nbsp;the&nbsp;style&nbsp;for&nbsp;the&nbsp;escape&nbsp;char&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2496"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;.=&nbsp;<span class="src-str">"</span></span>&lt;span<span class="src-var">$escape_char_attributes</span>&gt;<span class="src-str">&quot;&nbsp;</span><span class="src-str">.</span></div></li> <li><div class="src-line"><a name="a2497"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">GeSHi</span><span class="src-sym">::</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2498"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2499"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Get&nbsp;the&nbsp;byte&nbsp;AFTER&nbsp;the&nbsp;ESCAPE_CHAR&nbsp;we&nbsp;just&nbsp;found</span></span></div></li> <li><div class="src-line"><a name="a2500"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$es_char</span>&nbsp;=&nbsp;<span class="src-var">$part</span><span class="src-sym">[</span><span class="src-var">$es_pos</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2501"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$es_char</span>&nbsp;==&nbsp;<span class="src-str">&quot;\n&quot;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2502"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;don't&nbsp;put&nbsp;a&nbsp;newline&nbsp;around&nbsp;newlines</span></span></div></li> <li><div class="src-line"><a name="a2503"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;.=&nbsp;<span class="src-str">&quot;&lt;/span&gt;\n&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2504"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-var">$es_pos</span>&nbsp;+&nbsp;<span class="src-num">2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2505"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/ord">ord</a><span class="src-sym">(</span><span class="src-var">$es_char</span><span class="src-sym">)</span>&nbsp;&gt;=&nbsp;<span class="src-num">128</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2506"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//This&nbsp;is&nbsp;an&nbsp;non-ASCII&nbsp;char&nbsp;(UTF8&nbsp;or&nbsp;single&nbsp;byte)</span></span></div></li> <li><div class="src-line"><a name="a2507"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//This&nbsp;code&nbsp;tries&nbsp;to&nbsp;work&nbsp;around&nbsp;SF#2037598&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2508"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><a href="http://www.php.net/function_exists">function_exists</a><span class="src-sym">(</span><span class="src-str">'mb_substr'</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2509"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$es_char_m</span>&nbsp;=&nbsp;<a href="http://www.php.net/mb_substr">mb_substr</a><span class="src-sym">(</span><a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$es_pos</span>+<span class="src-num">1</span><span class="src-sym">,</span>&nbsp;<span class="src-num">16</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-num">0</span><span class="src-sym">,</span>&nbsp;<span class="src-num">1</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">encoding</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2510"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;.=&nbsp;<span class="src-var">$es_char_m</span>&nbsp;.&nbsp;<span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2511"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-id">GESHI_PHP_PRE_433</span>&nbsp;&amp;&amp;&nbsp;<span class="src-str">'utf-8'</span>&nbsp;==&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">encoding</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2512"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><a href="http://www.php.net/preg_match">preg_match</a><span class="src-sym">(</span><span class="src-str">&quot;/[\xC2-\xDF][\x80-\xBF]&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a2513"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;|\xE0[\xA0-\xBF][\x80-\xBF]&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a2514"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;|[\xE1-\xEC\xEE\xEF][\x80-\xBF]{2}&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a2515"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;|\xED[\x80-\x9F][\x80-\xBF]&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a2516"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;|\xF0[\x90-\xBF][\x80-\xBF]{2}&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a2517"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;|[\xF1-\xF3][\x80-\xBF]{3}&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a2518"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;|\xF4[\x80-\x8F][\x80-\xBF]{2}/s&quot;</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2519"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$es_char_m</span><span class="src-sym">,</span>&nbsp;<span class="src-id">null</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$es_pos</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2520"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$es_char_m</span>&nbsp;=&nbsp;<span class="src-var">$es_char_m</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2521"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2522"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$es_char_m</span>&nbsp;=&nbsp;<span class="src-var">$es_char</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2523"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2524"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$es_char_m</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2525"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2526"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$es_char_m</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$es_char</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2527"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2528"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-var">$es_pos</span>&nbsp;+&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$es_char_m</span><span class="src-sym">)</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2529"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2530"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$es_char</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2531"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-var">$es_pos</span>&nbsp;+&nbsp;<span class="src-num">2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2532"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2533"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$next_escape_regexp_pos</span>&nbsp;<&nbsp;<span class="src-var">$length</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2534"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_escape_regexp_pos</span>&nbsp;<&nbsp;<span class="src-var">$close_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2535"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$es_pos</span>&nbsp;=&nbsp;<span class="src-var">$next_escape_regexp_pos</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2536"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Add&nbsp;the&nbsp;stuff&nbsp;not&nbsp;in&nbsp;the&nbsp;string&nbsp;yet&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2537"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$es_pos</span>&nbsp;-&nbsp;<span class="src-var">$start</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2538"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2539"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Get&nbsp;the&nbsp;key&nbsp;and&nbsp;length&nbsp;of&nbsp;this&nbsp;match&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2540"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape</span>&nbsp;=&nbsp;<span class="src-var">$escape_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$next_escape_regexp_key</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2541"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_str</span>&nbsp;=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$es_pos</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$escape</span><span class="src-sym">[</span><span class="src-str">'length'</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2542"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_key</span>&nbsp;=&nbsp;<span class="src-var">$escape</span><span class="src-sym">[</span><span class="src-str">'key'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2543"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2544"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Get&nbsp;the&nbsp;style&nbsp;for&nbsp;this&nbsp;escaped&nbsp;char&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2545"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2546"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_char_attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$escape_key</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2547"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2548"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_char_attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;es'</span>&nbsp;.&nbsp;<span class="src-var">$escape_key</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2549"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2550"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2551"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Add&nbsp;the&nbsp;style&nbsp;for&nbsp;the&nbsp;escape&nbsp;char&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2552"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;.=&nbsp;<span class="src-str">"</span></span>&lt;span<span class="src-var">$escape_char_attributes</span>&gt;<span class="src-str">&quot;&nbsp;</span><span class="src-str">.</span></div></li> <li><div class="src-line"><a name="a2553"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$escape_str</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2554"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2555"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-var">$es_pos</span>&nbsp;+&nbsp;<span class="src-var">$escape</span><span class="src-sym">[</span><span class="src-str">'length'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2556"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2557"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Copy&nbsp;the&nbsp;remainder&nbsp;of&nbsp;the&nbsp;string&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a2558"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$close_pos</span>&nbsp;-&nbsp;<span class="src-var">$start</span>&nbsp;+&nbsp;<span class="src-var">$char_len</span><span class="src-sym">))</span>&nbsp;.&nbsp;<span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2559"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-var">$close_pos</span>&nbsp;+&nbsp;<span class="src-var">$char_len</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2560"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string_open</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2561"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2562"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">while</span><span class="src-sym">(</span><span class="src-var">$string_open</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2563"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2564"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$check_linenumbers</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2565"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Are&nbsp;line&nbsp;numbers&nbsp;used?&nbsp;If,&nbsp;we&nbsp;should&nbsp;end&nbsp;the&nbsp;string&nbsp;before</span></span></div></li> <li><div class="src-line"><a name="a2566"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;the&nbsp;newline&nbsp;and&nbsp;begin&nbsp;it&nbsp;again&nbsp;(so&nbsp;when&nbsp;&lt;li&gt;s&nbsp;are&nbsp;put&nbsp;in&nbsp;the&nbsp;source</span></span></div></li> <li><div class="src-line"><a name="a2567"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;remains&nbsp;XHTML&nbsp;compliant)</span></span></div></li> <li><div class="src-line"><a name="a2568"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;note&nbsp;to&nbsp;self:&nbsp;This&nbsp;opens&nbsp;up&nbsp;possibility&nbsp;of&nbsp;config&nbsp;files&nbsp;specifying</span></span></div></li> <li><div class="src-line"><a name="a2569"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;that&nbsp;languages&nbsp;can/cannot&nbsp;have&nbsp;multiline&nbsp;strings???</span></span></div></li> <li><div class="src-line"><a name="a2570"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">"</span></span>&lt;/span&gt;\n&lt;span<span class="src-var">$string_attributes</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span>&nbsp;<span class="src-var">$string</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2571"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2572"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2573"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;.=&nbsp;<span class="src-var">$string</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2574"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2575"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-var">$start</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2576"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2577"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'STRINGS'</span><span class="src-sym">]</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$hq</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$hq</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;==&nbsp;<span class="src-var">$char</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2578"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$hq_strlen</span><span class="src-sym">)</span>&nbsp;==&nbsp;<span class="src-var">$hq</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2579"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;The&nbsp;start&nbsp;of&nbsp;a&nbsp;hard&nbsp;quoted&nbsp;string</span></span></div></li> <li><div class="src-line"><a name="a2580"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2581"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string_attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'STRINGS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'HARD'</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2582"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_char_attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'HARD'</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2583"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2584"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string_attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;st_h&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2585"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_char_attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;es_h&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2586"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2587"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;parse&nbsp;the&nbsp;stuff&nbsp;before&nbsp;this</span></span></div></li> <li><div class="src-line"><a name="a2588"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">parse_non_string_part</span><span class="src-sym">(</span><span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2589"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2590"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2591"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;now&nbsp;handle&nbsp;the&nbsp;string</span></span></div></li> <li><div class="src-line"><a name="a2592"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2593"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2594"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;look&nbsp;for&nbsp;closing&nbsp;quote</span></span></div></li> <li><div class="src-line"><a name="a2595"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-var">$hq_strlen</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2596"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">while</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$close_pos</span>&nbsp;=&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'HARDQUOTE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2597"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-var">$close_pos</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2598"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$part</span><span class="src-sym">[</span><span class="src-var">$close_pos</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">]</span>&nbsp;==&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2599"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;make&nbsp;sure&nbsp;this&nbsp;quote&nbsp;is&nbsp;not&nbsp;escaped</span></span></div></li> <li><div class="src-line"><a name="a2600"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'HARDESCAPE'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$hardescape</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2601"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$close_pos</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">,</span>&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$hardescape</span><span class="src-sym">))</span>&nbsp;==&nbsp;<span class="src-var">$hardescape</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2602"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;check&nbsp;wether&nbsp;this&nbsp;quote&nbsp;is&nbsp;escaped&nbsp;or&nbsp;if&nbsp;it&nbsp;is&nbsp;something&nbsp;like&nbsp;'\\'</span></span></div></li> <li><div class="src-line"><a name="a2603"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$escape_char_pos</span>&nbsp;=&nbsp;<span class="src-var">$close_pos</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2604"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">while</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$escape_char_pos</span>&nbsp;>&nbsp;<span class="src-num">0</span></span></div></li> <li><div class="src-line"><a name="a2605"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&amp;&amp;&nbsp;<span class="src-var">$part</span><span class="src-sym">[</span><span class="src-var">$escape_char_pos</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">]</span>&nbsp;==&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2606"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;--<span class="src-var">$escape_char_pos</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2607"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2608"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">((</span><span class="src-var">$close_pos</span>&nbsp;-&nbsp;<span class="src-var">$escape_char_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">&</span>&nbsp;<span class="src-num">1</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2609"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;uneven&nbsp;number&nbsp;of&nbsp;escape&nbsp;chars&nbsp;=&gt;&nbsp;this&nbsp;quote&nbsp;is&nbsp;escaped</span></span></div></li> <li><div class="src-line"><a name="a2610"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span>&nbsp;<span class="src-num">2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2611"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2612"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2613"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2614"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2615"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2616"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;found&nbsp;closing&nbsp;quote</span></span></div></li> <li><div class="src-line"><a name="a2617"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2618"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2619"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2620"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Found&nbsp;the&nbsp;closing&nbsp;delimiter?</span></span></div></li> <li><div class="src-line"><a name="a2621"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$close_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2622"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;span&nbsp;till&nbsp;the&nbsp;end&nbsp;of&nbsp;this&nbsp;$part&nbsp;when&nbsp;no&nbsp;closing&nbsp;delimiter&nbsp;is&nbsp;found</span></span></div></li> <li><div class="src-line"><a name="a2623"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close_pos</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2624"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2625"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2626"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Get&nbsp;the&nbsp;actual&nbsp;string</span></span></div></li> <li><div class="src-line"><a name="a2627"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$close_pos</span>&nbsp;-&nbsp;<span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2628"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-var">$close_pos</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2629"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2630"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;handle&nbsp;escape&nbsp;chars&nbsp;and&nbsp;encode&nbsp;html&nbsp;chars</span></span></div></li> <li><div class="src-line"><a name="a2631"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;(special&nbsp;because&nbsp;when&nbsp;we&nbsp;have&nbsp;escape&nbsp;chars&nbsp;within&nbsp;our&nbsp;string&nbsp;they&nbsp;may&nbsp;not&nbsp;be&nbsp;escaped)</span></span></div></li> <li><div class="src-line"><a name="a2632"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2633"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2634"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$new_string</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2635"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">while</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$es_pos</span>&nbsp;=&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$string</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2636"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;hmtl&nbsp;escape&nbsp;stuff&nbsp;before</span></span></div></li> <li><div class="src-line"><a name="a2637"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$new_string</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$string</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$es_pos</span>&nbsp;-&nbsp;<span class="src-var">$start</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2638"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;check&nbsp;if&nbsp;this&nbsp;is&nbsp;a&nbsp;hard&nbsp;escape</span></span></div></li> <li><div class="src-line"><a name="a2639"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'HARDESCAPE'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$hardescape</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2640"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$string</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$es_pos</span><span class="src-sym">,</span>&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$hardescape</span><span class="src-sym">))</span>&nbsp;==&nbsp;<span class="src-var">$hardescape</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2641"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;indeed,&nbsp;this&nbsp;is&nbsp;a&nbsp;hardescape</span></span></div></li> <li><div class="src-line"><a name="a2642"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$new_string</span>&nbsp;.=&nbsp;<span class="src-str">"</span></span>&lt;span<span class="src-var">$escape_char_attributes</span>&gt;<span class="src-str">&quot;&nbsp;</span><span class="src-str">.</span></div></li> <li><div class="src-line"><a name="a2643"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$hardescape</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2644"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-var">$es_pos</span>&nbsp;+&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$hardescape</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2645"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span>&nbsp;<span class="src-num">2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2646"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2647"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2648"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;not&nbsp;a&nbsp;hard&nbsp;escape,&nbsp;but&nbsp;a&nbsp;normal&nbsp;escape</span></span></div></li> <li><div class="src-line"><a name="a2649"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;they&nbsp;come&nbsp;in&nbsp;pairs&nbsp;of&nbsp;two</span></span></div></li> <li><div class="src-line"><a name="a2650"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$c</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2651"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">while</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$string</span><span class="src-sym">[</span><span class="src-var">$es_pos</span>&nbsp;+&nbsp;<span class="src-var">$c</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;&amp;&amp;&nbsp;isset<span class="src-sym">(</span><span class="src-var">$string</span><span class="src-sym">[</span><span class="src-var">$es_pos</span>&nbsp;+&nbsp;<span class="src-var">$c</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">)</span></span></div></li> <li><div class="src-line"><a name="a2652"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&amp;&amp;&nbsp;<span class="src-var">$string</span><span class="src-sym">[</span><span class="src-var">$es_pos</span>&nbsp;+&nbsp;<span class="src-var">$c</span><span class="src-sym">]</span>&nbsp;==&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span></span></div></li> <li><div class="src-line"><a name="a2653"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&amp;&amp;&nbsp;<span class="src-var">$string</span><span class="src-sym">[</span><span class="src-var">$es_pos</span>&nbsp;+&nbsp;<span class="src-var">$c</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">]</span>&nbsp;==&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2654"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$c</span>&nbsp;+=&nbsp;<span class="src-num">2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2655"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2656"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$c</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2657"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$new_string</span>&nbsp;.=&nbsp;<span class="src-str">"</span></span>&lt;span<span class="src-var">$escape_char_attributes</span>&gt;<span class="src-str">&quot;&nbsp;</span><span class="src-str">.</span></div></li> <li><div class="src-line"><a name="a2658"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">str_repeat</span><span class="src-sym">(</span><span class="src-var">$escaped_escape_char</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$c</span><span class="src-sym">)</span>&nbsp;.</span></div></li> <li><div class="src-line"><a name="a2659"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2660"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-var">$es_pos</span>&nbsp;+&nbsp;<span class="src-var">$c</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2661"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2662"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;this&nbsp;is&nbsp;just&nbsp;a&nbsp;single&nbsp;lonely&nbsp;escape&nbsp;char...</span></span></div></li> <li><div class="src-line"><a name="a2663"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$new_string</span>&nbsp;.=&nbsp;<span class="src-var">$escaped_escape_char</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2664"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-var">$es_pos</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2665"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2666"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2667"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;=&nbsp;<span class="src-var">$new_string</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$string</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2668"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2669"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$string</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2670"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2671"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2672"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$check_linenumbers</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2673"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Are&nbsp;line&nbsp;numbers&nbsp;used?&nbsp;If,&nbsp;we&nbsp;should&nbsp;end&nbsp;the&nbsp;string&nbsp;before</span></span></div></li> <li><div class="src-line"><a name="a2674"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;the&nbsp;newline&nbsp;and&nbsp;begin&nbsp;it&nbsp;again&nbsp;(so&nbsp;when&nbsp;&lt;li&gt;s&nbsp;are&nbsp;put&nbsp;in&nbsp;the&nbsp;source</span></span></div></li> <li><div class="src-line"><a name="a2675"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;remains&nbsp;XHTML&nbsp;compliant)</span></span></div></li> <li><div class="src-line"><a name="a2676"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;note&nbsp;to&nbsp;self:&nbsp;This&nbsp;opens&nbsp;up&nbsp;possibility&nbsp;of&nbsp;config&nbsp;files&nbsp;specifying</span></span></div></li> <li><div class="src-line"><a name="a2677"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;that&nbsp;languages&nbsp;can/cannot&nbsp;have&nbsp;multiline&nbsp;strings???</span></span></div></li> <li><div class="src-line"><a name="a2678"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">"</span></span>&lt;/span&gt;\n&lt;span<span class="src-var">$string_attributes</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span>&nbsp;<span class="src-var">$string</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2679"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2680"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2681"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;.=&nbsp;</span><span class="src-str">&quot;</span>&lt;span<span class="src-var">$string_attributes</span>&gt;<span class="src-str">&quot;&nbsp;</span><span class="src-str">.&nbsp;<span class="src-var">$string</span>&nbsp;.&nbsp;<span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2682"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$string</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2683"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2684"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2685"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Have&nbsp;a&nbsp;look&nbsp;for&nbsp;regexp&nbsp;comments</span></span></div></li> <li><div class="src-line"><a name="a2686"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;==&nbsp;<span class="src-var">$next_comment_regexp_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2687"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$COMMENT_MATCHED</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2688"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment</span>&nbsp;=&nbsp;<span class="src-var">$comment_regexp_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$next_comment_regexp_key</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2689"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$comment</span><span class="src-sym">[</span><span class="src-str">'length'</span><span class="src-sym">]</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2690"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2691"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//@todo&nbsp;If&nbsp;remove&nbsp;important&nbsp;do&nbsp;remove&nbsp;here</span></span></div></li> <li><div class="src-line"><a name="a2692"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'MULTI'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2693"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2694"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$comment</span><span class="src-sym">[</span><span class="src-str">'key'</span><span class="src-sym">]]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2695"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2696"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;co'</span>&nbsp;.&nbsp;<span class="src-var">$comment</span><span class="src-sym">[</span><span class="src-str">'key'</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2697"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2698"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2699"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;=&nbsp;<span class="src-str">"</span></span>&lt;span<span class="src-var">$attributes</span>&gt;<span class="src-str">&quot;&nbsp;</span><span class="src-str">.&nbsp;<span class="src-var">$test_str</span>&nbsp;.&nbsp;<span class="src-str">&quot;&lt;/span&gt;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2700"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2701"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Short-cut&nbsp;through&nbsp;all&nbsp;the&nbsp;multiline&nbsp;code</span></span></div></li> <li><div class="src-line"><a name="a2702"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$check_linenumbers</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2703"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;strreplace&nbsp;to&nbsp;put&nbsp;close&nbsp;span&nbsp;and&nbsp;open&nbsp;span&nbsp;around&nbsp;multiline&nbsp;newlines</span></span></div></li> <li><div class="src-line"><a name="a2704"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2705"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">"</span></span>&lt;/span&gt;\n&lt;span<span class="src-var">$attributes</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2706"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">str_replace</span><span class="src-sym">(</span><span class="src-str">&quot;\n&nbsp;&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">&quot;\n&amp;nbsp;&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$test_str</span><span class="src-sym">)</span></span></div></li> <li><div class="src-line"><a name="a2707"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2708"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2709"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2710"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2711"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;+=&nbsp;<span class="src-var">$comment</span><span class="src-sym">[</span><span class="src-str">'length'</span><span class="src-sym">]</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2712"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2713"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;parse&nbsp;the&nbsp;rest</span></span></div></li> <li><div class="src-line"><a name="a2714"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">parse_non_string_part</span><span class="src-sym">(</span><span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2715"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2716"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2717"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2718"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;If&nbsp;we&nbsp;haven't&nbsp;matched&nbsp;a&nbsp;regexp&nbsp;comment,&nbsp;try&nbsp;multi-line&nbsp;comments</span></span></div></li> <li><div class="src-line"><a name="a2719"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$COMMENT_MATCHED</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2720"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Is&nbsp;this&nbsp;a&nbsp;multiline&nbsp;comment?</span></span></div></li> <li><div class="src-line"><a name="a2721"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'COMMENT_MULTI'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$next_comment_multi_pos</span>&nbsp;<&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2722"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_multi_pos</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2723"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'COMMENT_MULTI'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$open</span>&nbsp;=&gt;&nbsp;<span class="src-var">$close</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2724"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$match_i</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2725"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$comment_multi_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2726"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-var">$comment_multi_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span>&nbsp;&gt;=&nbsp;<span class="src-var">$i</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2727"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_multi_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2728"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;we&nbsp;have&nbsp;already&nbsp;matched&nbsp;something</span></span></div></li> <li><div class="src-line"><a name="a2729"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$comment_multi_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2730"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;this&nbsp;comment&nbsp;is&nbsp;never&nbsp;matched</span></span></div></li> <li><div class="src-line"><a name="a2731"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2732"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2733"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$match_i</span>&nbsp;=&nbsp;<span class="src-var">$comment_multi_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2734"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">((</span><span class="src-var">$match_i</span>&nbsp;=&nbsp;<a href="http://www.php.net/stripos">stripos</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$open</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">))</span>&nbsp;!==&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2735"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_multi_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$match_i</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2736"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2737"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_multi_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2738"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2739"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2740"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$match_i</span>&nbsp;!==&nbsp;<span class="src-id">false</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$match_i</span>&nbsp;<&nbsp;<span class="src-var">$next_comment_multi_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2741"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_multi_pos</span>&nbsp;=&nbsp;<span class="src-var">$match_i</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2742"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_open_comment_multi</span>&nbsp;=&nbsp;<span class="src-var">$open</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2743"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$match_i</span>&nbsp;===&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2744"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2745"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2746"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2747"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2748"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2749"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;==&nbsp;<span class="src-var">$next_comment_multi_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2750"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$open</span>&nbsp;=&nbsp;<span class="src-var">$next_open_comment_multi</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2751"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'COMMENT_MULTI'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$open</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2752"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$open_strlen</span>&nbsp;=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$open</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2753"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close_strlen</span>&nbsp;=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$close</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2754"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$COMMENT_MATCHED</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2755"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str_match</span>&nbsp;=&nbsp;<span class="src-var">$open</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2756"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//@todo&nbsp;If&nbsp;remove&nbsp;important&nbsp;do&nbsp;remove&nbsp;here</span></span></div></li> <li><div class="src-line"><a name="a2757"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'MULTI'</span><span class="src-sym">]</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2758"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$open</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_START_IMPORTANT&quot;&gt;GESHI_START_IMPORTANT&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2759"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$open</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_START_IMPORTANT&quot;&gt;GESHI_START_IMPORTANT&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2760"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2761"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'MULTI'</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2762"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2763"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;coMULTI&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2764"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2765"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;=&nbsp;<span class="src-str">"</span></span>&lt;span<span class="src-var">$attributes</span>&gt;<span class="src-str">&quot;&nbsp;</span><span class="src-str">.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$open</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2766"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2767"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2768"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">important_styles</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2769"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2770"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;imp&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2771"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2772"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2773"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;We&nbsp;don't&nbsp;include&nbsp;the&nbsp;start&nbsp;of&nbsp;the&nbsp;comment&nbsp;if&nbsp;it's&nbsp;an</span></span></div></li> <li><div class="src-line"><a name="a2774"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;&quot;important&quot;&nbsp;part</span></span></div></li> <li><div class="src-line"><a name="a2775"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;=&nbsp;<span class="src-str">"</span></span>&lt;span<span class="src-var">$attributes</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2776"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2777"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2778"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$open</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2779"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2780"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2781"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close_pos</span>&nbsp;=&nbsp;<span class="src-id">strpos</span><span class="src-sym">(</span>&nbsp;<span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$close</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-var">$open_strlen</span>&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2782"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2783"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$close_pos</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2784"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close_pos</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2785"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2786"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2787"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Short-cut&nbsp;through&nbsp;all&nbsp;the&nbsp;multiline&nbsp;code</span></span></div></li> <li><div class="src-line"><a name="a2788"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$rest_of_comment</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-id">substr</span><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-var">$open_strlen</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$close_pos</span>&nbsp;-&nbsp;<span class="src-var">$i</span>&nbsp;-&nbsp;<span class="src-var">$open_strlen</span>&nbsp;+&nbsp;<span class="src-var">$close_strlen</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2789"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">((</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'MULTI'</span><span class="src-sym">]</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2790"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str_match</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_START_IMPORTANT&quot;&gt;GESHI_START_IMPORTANT&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2791"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$check_linenumbers</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2792"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2793"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;strreplace&nbsp;to&nbsp;put&nbsp;close&nbsp;span&nbsp;and&nbsp;open&nbsp;span&nbsp;around&nbsp;multiline&nbsp;newlines</span></span></div></li> <li><div class="src-line"><a name="a2794"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;.=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2795"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">"</span></span>&lt;/span&gt;\n&lt;span<span class="src-var">$attributes</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a2796"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-id">str_replace</span><span class="src-sym">(</span><span class="src-str">&quot;\n&nbsp;&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">&quot;\n&amp;nbsp;&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$rest_of_comment</span><span class="src-sym">)</span></span></div></li> <li><div class="src-line"><a name="a2797"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2798"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2799"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;.=&nbsp;<span class="src-var">$rest_of_comment</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2800"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2801"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2802"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'MULTI'</span><span class="src-sym">]</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2803"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str_match</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_START_IMPORTANT&quot;&gt;GESHI_START_IMPORTANT&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2804"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2805"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2806"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2807"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-var">$close_pos</span>&nbsp;+&nbsp;<span class="src-var">$close_strlen</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2808"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2809"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;parse&nbsp;the&nbsp;rest</span></span></div></li> <li><div class="src-line"><a name="a2810"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">parse_non_string_part</span><span class="src-sym">(</span><span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2811"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2812"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2813"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2814"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2815"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;If&nbsp;we&nbsp;haven't&nbsp;matched&nbsp;a&nbsp;multiline&nbsp;comment,&nbsp;try&nbsp;single-line&nbsp;comments</span></span></div></li> <li><div class="src-line"><a name="a2816"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$COMMENT_MATCHED</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2817"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;cache&nbsp;potential&nbsp;single&nbsp;line&nbsp;comment&nbsp;occurances</span></span></div></li> <li><div class="src-line"><a name="a2818"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'COMMENT_SINGLE'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$next_comment_single_pos</span>&nbsp;<&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2819"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_single_pos</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2820"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'COMMENT_SINGLE'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$comment_key</span>&nbsp;=&gt;&nbsp;<span class="src-var">$comment_mark</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2821"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$match_i</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2822"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$comment_single_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2823"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-var">$comment_single_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span>&nbsp;&gt;=&nbsp;<span class="src-var">$i</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2824"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_single_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2825"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;we&nbsp;have&nbsp;already&nbsp;matched&nbsp;something</span></span></div></li> <li><div class="src-line"><a name="a2826"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$comment_single_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2827"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;this&nbsp;comment&nbsp;is&nbsp;never&nbsp;matched</span></span></div></li> <li><div class="src-line"><a name="a2828"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2829"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2830"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$match_i</span>&nbsp;=&nbsp;<span class="src-var">$comment_single_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2831"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a2832"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;case&nbsp;sensitive&nbsp;comments</span></span></div></li> <li><div class="src-line"><a name="a2833"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'CASE_SENSITIVE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-id">GESHI_COMMENTS</span><span class="src-sym">]</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2834"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-var">$match_i</span>&nbsp;=&nbsp;<a href="http://www.php.net/stripos">stripos</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$comment_mark</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">))</span>&nbsp;!==&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2835"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;non&nbsp;case&nbsp;sensitive</span></span></div></li> <li><div class="src-line"><a name="a2836"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'CASE_SENSITIVE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-id">GESHI_COMMENTS</span><span class="src-sym">]</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2837"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">((</span><span class="src-var">$match_i</span>&nbsp;=&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$comment_mark</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">))</span>&nbsp;!==&nbsp;<span class="src-id">false</span><span class="src-sym">)))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2838"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_single_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$match_i</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2839"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2840"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_single_cache_per_key</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2841"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2842"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2843"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$match_i</span>&nbsp;!==&nbsp;<span class="src-id">false</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$match_i</span>&nbsp;<&nbsp;<span class="src-var">$next_comment_single_pos</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2844"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_single_pos</span>&nbsp;=&nbsp;<span class="src-var">$match_i</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2845"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$next_comment_single_key</span>&nbsp;=&nbsp;<span class="src-var">$comment_key</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2846"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$match_i</span>&nbsp;===&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2847"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2848"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2849"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2850"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2851"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2852"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$next_comment_single_pos</span>&nbsp;==&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2853"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_key</span>&nbsp;=&nbsp;<span class="src-var">$next_comment_single_key</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2854"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$comment_mark</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'COMMENT_SINGLE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2855"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$com_len</span>&nbsp;=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$comment_mark</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2856"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2857"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;This&nbsp;check&nbsp;will&nbsp;find&nbsp;special&nbsp;variables&nbsp;like&nbsp;$#&nbsp;in&nbsp;bash</span></span></div></li> <li><div class="src-line"><a name="a2858"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;or&nbsp;compiler&nbsp;directives&nbsp;of&nbsp;Delphi&nbsp;beginning&nbsp;{$</span></span></div></li> <li><div class="src-line"><a name="a2859"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">((</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$sc_disallowed_before</span><span class="src-sym">)</span>&nbsp;||&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;==&nbsp;<span class="src-num">0</span><span class="src-sym">)</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2860"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-id">false</span>&nbsp;===&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$sc_disallowed_before</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$part</span><span class="src-sym">[</span><span class="src-var">$i</span>-<span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">)))</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a2861"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$sc_disallowed_after</span><span class="src-sym">)</span>&nbsp;||&nbsp;<span class="src-sym">(</span><span class="src-var">$length</span>&nbsp;&lt;=&nbsp;<span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-var">$com_len</span><span class="src-sym">)</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a2862"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-id">false</span>&nbsp;===&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$sc_disallowed_after</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$part</span><span class="src-sym">[</span><span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-var">$com_len</span><span class="src-sym">]</span><span class="src-sym">))))</span></span></div></li> <li><div class="src-line"><a name="a2863"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2864"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;this&nbsp;is&nbsp;a&nbsp;valid&nbsp;comment</span></span></div></li> <li><div class="src-line"><a name="a2865"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$COMMENT_MATCHED</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2866"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2867"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2868"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2869"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2870"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;co'</span>&nbsp;.&nbsp;<span class="src-var">$comment_key</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2871"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2872"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;=&nbsp;<span class="src-str">"</span></span>&lt;span<span class="src-var">$attributes</span>&gt;<span class="src-str">&quot;&nbsp;</span><span class="src-str">.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">change_case</span><span class="src-sym">(</span><span class="src-var">$comment_mark</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2873"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2874"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$comment_mark</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2875"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2876"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2877"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;this&nbsp;comment&nbsp;is&nbsp;the&nbsp;last&nbsp;in&nbsp;the&nbsp;source</span></span></div></li> <li><div class="src-line"><a name="a2878"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close_pos</span>&nbsp;=&nbsp;<span class="src-id">strpos</span><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2879"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$oops</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2880"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$close_pos</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2881"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close_pos</span>&nbsp;=&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2882"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$oops</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2883"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2884"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-var">$com_len</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$close_pos</span>&nbsp;-&nbsp;<span class="src-var">$i</span>&nbsp;-&nbsp;<span class="src-var">$com_len</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2885"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$comment_key</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2886"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;.=&nbsp;<span class="src-str">&quot;&lt;/span&gt;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2887"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2888"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2889"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Take&nbsp;into&nbsp;account&nbsp;that&nbsp;the&nbsp;comment&nbsp;might&nbsp;be&nbsp;the&nbsp;last&nbsp;in&nbsp;the&nbsp;source</span></span></div></li> <li><div class="src-line"><a name="a2890"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$oops</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2891"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$test_str</span>&nbsp;.=&nbsp;<span class="src-str">&quot;\n&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2892"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2893"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2894"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-var">$close_pos</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2895"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2896"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;parse&nbsp;the&nbsp;rest</span></span></div></li> <li><div class="src-line"><a name="a2897"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">parse_non_string_part</span><span class="src-sym">(</span><span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2898"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2899"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2900"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2901"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2902"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2903"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2904"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Where&nbsp;are&nbsp;we&nbsp;adding&nbsp;this&nbsp;char?</span></span></div></li> <li><div class="src-line"><a name="a2905"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$COMMENT_MATCHED</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2906"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;.=&nbsp;<span class="src-var">$char</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2907"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2908"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;.=&nbsp;<span class="src-var">$test_str</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2909"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$test_str</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2910"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$COMMENT_MATCHED</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2911"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2912"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2913"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Parse&nbsp;the&nbsp;last&nbsp;bit</span></span></div></li> <li><div class="src-line"><a name="a2914"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">parse_non_string_part</span><span class="src-sym">(</span><span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2915"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2916"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2917"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2918"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2919"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Close&nbsp;the&nbsp;&lt;span&gt;&nbsp;that&nbsp;surrounds&nbsp;the&nbsp;block</span></span></div></li> <li><div class="src-line"><a name="a2920"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$STRICTATTRS</span>&nbsp;!=&nbsp;<span class="src-str">''</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2921"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">"</span></span>&lt;/span&gt;\n&lt;span<span class="src-var">$STRICTATTRS</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span>&nbsp;<span class="src-var">$result</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2922"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2923"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2924"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2925"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$endresult</span>&nbsp;.=&nbsp;<span class="src-var">$result</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2926"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$part</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$parts</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$result</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2927"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2928"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2929"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//This&nbsp;fix&nbsp;is&nbsp;related&nbsp;to&nbsp;SF#1923020,&nbsp;but&nbsp;has&nbsp;to&nbsp;be&nbsp;applied&nbsp;regardless&nbsp;of</span></span></div></li> <li><div class="src-line"><a name="a2930"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//actually&nbsp;highlighting&nbsp;symbols.</span></span></div></li> <li><div class="src-line"><a name="a2931"></a><span class="src-doc">/**&nbsp;NOTE:&nbsp;memorypeak&nbsp;#3&nbsp;*/</span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a2932"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$endresult</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'&lt;SEMI&gt;'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&lt;PIPE&gt;'</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">';'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'|'</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$endresult</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2933"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2934"></a></span><span class="src-str"><span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//&nbsp;Parse&nbsp;the&nbsp;last&nbsp;stuff&nbsp;(redundant?)</span></span></div></li> <li><div class="src-line"><a name="a2935"></a></span><span class="src-str"><span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$result&nbsp;.=&nbsp;$this-&gt;parse_non_string_part($stuff_to_parse);</span></span></div></li> <li><div class="src-line"><a name="a2936"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a2937"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Lop&nbsp;off&nbsp;the&nbsp;very&nbsp;first&nbsp;and&nbsp;last&nbsp;spaces</span></span></div></li> <li><div class="src-line"><a name="a2938"></a></span><span class="src-str"><span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$result&nbsp;=&nbsp;substr($result,&nbsp;1,&nbsp;-1);</span></span></div></li> <li><div class="src-line"><a name="a2939"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a2940"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;We're&nbsp;finished:&nbsp;stop&nbsp;timing</span></span></div></li> <li><div class="src-line"><a name="a2941"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">set_time</span><span class="src-sym">(</span><span class="src-var">$start_time</span><span class="src-sym">,</span>&nbsp;<a href="http://www.php.net/microtime">microtime</a><span class="src-sym">(</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2942"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2943"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">finalise</span><span class="src-sym">(</span><span class="src-var">$endresult</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2944"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$endresult</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2945"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2946"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2947"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a2948"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Swaps&nbsp;out&nbsp;spaces&nbsp;and&nbsp;tabs&nbsp;for&nbsp;HTML&nbsp;indentation.&nbsp;Not&nbsp;needed&nbsp;if</span></div></li> <li><div class="src-line"><a name="a2949"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;the&nbsp;code&nbsp;is&nbsp;in&nbsp;a&nbsp;pre&nbsp;block...</span></div></li> <li><div class="src-line"><a name="a2950"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a2951"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc">&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;source&nbsp;to&nbsp;indent&nbsp;(reference!)</span></div></li> <li><div class="src-line"><a name="a2952"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a2953"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@access</span><span class="src-doc">&nbsp;private</span></div></li> <li><div class="src-line"><a name="a2954"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a2955"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">indent</span><span class="src-sym">(</span><span class="src-sym">&</span><span class="src-var">$result</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2956"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">///&nbsp;Replace&nbsp;tabs&nbsp;with&nbsp;the&nbsp;correct&nbsp;number&nbsp;of&nbsp;spaces</span></span></div></li> <li><div class="src-line"><a name="a2957"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">false</span>&nbsp;!==&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$result</span><span class="src-sym">,</span>&nbsp;<span class="src-str">&quot;\t&quot;</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2958"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$lines</span>&nbsp;=&nbsp;<a href="http://www.php.net/explode">explode</a><span class="src-sym">(</span><span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$result</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2959"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;=&nbsp;<span class="src-id">null</span><span class="src-sym">;</span><span class="src-comm">//Save&nbsp;memory&nbsp;while&nbsp;we&nbsp;process&nbsp;the&nbsp;lines&nbsp;individually</span></span></div></li> <li><div class="src-line"><a name="a2960"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$tab_width</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodget_real_tab_width">get_real_tab_width</a><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2961"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$tab_string</span>&nbsp;=&nbsp;<span class="src-str">'&amp;nbsp;'</span>&nbsp;.&nbsp;<a href="http://www.php.net/str_repeat">str_repeat</a><span class="src-sym">(</span><span class="src-str">'&nbsp;'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$tab_width</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2962"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2963"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$key</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$n</span>&nbsp;=&nbsp;<a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$lines</span><span class="src-sym">)</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$key</span>&nbsp;<&nbsp;<span class="src-var">$n</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$key</span>++<span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2964"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$line</span>&nbsp;=&nbsp;<span class="src-var">$lines</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2965"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">false</span>&nbsp;===&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$line</span><span class="src-sym">,</span>&nbsp;<span class="src-str">&quot;\t&quot;</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2966"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2967"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2968"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a2969"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$pos</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2970"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$length</span>&nbsp;=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$line</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2971"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$lines</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span>&nbsp;<span class="src-comm">//&nbsp;reduce&nbsp;memory</span></span></div></li> <li><div class="src-line"><a name="a2972"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a2973"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$IN_TAG</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2974"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$i</span>&nbsp;<&nbsp;<span class="src-var">$length</span><span class="src-sym">;</span>&nbsp;++<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2975"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$char</span>&nbsp;=&nbsp;<span class="src-var">$line</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2976"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Simple&nbsp;engine&nbsp;to&nbsp;work&nbsp;out&nbsp;whether&nbsp;we're&nbsp;in&nbsp;a&nbsp;tag.</span></span></div></li> <li><div class="src-line"><a name="a2977"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;If&nbsp;we&nbsp;are&nbsp;we&nbsp;modify&nbsp;$pos.&nbsp;This&nbsp;is&nbsp;so&nbsp;we&nbsp;ignore&nbsp;HTML</span></span></div></li> <li><div class="src-line"><a name="a2978"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;in&nbsp;the&nbsp;line&nbsp;and&nbsp;only&nbsp;workout&nbsp;the&nbsp;tab&nbsp;replacement</span></span></div></li> <li><div class="src-line"><a name="a2979"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;via&nbsp;the&nbsp;actual&nbsp;content&nbsp;of&nbsp;the&nbsp;string</span></span></div></li> <li><div class="src-line"><a name="a2980"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;This&nbsp;test&nbsp;could&nbsp;be&nbsp;improved&nbsp;to&nbsp;include&nbsp;strings&nbsp;in&nbsp;the</span></span></div></li> <li><div class="src-line"><a name="a2981"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;html&nbsp;so&nbsp;that&nbsp;&lt;&nbsp;or&nbsp;&gt;&nbsp;would&nbsp;be&nbsp;allowed&nbsp;in&nbsp;user's&nbsp;styles</span></span></div></li> <li><div class="src-line"><a name="a2982"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;(e.g.&nbsp;quotes:&nbsp;'&lt;'&nbsp;'&gt;';&nbsp;or&nbsp;similar)</span></span></div></li> <li><div class="src-line"><a name="a2983"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$IN_TAG</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2984"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-str">'&gt;'</span>&nbsp;==&nbsp;<span class="src-var">$char</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2985"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$IN_TAG</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2986"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2987"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$lines</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$char</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2988"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-str">'&lt;'</span>&nbsp;==&nbsp;<span class="src-var">$char</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2989"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$IN_TAG</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2990"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$lines</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2991"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-str">'&amp;'</span>&nbsp;==&nbsp;<span class="src-var">$char</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2992"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$substr</span>&nbsp;=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$line</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-num">3</span><span class="src-sym">,</span>&nbsp;<span class="src-num">5</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2993"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$posi</span>&nbsp;=&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$substr</span><span class="src-sym">,</span>&nbsp;<span class="src-str">';'</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2994"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">false</span>&nbsp;===&nbsp;<span class="src-var">$posi</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2995"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$pos</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2996"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a2997"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$pos</span>&nbsp;-=&nbsp;<span class="src-var">$posi</span>+<span class="src-num">2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a2998"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a2999"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$lines</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$char</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3000"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-str">&quot;\t&quot;</span>&nbsp;==&nbsp;<span class="src-var">$char</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3001"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$str</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3002"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;OPTIMISE&nbsp;-&nbsp;move&nbsp;$strs&nbsp;out.&nbsp;Make&nbsp;an&nbsp;array:</span></span></div></li> <li><div class="src-line"><a name="a3003"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;$tabs&nbsp;=&nbsp;array(</span></span></div></li> <li><div class="src-line"><a name="a3004"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;&nbsp;1&nbsp;=&gt;&nbsp;'&amp;nbsp;',</span></span></div></li> <li><div class="src-line"><a name="a3005"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;&nbsp;2&nbsp;=&gt;&nbsp;'&amp;nbsp;&nbsp;',</span></span></div></li> <li><div class="src-line"><a name="a3006"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;&nbsp;3&nbsp;=&gt;&nbsp;'&amp;nbsp;&nbsp;&amp;nbsp;'&nbsp;etc&nbsp;etc</span></span></div></li> <li><div class="src-line"><a name="a3007"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;to&nbsp;use&nbsp;instead&nbsp;of&nbsp;building&nbsp;a&nbsp;string&nbsp;every&nbsp;time</span></span></div></li> <li><div class="src-line"><a name="a3008"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$tab_end_width</span>&nbsp;=&nbsp;<span class="src-var">$tab_width</span>&nbsp;-&nbsp;<span class="src-sym">(</span><span class="src-var">$pos</span>&nbsp;%&nbsp;<span class="src-var">$tab_width</span><span class="src-sym">)</span><span class="src-sym">;</span>&nbsp;<span class="src-comm">//Moved&nbsp;out&nbsp;of&nbsp;the&nbsp;look&nbsp;as&nbsp;it&nbsp;doesn't&nbsp;change&nbsp;within&nbsp;the&nbsp;loop</span></span></div></li> <li><div class="src-line"><a name="a3009"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">((</span><span class="src-var">$pos</span>&nbsp;<span class="src-sym">&</span>&nbsp;<span class="src-num">1</span><span class="src-sym">)</span>&nbsp;||&nbsp;<span class="src-num">1</span>&nbsp;==&nbsp;<span class="src-var">$tab_end_width</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3010"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$str</span>&nbsp;.=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$tab_string</span><span class="src-sym">,</span>&nbsp;<span class="src-num">6</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$tab_end_width</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3011"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3012"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$str</span>&nbsp;.=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$tab_string</span><span class="src-sym">,</span>&nbsp;<span class="src-num">0</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$tab_end_width</span>+<span class="src-num">5</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3013"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3014"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$lines</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$str</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3015"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$pos</span>&nbsp;+=&nbsp;<span class="src-var">$tab_end_width</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3016"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3017"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">false</span>&nbsp;===&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$line</span><span class="src-sym">,</span>&nbsp;<span class="src-str">&quot;\t&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3018"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$lines</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$line</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3019"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3020"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3021"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-num">0</span>&nbsp;==&nbsp;<span class="src-var">$pos</span>&nbsp;&amp;&amp;&nbsp;<span class="src-str">'&nbsp;'</span>&nbsp;==&nbsp;<span class="src-var">$char</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3022"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$lines</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-str">'&amp;nbsp;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3023"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$pos</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3024"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3025"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$lines</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.=&nbsp;<span class="src-var">$char</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3026"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$pos</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3027"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3028"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3029"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3030"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;=&nbsp;<a href="http://www.php.net/implode">implode</a><span class="src-sym">(</span><span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$lines</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3031"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$lines</span><span class="src-sym">)</span><span class="src-sym">;</span><span class="src-comm">//We&nbsp;don't&nbsp;need&nbsp;the&nbsp;lines&nbsp;separated&nbsp;beyond&nbsp;this&nbsp;---&nbsp;free&nbsp;them!</span></span></div></li> <li><div class="src-line"><a name="a3032"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3033"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Other&nbsp;whitespace</span></span></div></li> <li><div class="src-line"><a name="a3034"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;BenBE:&nbsp;Fix&nbsp;to&nbsp;reduce&nbsp;the&nbsp;number&nbsp;of&nbsp;replacements&nbsp;to&nbsp;be&nbsp;done</span></span></div></li> <li><div class="src-line"><a name="a3035"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_replace">preg_replace</a><span class="src-sym">(</span><span class="src-str">'/^&nbsp;/m'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&amp;nbsp;'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$result</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3036"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">'&nbsp;&nbsp;'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&nbsp;&amp;nbsp;'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$result</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3037"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3038"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS&quot;&gt;GESHI_NO_LINE_NUMBERS&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3039"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_ending</span>&nbsp;===&nbsp;<span class="src-id">null</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3040"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;=&nbsp;<a href="http://www.php.net/nl2br">nl2br</a><span class="src-sym">(</span><span class="src-var">$result</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3041"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3042"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$result</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_ending</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$result</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3043"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3044"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3045"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3046"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3047"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a3048"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Changes&nbsp;the&nbsp;case&nbsp;of&nbsp;a&nbsp;keyword&nbsp;for&nbsp;those&nbsp;languages&nbsp;where&nbsp;a&nbsp;change&nbsp;is&nbsp;asked&nbsp;for</span></div></li> <li><div class="src-line"><a name="a3049"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3050"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc">&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;keyword&nbsp;to&nbsp;change&nbsp;the&nbsp;case&nbsp;of</span></div></li> <li><div class="src-line"><a name="a3051"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@return&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;keyword&nbsp;with&nbsp;its&nbsp;case&nbsp;changed</span></div></li> <li><div class="src-line"><a name="a3052"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a3053"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@access</span><span class="src-doc">&nbsp;private</span></div></li> <li><div class="src-line"><a name="a3054"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a3055"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">change_case</span><span class="src-sym">(</span><span class="src-var">$instr</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3056"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">switch</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'CASE_KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3057"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">case</span>&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_CAPS_UPPER&quot;&gt;GESHI_CAPS_UPPER&lt;/a&gt;</span>:</span></div></li> <li><div class="src-line"><a name="a3058"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<a href="http://www.php.net/strtoupper">strtoupper</a><span class="src-sym">(</span><span class="src-var">$instr</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3059"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">case</span>&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_CAPS_LOWER&quot;&gt;GESHI_CAPS_LOWER&lt;/a&gt;</span>:</span></div></li> <li><div class="src-line"><a name="a3060"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<a href="http://www.php.net/strtolower">strtolower</a><span class="src-sym">(</span><span class="src-var">$instr</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3061"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">default</span>:</span></div></li> <li><div class="src-line"><a name="a3062"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$instr</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3063"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3064"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3065"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3066"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a3067"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Handles&nbsp;replacements&nbsp;of&nbsp;keywords&nbsp;to&nbsp;include&nbsp;markup&nbsp;and&nbsp;links&nbsp;if&nbsp;requested</span></div></li> <li><div class="src-line"><a name="a3068"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3069"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc">&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;keyword&nbsp;to&nbsp;add&nbsp;the&nbsp;Markup&nbsp;to</span></div></li> <li><div class="src-line"><a name="a3070"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@return&nbsp;</span><span class="src-doc-type">The&nbsp;</span><span class="src-doc">HTML&nbsp;for&nbsp;the&nbsp;match&nbsp;found</span></div></li> <li><div class="src-line"><a name="a3071"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;&nbsp;1.0.8</span></div></li> <li><div class="src-line"><a name="a3072"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@access</span><span class="src-doc">&nbsp;private</span></div></li> <li><div class="src-line"><a name="a3073"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3074"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@todo</span><span class="src-doc">&nbsp;&nbsp;&nbsp;Get&nbsp;rid&nbsp;of&nbsp;ender&nbsp;in&nbsp;keyword&nbsp;links</span></div></li> <li><div class="src-line"><a name="a3075"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a3076"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">handle_keyword_replace</span><span class="src-sym">(</span><span class="src-var">$match</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3077"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$k</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_kw_replace_group</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3078"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$keyword</span>&nbsp;=&nbsp;<span class="src-var">$match</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3079"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3080"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$before</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3081"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$after</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3082"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3083"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">keyword_links</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3084"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Keyword&nbsp;links&nbsp;have&nbsp;been&nbsp;ebabled</span></span></div></li> <li><div class="src-line"><a name="a3085"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a3086"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'URLS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a3087"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'URLS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span>&nbsp;!=&nbsp;<span class="src-str">''</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3088"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;There&nbsp;is&nbsp;a&nbsp;base&nbsp;group&nbsp;for&nbsp;this&nbsp;keyword</span></span></div></li> <li><div class="src-line"><a name="a3089"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a3090"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Old&nbsp;system:&nbsp;strtolower</span></span></div></li> <li><div class="src-line"><a name="a3091"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//$keyword&nbsp;=&nbsp;(&nbsp;$this-&gt;language_data['CASE_SENSITIVE'][$group]&nbsp;)&nbsp;?&nbsp;$keyword&nbsp;:&nbsp;strtolower($keyword);</span></span></div></li> <li><div class="src-line"><a name="a3092"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;New&nbsp;system:&nbsp;get&nbsp;keyword&nbsp;from&nbsp;language&nbsp;file&nbsp;to&nbsp;get&nbsp;correct&nbsp;case</span></span></div></li> <li><div class="src-line"><a name="a3093"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'CASE_SENSITIVE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a3094"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'URLS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'{FNAME}'</span><span class="src-sym">)</span>&nbsp;!==&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3095"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$word</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3096"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/strcasecmp">strcasecmp</a><span class="src-sym">(</span><span class="src-var">$word</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$keyword</span><span class="src-sym">)</span>&nbsp;==&nbsp;<span class="src-num">0</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3097"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3098"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3099"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3100"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3101"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$word</span>&nbsp;=&nbsp;<span class="src-var">$keyword</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3102"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3103"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3104"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$before</span>&nbsp;=&nbsp;<span class="src-str">'&lt;|UR1|&quot;'</span>&nbsp;.</span></div></li> <li><div class="src-line"><a name="a3105"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a3106"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a3107"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'{FNAME}'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3108"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'{FNAMEL}'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3109"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'{FNAMEU}'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3110"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'.'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3111"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a3112"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">'+'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'%20'</span><span class="src-sym">,</span>&nbsp;<a href="http://www.php.net/urlencode">urlencode</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$word</span><span class="src-sym">)))</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3113"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">'+'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'%20'</span><span class="src-sym">,</span>&nbsp;<a href="http://www.php.net/urlencode">urlencode</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><a href="http://www.php.net/strtolower">strtolower</a><span class="src-sym">(</span><span class="src-var">$word</span><span class="src-sym">))))</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3114"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">'+'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'%20'</span><span class="src-sym">,</span>&nbsp;<a href="http://www.php.net/urlencode">urlencode</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><a href="http://www.php.net/strtoupper">strtoupper</a><span class="src-sym">(</span><span class="src-var">$word</span><span class="src-sym">))))</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3115"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;DOT&gt;'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3116"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'URLS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span></span></div></li> <li><div class="src-line"><a name="a3117"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3118"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$after</span>&nbsp;=&nbsp;<span class="src-str">'&lt;/a&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3119"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3120"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3121"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3122"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$before</span>&nbsp;.&nbsp;<span class="src-str">'&lt;|/'</span>.&nbsp;<span class="src-var">$k</span>&nbsp;.<span class="src-str">'/&gt;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">change_case</span><span class="src-sym">(</span><span class="src-var">$keyword</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">'|&gt;'</span>&nbsp;.&nbsp;<span class="src-var">$after</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3123"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3124"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3125"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a3126"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;handles&nbsp;regular&nbsp;expressions&nbsp;highlighting-definitions&nbsp;with&nbsp;callback&nbsp;functions</span></div></li> <li><div class="src-line"><a name="a3127"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3128"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-tag">@note</span><span class="src-doc">&nbsp;this&nbsp;is&nbsp;a&nbsp;callback,&nbsp;don't&nbsp;use&nbsp;it&nbsp;directly</span></div></li> <li><div class="src-line"><a name="a3129"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3130"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">array&nbsp;</span><span class="src-doc">the&nbsp;matches&nbsp;array</span></div></li> <li><div class="src-line"><a name="a3131"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@return&nbsp;</span><span class="src-doc-type">The&nbsp;</span><span class="src-doc">highlighted&nbsp;string</span></div></li> <li><div class="src-line"><a name="a3132"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.8</span></div></li> <li><div class="src-line"><a name="a3133"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@access</span><span class="src-doc">&nbsp;private</span></div></li> <li><div class="src-line"><a name="a3134"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a3135"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">handle_regexps_callback</span><span class="src-sym">(</span><span class="src-var">$matches</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3136"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;before:&nbsp;&quot;'&nbsp;style=\&quot;'&nbsp;.&nbsp;call_user_func(\&quot;$func\&quot;,&nbsp;'\\1')&nbsp;.&nbsp;'\&quot;\\1|&gt;'&quot;,</span></span></div></li> <li><div class="src-line"><a name="a3137"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<a href="http://www.php.net/call_user_func">call_user_func</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_rx_key</span><span class="src-sym">]</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span>.&nbsp;<span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'|&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3138"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3139"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3140"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a3141"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;handles&nbsp;newlines&nbsp;in&nbsp;REGEXPS&nbsp;matches.&nbsp;Set&nbsp;the&nbsp;_hmr_*&nbsp;vars&nbsp;before&nbsp;calling&nbsp;this</span></div></li> <li><div class="src-line"><a name="a3142"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3143"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-tag">@note</span><span class="src-doc">&nbsp;this&nbsp;is&nbsp;a&nbsp;callback,&nbsp;don't&nbsp;use&nbsp;it&nbsp;directly</span></div></li> <li><div class="src-line"><a name="a3144"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3145"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">array&nbsp;</span><span class="src-doc">the&nbsp;matches&nbsp;array</span></div></li> <li><div class="src-line"><a name="a3146"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@return&nbsp;</span><span class="src-doc-type">string&nbsp;</span></div></li> <li><div class="src-line"><a name="a3147"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.8</span></div></li> <li><div class="src-line"><a name="a3148"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@access</span><span class="src-doc">&nbsp;private</span></div></li> <li><div class="src-line"><a name="a3149"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a3150"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">handle_multiline_regexps</span><span class="src-sym">(</span><span class="src-var">$matches</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3151"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$before</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_before</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3152"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$after</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_after</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3153"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_replace</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3154"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$replace</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_replace</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3155"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$search</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3156"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3157"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/array_keys">array_keys</a><span class="src-sym">(</span><span class="src-var">$matches</span><span class="src-sym">)</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$k</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3158"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$search</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'\\'</span>&nbsp;.&nbsp;<span class="src-var">$k</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3159"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3160"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3161"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$before</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-var">$search</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$matches</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$before</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3162"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$after</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-var">$search</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$matches</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$after</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3163"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$replace</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-var">$search</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$matches</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$replace</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3164"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3165"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$replace</span>&nbsp;=&nbsp;<span class="src-var">$matches</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3166"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3167"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$before</span></span></div></li> <li><div class="src-line"><a name="a3168"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.&nbsp;<span class="src-str">'&lt;|!REG3XP'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_key</span>&nbsp;.<span class="src-str">'!&gt;'</span></span></div></li> <li><div class="src-line"><a name="a3169"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">&quot;|&gt;\n&lt;|!REG3XP&quot;</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_key</span>&nbsp;.&nbsp;<span class="src-str">'!&gt;'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$replace</span><span class="src-sym">)</span></span></div></li> <li><div class="src-line"><a name="a3170"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.&nbsp;<span class="src-str">'|&gt;'</span></span></div></li> <li><div class="src-line"><a name="a3171"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.&nbsp;<span class="src-var">$after</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3172"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3173"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3174"></a><span class="src-doc">/**</span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;</span></span></div></li> <li><div class="src-line"><a name="a3175"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Takes&nbsp;a&nbsp;string&nbsp;that&nbsp;has&nbsp;no&nbsp;strings&nbsp;or&nbsp;comments&nbsp;in&nbsp;it,&nbsp;and&nbsp;highlights</span></div></li> <li><div class="src-line"><a name="a3176"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;stuff&nbsp;like&nbsp;keywords,&nbsp;numbers&nbsp;and&nbsp;methods.</span></div></li> <li><div class="src-line"><a name="a3177"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3178"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@param&nbsp;</span><span class="src-doc-type">string&nbsp;</span><span class="src-doc">The&nbsp;string&nbsp;to&nbsp;parse&nbsp;for&nbsp;keyword,&nbsp;numbers&nbsp;etc.</span></div></li> <li><div class="src-line"><a name="a3179"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@since</span><span class="src-doc">&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a3180"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@access</span><span class="src-doc">&nbsp;private</span></div></li> <li><div class="src-line"><a name="a3181"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;</span><span class="src-doc-coretag">@todo</span><span class="src-doc">&nbsp;BUGGY!&nbsp;Why?&nbsp;Why&nbsp;not&nbsp;build&nbsp;string&nbsp;and&nbsp;return?</span></div></li> <li><div class="src-line"><a name="a3182"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span><span class="src-str"></span></span></div></li> <li><div class="src-line"><a name="a3183"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">parse_non_string_part</span><span class="src-sym">(</span><span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3184"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3185"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3186"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Regular&nbsp;expressions</span></span></div></li> <li><div class="src-line"><a name="a3187"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span>&nbsp;=&gt;&nbsp;<span class="src-var">$regexp</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3188"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3189"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$regexp</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3190"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS&quot;&gt;GESHI_NO_LINE_NUMBERS&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3191"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;produce&nbsp;valid&nbsp;HTML&nbsp;when&nbsp;we&nbsp;match&nbsp;multiple&nbsp;lines</span></span></div></li> <li><div class="src-line"><a name="a3192"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_replace</span>&nbsp;=&nbsp;<span class="src-var">$regexp</span><span class="src-sym">[</span><span class="src-id">GESHI_REPLACE</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3193"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_before</span>&nbsp;=&nbsp;<span class="src-var">$regexp</span><span class="src-sym">[</span><span class="src-id">GESHI_BEFORE</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3194"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_key</span>&nbsp;=&nbsp;<span class="src-var">$key</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3195"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_after</span>&nbsp;=&nbsp;<span class="src-var">$regexp</span><span class="src-sym">[</span><span class="src-id">GESHI_AFTER</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3196"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_replace_callback">preg_replace_callback</a><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a3197"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;/&quot;</span>&nbsp;.&nbsp;<span class="src-var">$regexp</span><span class="src-sym">[</span><span class="src-id">GESHI_SEARCH</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">"</span></span>/{<span class="src-var">$regexp</span><span class="src-sym">[</span><span class="src-id">GESHI_MODIFIERS</span><span class="src-sym">]</span><span class="src-sym">}</span><span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3198"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'handle_multiline_regexps'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3199"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3200"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_replace</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3201"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_before</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3202"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_after</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3203"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3204"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_replace">preg_replace</a><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a3205"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'/'</span>&nbsp;.&nbsp;<span class="src-var">$regexp</span><span class="src-sym">[</span><span class="src-id">GESHI_SEARCH</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'/'</span>&nbsp;.&nbsp;<span class="src-var">$regexp</span><span class="src-sym">[</span><span class="src-id">GESHI_MODIFIERS</span><span class="src-sym">]</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3206"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$regexp</span><span class="src-sym">[</span><span class="src-id">GESHI_BEFORE</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&lt;|!REG3XP'</span>.&nbsp;<span class="src-var">$key</span>&nbsp;.<span class="src-str">'!&gt;'</span>&nbsp;.&nbsp;<span class="src-var">$regexp</span><span class="src-sym">[</span><span class="src-id">GESHI_REPLACE</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'|&gt;'</span>&nbsp;.&nbsp;<span class="src-var">$regexp</span><span class="src-sym">[</span><span class="src-id">GESHI_AFTER</span><span class="src-sym">]</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3207"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3208"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3209"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3210"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS&quot;&gt;GESHI_NO_LINE_NUMBERS&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3211"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;produce&nbsp;valid&nbsp;HTML&nbsp;when&nbsp;we&nbsp;match&nbsp;multiple&nbsp;lines</span></span></div></li> <li><div class="src-line"><a name="a3212"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_key</span>&nbsp;=&nbsp;<span class="src-var">$key</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3213"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_replace_callback">preg_replace_callback</a><span class="src-sym">(</span>&nbsp;<span class="src-str">&quot;/(&quot;</span>&nbsp;.&nbsp;<span class="src-var">$regexp</span>&nbsp;.&nbsp;<span class="src-str">&quot;)/&quot;</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3214"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'handle_multiline_regexps'</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3215"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_hmr_key</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3216"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3217"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_replace">preg_replace</a><span class="src-sym">(</span>&nbsp;<span class="src-str">&quot;/(&quot;</span>&nbsp;.&nbsp;<span class="src-var">$regexp</span>&nbsp;.&nbsp;<span class="src-str">&quot;)/&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">"</span></span>&lt;|!REG3XP<span class="src-var">$key</span>!&gt;\\1|&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3218"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3219"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3220"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3221"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3222"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3223"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Highlight&nbsp;numbers.&nbsp;As&nbsp;of&nbsp;1.0.8&nbsp;we&nbsp;support&nbsp;diffent&nbsp;types&nbsp;of&nbsp;numbers</span></span></div></li> <li><div class="src-line"><a name="a3224"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$numbers_found</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3225"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span>&nbsp;&amp;&amp;&nbsp;<a href="http://www.php.net/preg_match">preg_match</a><span class="src-sym">(</span><span class="src-str">'#\d#'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;<span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3226"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$numbers_found</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3227"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3228"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//For&nbsp;each&nbsp;of&nbsp;the&nbsp;formats&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3229"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_RXCACHE'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$id</span>&nbsp;=&gt;&nbsp;<span class="src-var">$regexp</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3230"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;it&nbsp;should&nbsp;be&nbsp;highlighted&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3231"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_replace">preg_replace</a><span class="src-sym">(</span><span class="src-var">$regexp</span><span class="src-sym">,</span>&nbsp;<span class="src-str">"</span></span>&lt;|/NUM!<span class="src-var">$id</span>/&gt;\\1|&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3232"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3233"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3234"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3235"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Highlight&nbsp;keywords</span></span></div></li> <li><div class="src-line"><a name="a3236"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$disallowed_before</span>&nbsp;=&nbsp;<span class="src-str">&quot;(?&lt;![a-zA-Z0-9\$_\|\#;&gt;|^&amp;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3237"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$disallowed_after</span>&nbsp;=&nbsp;<span class="src-str">&quot;(?![a-zA-Z0-9_\|%\\-&amp;;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3238"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'STRINGS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3239"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$quotemarks</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_quote">preg_quote</a><span class="src-sym">(</span><a href="http://www.php.net/implode">implode</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'QUOTEMARKS'</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'/'</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3240"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$disallowed_before</span>&nbsp;.=&nbsp;<span class="src-var">$quotemarks</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3241"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$disallowed_after</span>&nbsp;.=&nbsp;<span class="src-var">$quotemarks</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3242"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3243"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$disallowed_before</span>&nbsp;.=&nbsp;<span class="src-str">&quot;])&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3244"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$disallowed_after</span>&nbsp;.=&nbsp;<span class="src-str">&quot;])&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3245"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3246"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parser_control_pergroup</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3247"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3248"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3249"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$x</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span>&nbsp;<span class="src-comm">//&nbsp;check&nbsp;wether&nbsp;per-keyword-group&nbsp;parser_control&nbsp;is&nbsp;enabled</span></span></div></li> <li><div class="src-line"><a name="a3250"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'DISALLOWED_BEFORE'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3251"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$disallowed_before</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'DISALLOWED_BEFORE'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3252"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$x</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3253"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3254"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'DISALLOWED_AFTER'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3255"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$disallowed_after</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'DISALLOWED_AFTER'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3256"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$x</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3257"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3258"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parser_control_pergroup</span>&nbsp;=&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;-&nbsp;<span class="src-var">$x</span><span class="src-sym">)</span>&nbsp;>&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3259"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3260"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3261"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3262"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;if&nbsp;this&nbsp;is&nbsp;changed,&nbsp;don't&nbsp;forget&nbsp;to&nbsp;change&nbsp;it&nbsp;below</span></span></div></li> <li><div class="src-line"><a name="a3263"></a></span><span class="src-str"><span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if&nbsp;(!empty($disallowed_before))&nbsp;{</span></span></div></li> <li><div class="src-line"><a name="a3264"></a></span><span class="src-str"><span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$disallowed_before&nbsp;=&nbsp;&quot;(?&lt;![$disallowed_before])&quot;;</span></span></div></li> <li><div class="src-line"><a name="a3265"></a></span><span class="src-str"><span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span></span></div></li> <li><div class="src-line"><a name="a3266"></a></span><span class="src-str"><span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if&nbsp;(!empty($disallowed_after))&nbsp;{</span></span></div></li> <li><div class="src-line"><a name="a3267"></a></span><span class="src-str"><span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$disallowed_after&nbsp;=&nbsp;&quot;(?![$disallowed_after])&quot;;</span></span></div></li> <li><div class="src-line"><a name="a3268"></a></span><span class="src-str"><span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span></span></div></li> <li><div class="src-line"><a name="a3269"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a3270"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/array_keys">array_keys</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$k</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3271"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a3272"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3273"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3274"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$case_sensitive</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'CASE_SENSITIVE'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3275"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$modifiers</span>&nbsp;=&nbsp;<span class="src-var">$case_sensitive</span>&nbsp;?&nbsp;<span class="src-str">''</span>&nbsp;:&nbsp;<span class="src-str">'i'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3276"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3277"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;NEW&nbsp;in&nbsp;1.0.8&nbsp;-&nbsp;per-keyword-group&nbsp;parser&nbsp;control</span></span></div></li> <li><div class="src-line"><a name="a3278"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$disallowed_before_local</span>&nbsp;=&nbsp;<span class="src-var">$disallowed_before</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3279"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$disallowed_after_local</span>&nbsp;=&nbsp;<span class="src-var">$disallowed_after</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3280"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$parser_control_pergroup</span>&nbsp;&amp;&amp;&nbsp;isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3281"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'DISALLOWED_BEFORE'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3282"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$disallowed_before_local</span>&nbsp;=</span></div></li> <li><div class="src-line"><a name="a3283"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'DISALLOWED_BEFORE'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3284"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3285"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3286"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'DISALLOWED_AFTER'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3287"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$disallowed_after_local</span>&nbsp;=</span></div></li> <li><div class="src-line"><a name="a3288"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'DISALLOWED_AFTER'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3289"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3290"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3291"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3292"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_kw_replace_group</span>&nbsp;=&nbsp;<span class="src-var">$k</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3293"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3294"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//NEW&nbsp;in&nbsp;1.0.8,&nbsp;the&nbsp;cached&nbsp;regexp&nbsp;list</span></span></div></li> <li><div class="src-line"><a name="a3295"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;since&nbsp;we&nbsp;don't&nbsp;want&nbsp;PHP&nbsp;/&nbsp;PCRE&nbsp;to&nbsp;crash&nbsp;due&nbsp;to&nbsp;too&nbsp;large&nbsp;patterns&nbsp;we&nbsp;split&nbsp;them&nbsp;into&nbsp;smaller&nbsp;chunks</span></span></div></li> <li><div class="src-line"><a name="a3296"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$set</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$set_length</span>&nbsp;=&nbsp;<a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'CACHED_KEYWORD_LISTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$set</span>&nbsp;<&nbsp;&nbsp;<span class="src-var">$set_length</span><span class="src-sym">;</span>&nbsp;++<span class="src-var">$set</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3297"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$keywordset</span>&nbsp;=<span class="src-sym">&</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'CACHED_KEYWORD_LISTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$set</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3298"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Might&nbsp;make&nbsp;a&nbsp;more&nbsp;unique&nbsp;string&nbsp;for&nbsp;putting&nbsp;the&nbsp;number&nbsp;in&nbsp;soon</span></span></div></li> <li><div class="src-line"><a name="a3299"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Basically,&nbsp;we&nbsp;don't&nbsp;put&nbsp;the&nbsp;styles&nbsp;in&nbsp;yet&nbsp;because&nbsp;then&nbsp;the&nbsp;styles&nbsp;themselves&nbsp;will</span></span></div></li> <li><div class="src-line"><a name="a3300"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;get&nbsp;highlighted&nbsp;if&nbsp;the&nbsp;language&nbsp;has&nbsp;a&nbsp;CSS&nbsp;keyword&nbsp;in&nbsp;it&nbsp;(like&nbsp;CSS,&nbsp;for&nbsp;example&nbsp;;))</span></span></div></li> <li><div class="src-line"><a name="a3301"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_replace_callback">preg_replace_callback</a><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a3302"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">"</span></span>/<span class="src-var">$disallowed_before_local</span>({<span class="src-var">$keywordset</span><span class="src-sym">}</span>)(?!\&lt;DOT\&gt;(?:htm|php))<span class="src-var">$disallowed_after_local</span>/<span class="src-var">$modifiers</span><span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3303"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'handle_keyword_replace'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3304"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span></span></div></li> <li><div class="src-line"><a name="a3305"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3306"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3307"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3308"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3309"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3310"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//</span></span></div></li> <li><div class="src-line"><a name="a3311"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Now&nbsp;that's&nbsp;all&nbsp;done,&nbsp;replace&nbsp;/[number]/&nbsp;with&nbsp;the&nbsp;correct&nbsp;styles</span></span></div></li> <li><div class="src-line"><a name="a3312"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//</span></span></div></li> <li><div class="src-line"><a name="a3313"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/array_keys">array_keys</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$k</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3314"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3315"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.</span></div></li> <li><div class="src-line"><a name="a3316"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;?</span></div></li> <li><div class="src-line"><a name="a3317"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$k</span><span class="src-sym">]</span>&nbsp;:&nbsp;<span class="src-str">&quot;&quot;</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3318"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3319"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;kw'</span>&nbsp;.&nbsp;<span class="src-var">$k</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3320"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3321"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">"</span></span>&lt;|/<span class="src-var">$k</span>/&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span>&nbsp;</span><span class="src-str">&quot;</span>&lt;|<span class="src-var">$attributes</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3322"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3323"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3324"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$numbers_found</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3325"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Put&nbsp;number&nbsp;styles&nbsp;in</span></span></div></li> <li><div class="src-line"><a name="a3326"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_RXCACHE'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$id</span>&nbsp;=&gt;&nbsp;<span class="src-var">$regexp</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3327"></a></span><span class="src-str"><span class="src-comm">//Commented&nbsp;out&nbsp;for&nbsp;now,&nbsp;as&nbsp;this&nbsp;needs&nbsp;some&nbsp;review&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3328"></a></span><span class="src-str"><span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if&nbsp;($numbers_permissions&nbsp;&amp;&nbsp;$id)&nbsp;{</span></span></div></li> <li><div class="src-line"><a name="a3329"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Get&nbsp;the&nbsp;appropriate&nbsp;style&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3330"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Checking&nbsp;for&nbsp;unset&nbsp;styles&nbsp;is&nbsp;done&nbsp;by&nbsp;the&nbsp;style&nbsp;cache&nbsp;builder&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3331"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3332"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$id</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3333"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3334"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;nu'</span>.<span class="src-var">$id</span>.<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3335"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3336"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3337"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Set&nbsp;in&nbsp;the&nbsp;correct&nbsp;styles&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3338"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">"</span></span>/NUM!<span class="src-var">$id</span>/<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span>&nbsp;<span class="src-var">$attributes</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3339"></a></span><span class="src-str"><span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span></span></div></li> <li><div class="src-line"><a name="a3340"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3341"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3342"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3343"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Highlight&nbsp;methods&nbsp;and&nbsp;fields&nbsp;in&nbsp;objects</span></span></div></li> <li><div class="src-line"><a name="a3344"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'METHODS'</span><span class="src-sym">]</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'OOLANG'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3345"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$oolang_spaces</span>&nbsp;=&nbsp;<span class="src-str">&quot;[\s]*&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3346"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$oolang_before</span>&nbsp;=&nbsp;<span class="src-str">&quot;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3347"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$oolang_after</span>&nbsp;=&nbsp;<span class="src-str">&quot;[a-zA-Z][a-zA-Z0-9_]*&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3348"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3349"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'OOLANG'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3350"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'OOLANG'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'MATCH_BEFORE'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3351"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$oolang_before</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'OOLANG'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'MATCH_BEFORE'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3352"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3353"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'OOLANG'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'MATCH_AFTER'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3354"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$oolang_after</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'OOLANG'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'MATCH_AFTER'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3355"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3356"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'OOLANG'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'MATCH_SPACES'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3357"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$oolang_spaces</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'OOLANG'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'MATCH_SPACES'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3358"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3359"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3360"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3361"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3362"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'OBJECT_SPLITTERS'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span>&nbsp;=&gt;&nbsp;<span class="src-var">$splitter</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3363"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">false</span>&nbsp;!==&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$stuff_to_parse</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$splitter</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3364"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3365"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'METHODS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3366"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3367"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;me'</span>&nbsp;.&nbsp;<span class="src-var">$key</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3368"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3369"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_replace">preg_replace</a><span class="src-sym">(</span><span class="src-str">"</span></span>/(<span class="src-var">$oolang_before</span>)(<span class="src-str">&quot;&nbsp;</span><span class="src-str">.&nbsp;<span class="src-id">preg_quote</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'OBJECT_SPLITTERS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'/'</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">"</span></span>)(<span class="src-var">$oolang_spaces</span>)(<span class="src-var">$oolang_after</span>)/<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span>&nbsp;</span><span class="src-str">&quot;</span>\\1\\2\\3&lt;|<span class="src-var">$attributes</span>&gt;\\4|&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3370"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3371"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3372"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3373"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3374"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//</span></span></div></li> <li><div class="src-line"><a name="a3375"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Highlight&nbsp;brackets.&nbsp;Yes,&nbsp;I've&nbsp;tried&nbsp;adding&nbsp;a&nbsp;semi-colon&nbsp;to&nbsp;this&nbsp;list.</span></span></div></li> <li><div class="src-line"><a name="a3376"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;You&nbsp;try&nbsp;it,&nbsp;and&nbsp;see&nbsp;what&nbsp;happens&nbsp;;)</span></span></div></li> <li><div class="src-line"><a name="a3377"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;TODO:&nbsp;Fix&nbsp;lexic&nbsp;permissions&nbsp;not&nbsp;converting&nbsp;entities&nbsp;if&nbsp;shouldn't</span></span></div></li> <li><div class="src-line"><a name="a3378"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;be&nbsp;highlighting&nbsp;regardless</span></span></div></li> <li><div class="src-line"><a name="a3379"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//</span></span></div></li> <li><div class="src-line"><a name="a3380"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3381"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'CACHE_BRACKET_MATCH'</span><span class="src-sym">]</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3382"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'CACHE_BRACKET_REPLACE'</span><span class="src-sym">]</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3383"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3384"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3385"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3386"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//FIX&nbsp;for&nbsp;symbol&nbsp;highlighting&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3387"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]</span>&nbsp;&amp;&amp;&nbsp;<span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3388"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Get&nbsp;all&nbsp;matches&nbsp;and&nbsp;throw&nbsp;away&nbsp;those&nbsp;witin&nbsp;a&nbsp;block&nbsp;that&nbsp;is&nbsp;already&nbsp;highlighted...&nbsp;(i.e.&nbsp;matched&nbsp;by&nbsp;a&nbsp;regexp)</span></span></div></li> <li><div class="src-line"><a name="a3389"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$n_symbols</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_match_all">preg_match_all</a><span class="src-sym">(</span><span class="src-str">&quot;/&lt;\|(?:&lt;DOT&gt;|[^&gt;])+&gt;(?:(?!\|&gt;).*?)\|&gt;|&lt;\/a&gt;|(?:&quot;</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOL_SEARCH'</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">&quot;)+/&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$pot_symbols</span><span class="src-sym">,</span>&nbsp;<span class="src-id">PREG_OFFSET_CAPTURE</span>&nbsp;|&nbsp;<span class="src-id">PREG_SET_ORDER</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3390"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$global_offset</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3391"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$s_id</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$s_id</span>&nbsp;<&nbsp;<span class="src-var">$n_symbols</span><span class="src-sym">;</span>&nbsp;++<span class="src-var">$s_id</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3392"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_match</span>&nbsp;=&nbsp;<span class="src-var">$pot_symbols</span><span class="src-sym">[</span><span class="src-var">$s_id</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3393"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$symbol_match</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&lt;'</span><span class="src-sym">)</span>&nbsp;!==&nbsp;<span class="src-id">false</span>&nbsp;||&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$symbol_match</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&gt;'</span><span class="src-sym">)</span>&nbsp;!==&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3394"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;already&nbsp;highlighted&nbsp;blocks&nbsp;_must_&nbsp;include&nbsp;either&nbsp;&lt;&nbsp;or&nbsp;&gt;</span></span></div></li> <li><div class="src-line"><a name="a3395"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;so&nbsp;if&nbsp;this&nbsp;conditional&nbsp;applies,&nbsp;we&nbsp;have&nbsp;to&nbsp;skip&nbsp;this&nbsp;match</span></span></div></li> <li><div class="src-line"><a name="a3396"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;BenBE:&nbsp;UNLESS&nbsp;the&nbsp;block&nbsp;contains&nbsp;&lt;SEMI&gt;&nbsp;or&nbsp;&lt;PIPE&gt;</span></span></div></li> <li><div class="src-line"><a name="a3397"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$symbol_match</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&lt;SEMI&gt;'</span><span class="src-sym">)</span>&nbsp;===&nbsp;<span class="src-id">false</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a3398"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$symbol_match</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&lt;PIPE&gt;'</span><span class="src-sym">)</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3399"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3400"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3401"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3402"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3403"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;if&nbsp;we&nbsp;reach&nbsp;this&nbsp;point,&nbsp;we&nbsp;have&nbsp;a&nbsp;valid&nbsp;match&nbsp;which&nbsp;needs&nbsp;to&nbsp;be&nbsp;highlighted</span></span></div></li> <li><div class="src-line"><a name="a3404"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a3405"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_length</span>&nbsp;=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$symbol_match</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3406"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_offset</span>&nbsp;=&nbsp;<span class="src-var">$pot_symbols</span><span class="src-sym">[</span><span class="src-var">$s_id</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3407"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$pot_symbols</span><span class="src-sym">[</span><span class="src-var">$s_id</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3408"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_end</span>&nbsp;=&nbsp;<span class="src-var">$symbol_length</span>&nbsp;+&nbsp;<span class="src-var">$symbol_offset</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3409"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_hl</span>&nbsp;=&nbsp;<span class="src-str">&quot;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3410"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3411"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;if&nbsp;we&nbsp;have&nbsp;multiple&nbsp;styles,&nbsp;we&nbsp;have&nbsp;to&nbsp;handle&nbsp;them&nbsp;properly</span></span></div></li> <li><div class="src-line"><a name="a3412"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'MULTIPLE_SYMBOL_GROUPS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3413"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$old_sym</span>&nbsp;=&nbsp;-<span class="src-num">1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3414"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Split&nbsp;the&nbsp;current&nbsp;stuff&nbsp;to&nbsp;replace&nbsp;into&nbsp;its&nbsp;atomic&nbsp;symbols&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3415"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/preg_match_all">preg_match_all</a><span class="src-sym">(</span><span class="src-str">&quot;/&quot;</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOL_SEARCH'</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">&quot;/&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$symbol_match</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$sym_match_syms</span><span class="src-sym">,</span>&nbsp;<span class="src-id">PREG_PATTERN_ORDER</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3416"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$sym_match_syms</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$sym_ms</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3417"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;consequtive&nbsp;symbols&nbsp;belong&nbsp;to&nbsp;the&nbsp;same&nbsp;group&nbsp;to&nbsp;save&nbsp;output&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3418"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOL_DATA'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$sym_ms</span><span class="src-sym">]</span><span class="src-sym">)</span></span></div></li> <li><div class="src-line"><a name="a3419"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&amp;&amp;&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOL_DATA'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$sym_ms</span><span class="src-sym">]</span>&nbsp;!=&nbsp;<span class="src-var">$old_sym</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3420"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>-<span class="src-num">1</span>&nbsp;!=&nbsp;<span class="src-var">$old_sym</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3421"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_hl</span>&nbsp;.=&nbsp;<span class="src-str">&quot;|&gt;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3422"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3423"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$old_sym</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'SYMBOL_DATA'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$sym_ms</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3424"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3425"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_hl</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;|&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$old_sym</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3426"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3427"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_hl</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;|&nbsp;class=&quot;sy'</span>&nbsp;.&nbsp;<span class="src-var">$old_sym</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3428"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3429"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3430"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_hl</span>&nbsp;.=&nbsp;<span class="src-var">$sym_ms</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3431"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3432"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$sym_match_syms</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3433"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3434"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Close&nbsp;remaining&nbsp;tags&nbsp;and&nbsp;insert&nbsp;the&nbsp;replacement&nbsp;at&nbsp;the&nbsp;right&nbsp;position&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3435"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Take&nbsp;caution&nbsp;if&nbsp;symbol_hl&nbsp;is&nbsp;empty&nbsp;to&nbsp;avoid&nbsp;doubled&nbsp;closing&nbsp;spans.</span></span></div></li> <li><div class="src-line"><a name="a3436"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>-<span class="src-num">1</span>&nbsp;!=&nbsp;<span class="src-var">$old_sym</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3437"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_hl</span>&nbsp;.=&nbsp;<span class="src-str">&quot;|&gt;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3438"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3439"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3440"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3441"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_hl</span>&nbsp;=&nbsp;<span class="src-str">'&lt;|&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3442"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3443"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_hl</span>&nbsp;=&nbsp;<span class="src-str">'&lt;|&nbsp;class=&quot;sy0&quot;&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3444"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3445"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$symbol_hl</span>&nbsp;.=&nbsp;<span class="src-var">$symbol_match</span>&nbsp;.&nbsp;<span class="src-str">'|&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3446"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3447"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3448"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/substr_replace">substr_replace</a><span class="src-sym">(</span><span class="src-var">$stuff_to_parse</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$symbol_hl</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$symbol_offset</span>&nbsp;+&nbsp;<span class="src-var">$global_offset</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$symbol_length</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3449"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3450"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;since&nbsp;we&nbsp;replace&nbsp;old&nbsp;text&nbsp;with&nbsp;something&nbsp;of&nbsp;different&nbsp;size,</span></span></div></li> <li><div class="src-line"><a name="a3451"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;we'll&nbsp;have&nbsp;to&nbsp;keep&nbsp;track&nbsp;of&nbsp;the&nbsp;differences</span></span></div></li> <li><div class="src-line"><a name="a3452"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$global_offset</span>&nbsp;+=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$symbol_hl</span><span class="src-sym">)</span>&nbsp;-&nbsp;<span class="src-var">$symbol_length</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3453"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3454"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3455"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//FIX&nbsp;for&nbsp;symbol&nbsp;highlighting&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3456"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a3457"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Add&nbsp;class/style&nbsp;for&nbsp;regexps</span></span></div></li> <li><div class="src-line"><a name="a3458"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/array_keys">array_keys</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3459"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3460"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_callable">is_callable</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3461"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_rx_key</span>&nbsp;=&nbsp;<span class="src-var">$key</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3462"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_replace_callback">preg_replace_callback</a><span class="src-sym">(</span><span class="src-str">"</span></span>/!REG3XP<span class="src-var">$key</span>!(.*)\|&gt;/U<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3463"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'handle_regexps_callback'</span><span class="src-sym">)</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a3464"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3465"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3466"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3467"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3468"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3469"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a3470"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/array_key_exists">array_key_exists</a><span class="src-sym">(</span><span class="src-id">GESHI_CLASS</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3471"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;'</span>&nbsp;.</span></div></li> <li><div class="src-line"><a name="a3472"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-id">GESHI_CLASS</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3473"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3474"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;re'</span>&nbsp;.&nbsp;<span class="src-var">$key</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3475"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3476"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3477"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">"</span></span>!REG3XP<span class="src-var">$key</span>!<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span>&nbsp;</span><span class="src-str">&quot;</span><span class="src-var">$attributes</span><span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3478"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3479"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3480"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3481"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3482"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Replace&nbsp;&lt;DOT&gt;&nbsp;with&nbsp;.&nbsp;for&nbsp;urls</span></span></div></li> <li><div class="src-line"><a name="a3483"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<span class="src-id">str_replace</span><span class="src-sym">(</span><span class="src-str">'&lt;DOT&gt;'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'.'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3484"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Replace&nbsp;&lt;|UR1|&nbsp;with&nbsp;&lt;a&nbsp;href=&nbsp;for&nbsp;urls&nbsp;also</span></span></div></li> <li><div class="src-line"><a name="a3485"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">link_styles</span><span class="src-sym">[</span><span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_LINK&quot;&gt;GESHI_LINK&lt;/a&gt;</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3486"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3487"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">'&lt;|UR1|'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&lt;a'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">link_target</span>&nbsp;.&nbsp;<span class="src-str">'&nbsp;href='</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3488"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3489"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">'&lt;|UR1|'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&lt;a'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">link_target</span>&nbsp;.&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">link_styles</span><span class="src-sym">[</span><span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_LINK&quot;&gt;GESHI_LINK&lt;/a&gt;</span><span class="src-sym">]</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&nbsp;href='</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3490"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3491"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3492"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">'&lt;|UR1|'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&lt;a'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">link_target</span>&nbsp;.&nbsp;<span class="src-str">'&nbsp;href='</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3493"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3494"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3495"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//</span></span></div></li> <li><div class="src-line"><a name="a3496"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;NOW&nbsp;we&nbsp;add&nbsp;the&nbsp;span&nbsp;thingy&nbsp;;)</span></span></div></li> <li><div class="src-line"><a name="a3497"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//</span></span></div></li> <li><div class="src-line"><a name="a3498"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a3499"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">'&lt;|'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&lt;span'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3500"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a>&nbsp;<span class="src-sym">(</span>&nbsp;<span class="src-str">'|&gt;'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$stuff_to_parse</span>&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3501"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$stuff_to_parse</span><span class="src-sym">,</span>&nbsp;<span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3502"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3503"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3504"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a3505"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Sets&nbsp;the&nbsp;time&nbsp;taken&nbsp;to&nbsp;parse&nbsp;the&nbsp;code</span></div></li> <li><div class="src-line"><a name="a3506"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3507"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;microtime&nbsp;The&nbsp;time&nbsp;when&nbsp;parsing&nbsp;started</span></div></li> <li><div class="src-line"><a name="a3508"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;microtime&nbsp;The&nbsp;time&nbsp;when&nbsp;parsing&nbsp;ended</span></div></li> <li><div class="src-line"><a name="a3509"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a3510"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@access&nbsp;private</span></div></li> <li><div class="src-line"><a name="a3511"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a3512"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">set_time</span><span class="src-sym">(</span><span class="src-var">$start_time</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$end_time</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3513"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<a href="http://www.php.net/explode">explode</a><span class="src-sym">(</span><span class="src-str">'&nbsp;'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$start_time</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3514"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$end</span>&nbsp;=&nbsp;<a href="http://www.php.net/explode">explode</a><span class="src-sym">(</span><span class="src-str">'&nbsp;'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$end_time</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3515"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="http://www.php.net/time">time</a>&nbsp;=&nbsp;<span class="src-var">$end</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;+&nbsp;<span class="src-var">$end</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span>&nbsp;-&nbsp;<span class="src-var">$start</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span>&nbsp;-&nbsp;<span class="src-var">$start</span><span class="src-sym">[</span><span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3516"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3517"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3518"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a3519"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Gets&nbsp;the&nbsp;time&nbsp;taken&nbsp;to&nbsp;parse&nbsp;the&nbsp;code</span></div></li> <li><div class="src-line"><a name="a3520"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3521"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@return&nbsp;double&nbsp;The&nbsp;time&nbsp;taken&nbsp;to&nbsp;parse&nbsp;the&nbsp;code</span></div></li> <li><div class="src-line"><a name="a3522"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a3523"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a3524"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodget_time">get_time</a><span class="src-sym">(</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3525"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="http://www.php.net/time">time</a><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3526"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3527"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3528"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a3529"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Merges&nbsp;arrays&nbsp;recursively,&nbsp;overwriting&nbsp;values&nbsp;of&nbsp;the&nbsp;first&nbsp;array&nbsp;with&nbsp;values&nbsp;of&nbsp;later&nbsp;arrays</span></div></li> <li><div class="src-line"><a name="a3530"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3531"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;1.0.8</span></div></li> <li><div class="src-line"><a name="a3532"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@access&nbsp;private</span></div></li> <li><div class="src-line"><a name="a3533"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a3534"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">merge_arrays</span><span class="src-sym">(</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3535"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$arrays</span>&nbsp;=&nbsp;<a href="http://www.php.net/func_get_args">func_get_args</a><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3536"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$narrays</span>&nbsp;=&nbsp;<a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$arrays</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3537"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3538"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;check&nbsp;arguments</span></span></div></li> <li><div class="src-line"><a name="a3539"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;comment&nbsp;out&nbsp;if&nbsp;more&nbsp;performance&nbsp;is&nbsp;necessary&nbsp;(in&nbsp;this&nbsp;case&nbsp;the&nbsp;foreach&nbsp;loop&nbsp;will&nbsp;trigger&nbsp;a&nbsp;warning&nbsp;if&nbsp;the&nbsp;argument&nbsp;is&nbsp;not&nbsp;an&nbsp;array)</span></span></div></li> <li><div class="src-line"><a name="a3540"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$i</span>&nbsp;<&nbsp;<span class="src-var">$narrays</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$i</span>&nbsp;++<span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3541"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$arrays</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3542"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;also&nbsp;array_merge_recursive&nbsp;returns&nbsp;nothing&nbsp;in&nbsp;this&nbsp;case</span></span></div></li> <li><div class="src-line"><a name="a3543"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/trigger_error">trigger_error</a><span class="src-sym">(</span><span class="src-str">'Argument&nbsp;#'</span>&nbsp;.&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>+<span class="src-num">1</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">'&nbsp;is&nbsp;not&nbsp;an&nbsp;array&nbsp;-&nbsp;trying&nbsp;to&nbsp;merge&nbsp;array&nbsp;with&nbsp;scalar!&nbsp;Returning&nbsp;false!'</span><span class="src-sym">,</span>&nbsp;<span class="src-id">E_USER_WARNING</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3544"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3545"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3546"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3547"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3548"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;the&nbsp;first&nbsp;array&nbsp;is&nbsp;in&nbsp;the&nbsp;output&nbsp;set&nbsp;in&nbsp;every&nbsp;case</span></span></div></li> <li><div class="src-line"><a name="a3549"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$ret</span>&nbsp;=&nbsp;<span class="src-var">$arrays</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3550"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3551"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;merege&nbsp;$ret&nbsp;with&nbsp;the&nbsp;remaining&nbsp;arrays</span></span></div></li> <li><div class="src-line"><a name="a3552"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-num">1</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$i</span>&nbsp;<&nbsp;<span class="src-var">$narrays</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$i</span>&nbsp;++<span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3553"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$arrays</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span>&nbsp;=&gt;&nbsp;<span class="src-var">$value</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3554"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$value</span><span class="src-sym">)</span>&nbsp;&amp;&amp;&nbsp;isset<span class="src-sym">(</span><span class="src-var">$ret</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3555"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;if&nbsp;$ret[$key]&nbsp;is&nbsp;not&nbsp;an&nbsp;array&nbsp;you&nbsp;try&nbsp;to&nbsp;merge&nbsp;an&nbsp;scalar&nbsp;value&nbsp;with&nbsp;an&nbsp;array&nbsp;-&nbsp;the&nbsp;result&nbsp;is&nbsp;not&nbsp;defined&nbsp;(incompatible&nbsp;arrays)</span></span></div></li> <li><div class="src-line"><a name="a3556"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;in&nbsp;this&nbsp;case&nbsp;the&nbsp;call&nbsp;will&nbsp;trigger&nbsp;an&nbsp;E_USER_WARNING&nbsp;and&nbsp;the&nbsp;$ret[$key]&nbsp;will&nbsp;be&nbsp;false.</span></span></div></li> <li><div class="src-line"><a name="a3557"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$ret</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">merge_arrays</span><span class="src-sym">(</span><span class="src-var">$ret</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$value</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3558"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3559"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$ret</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$value</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3560"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3561"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3562"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3563"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3564"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$ret</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3565"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3566"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3567"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a3568"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Gets&nbsp;language&nbsp;information&nbsp;and&nbsp;stores&nbsp;it&nbsp;for&nbsp;later&nbsp;use</span></div></li> <li><div class="src-line"><a name="a3569"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3570"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;string&nbsp;The&nbsp;filename&nbsp;of&nbsp;the&nbsp;language&nbsp;file&nbsp;you&nbsp;want&nbsp;to&nbsp;load</span></div></li> <li><div class="src-line"><a name="a3571"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a3572"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@access&nbsp;private</span></div></li> <li><div class="src-line"><a name="a3573"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@todo&nbsp;Needs&nbsp;to&nbsp;load&nbsp;keys&nbsp;for&nbsp;lexic&nbsp;permissions&nbsp;for&nbsp;keywords,&nbsp;regexps&nbsp;etc</span></div></li> <li><div class="src-line"><a name="a3574"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a3575"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">load_language</span><span class="src-sym">(</span><span class="src-var">$file_name</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3576"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$file_name</span>&nbsp;==&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">loaded_language</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3577"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;this&nbsp;file&nbsp;is&nbsp;already&nbsp;loaded!</span></span></div></li> <li><div class="src-line"><a name="a3578"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3579"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3580"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3581"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Prepare&nbsp;some&nbsp;stuff&nbsp;before&nbsp;actually&nbsp;loading&nbsp;the&nbsp;language&nbsp;file</span></span></div></li> <li><div class="src-line"><a name="a3582"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">loaded_language</span>&nbsp;=&nbsp;<span class="src-var">$file_name</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3583"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">parse_cache_built</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3584"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodenable_highlighting">enable_highlighting</a><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3585"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$language_data</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3586"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3587"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Load&nbsp;the&nbsp;language&nbsp;file</span></span></div></li> <li><div class="src-line"><a name="a3588"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;require&nbsp;<span class="src-var">$file_name</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3589"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3590"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Perhaps&nbsp;some&nbsp;checking&nbsp;might&nbsp;be&nbsp;added&nbsp;here&nbsp;later&nbsp;to&nbsp;check&nbsp;that</span></span></div></li> <li><div class="src-line"><a name="a3591"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;$language&nbsp;data&nbsp;is&nbsp;a&nbsp;valid&nbsp;thing&nbsp;but&nbsp;maybe&nbsp;not</span></span></div></li> <li><div class="src-line"><a name="a3592"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span>&nbsp;=&nbsp;<span class="src-var">$language_data</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3593"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3594"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Set&nbsp;strict&nbsp;mode&nbsp;if&nbsp;should&nbsp;be&nbsp;set</span></span></div></li> <li><div class="src-line"><a name="a3595"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">strict_mode</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STRICT_MODE_APPLIES'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3596"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3597"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Set&nbsp;permissions&nbsp;for&nbsp;all&nbsp;lexics&nbsp;to&nbsp;true</span></span></div></li> <li><div class="src-line"><a name="a3598"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;so&nbsp;they'll&nbsp;be&nbsp;highlighted&nbsp;by&nbsp;default</span></span></div></li> <li><div class="src-line"><a name="a3599"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/array_keys">array_keys</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3600"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3601"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3602"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3603"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-id">false</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3604"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3605"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3606"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3607"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/array_keys">array_keys</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'COMMENT_SINGLE'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3608"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3609"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3610"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/array_keys">array_keys</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">)</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3611"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3612"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3613"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3614"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;for&nbsp;BenBE&nbsp;and&nbsp;future&nbsp;code&nbsp;reviews:</span></span></div></li> <li><div class="src-line"><a name="a3615"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;we&nbsp;can&nbsp;use&nbsp;empty&nbsp;here&nbsp;since&nbsp;we&nbsp;only&nbsp;check&nbsp;for&nbsp;existance&nbsp;and&nbsp;emptiness&nbsp;of&nbsp;an&nbsp;array</span></span></div></li> <li><div class="src-line"><a name="a3616"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;if&nbsp;it&nbsp;is&nbsp;not&nbsp;an&nbsp;array&nbsp;at&nbsp;all&nbsp;but&nbsp;rather&nbsp;false&nbsp;or&nbsp;null&nbsp;this&nbsp;will&nbsp;work&nbsp;as&nbsp;intended&nbsp;as&nbsp;well</span></span></div></li> <li><div class="src-line"><a name="a3617"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;even&nbsp;if&nbsp;$this-&gt;language_data['PARSER_CONTROL']&nbsp;is&nbsp;undefined&nbsp;this&nbsp;won't&nbsp;trigger&nbsp;a&nbsp;notice</span></span></div></li> <li><div class="src-line"><a name="a3618"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'ENABLE_FLAGS'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3619"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'ENABLE_FLAGS'</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$flag</span>&nbsp;=&gt;&nbsp;<span class="src-var">$value</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3620"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;it's&nbsp;either&nbsp;true&nbsp;or&nbsp;false&nbsp;and&nbsp;maybe&nbsp;is&nbsp;true&nbsp;as&nbsp;well</span></span></div></li> <li><div class="src-line"><a name="a3621"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$perm</span>&nbsp;=&nbsp;<span class="src-var">$value</span>&nbsp;!==&nbsp;<span class="src-id">GESHI_NEVER</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3622"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$flag</span>&nbsp;==&nbsp;<span class="src-str">'ALL'</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3623"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodenable_highlighting">enable_highlighting</a><span class="src-sym">(</span><span class="src-var">$perm</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3624"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3625"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3626"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-var">$flag</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3627"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;unknown&nbsp;lexic&nbsp;permission</span></span></div></li> <li><div class="src-line"><a name="a3628"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3629"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3630"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-var">$flag</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3631"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-var">$flag</span><span class="src-sym">]</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span>&nbsp;=&gt;&nbsp;<span class="src-var">$val</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3632"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-var">$flag</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$key</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$perm</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3633"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3634"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3635"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-var">$flag</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$perm</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3636"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3637"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3638"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'PARSER_CONTROL'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'ENABLE_FLAGS'</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3639"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3640"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3641"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//NEW&nbsp;in&nbsp;1.0.8:&nbsp;Allow&nbsp;styles&nbsp;to&nbsp;be&nbsp;loaded&nbsp;from&nbsp;a&nbsp;separate&nbsp;file&nbsp;to&nbsp;override&nbsp;defaults</span></span></div></li> <li><div class="src-line"><a name="a3642"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$style_filename</span>&nbsp;=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$file_name</span><span class="src-sym">,</span>&nbsp;<span class="src-num">0</span><span class="src-sym">,</span>&nbsp;-<span class="src-num">4</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">'.style.php'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3643"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/is_readable">is_readable</a><span class="src-sym">(</span><span class="src-var">$style_filename</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3644"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Clear&nbsp;any&nbsp;style_data&nbsp;that&nbsp;could&nbsp;have&nbsp;been&nbsp;set&nbsp;before&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3645"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$style_data</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3646"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$style_data</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3647"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3648"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3649"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Read&nbsp;the&nbsp;Style&nbsp;Information&nbsp;from&nbsp;the&nbsp;style&nbsp;file</span></span></div></li> <li><div class="src-line"><a name="a3650"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-inc">include</span>&nbsp;<span class="src-var">$style_filename</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3651"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3652"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Apply&nbsp;the&nbsp;new&nbsp;styles&nbsp;to&nbsp;our&nbsp;current&nbsp;language&nbsp;styles</span></span></div></li> <li><div class="src-line"><a name="a3653"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$style_data</span><span class="src-sym">)</span>&nbsp;&amp;&amp;&nbsp;<a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$style_data</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3654"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span>&nbsp;=</span></div></li> <li><div class="src-line"><a name="a3655"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">merge_arrays</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$style_data</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3656"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3657"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3658"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3659"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3660"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a3661"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Takes&nbsp;the&nbsp;parsed&nbsp;code&nbsp;and&nbsp;various&nbsp;options,&nbsp;and&nbsp;creates&nbsp;the&nbsp;HTML</span></div></li> <li><div class="src-line"><a name="a3662"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;surrounding&nbsp;it&nbsp;to&nbsp;make&nbsp;it&nbsp;look&nbsp;nice.</span></div></li> <li><div class="src-line"><a name="a3663"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3664"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;&nbsp;string&nbsp;The&nbsp;code&nbsp;already&nbsp;parsed&nbsp;(reference!)</span></div></li> <li><div class="src-line"><a name="a3665"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a3666"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@access&nbsp;private</span></div></li> <li><div class="src-line"><a name="a3667"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a3668"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">finalise</span><span class="src-sym">(</span><span class="src-sym">&</span><span class="src-var">$parsed_code</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3669"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Remove&nbsp;end&nbsp;parts&nbsp;of&nbsp;important&nbsp;declarations</span></span></div></li> <li><div class="src-line"><a name="a3670"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;This&nbsp;is&nbsp;BUGGY!!&nbsp;My&nbsp;fault&nbsp;for&nbsp;bad&nbsp;code:&nbsp;fix&nbsp;coming&nbsp;in&nbsp;1.2</span></span></div></li> <li><div class="src-line"><a name="a3671"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;@todo&nbsp;Remove&nbsp;this&nbsp;crap</span></span></div></li> <li><div class="src-line"><a name="a3672"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodenable_important_blocks">enable_important_blocks</a>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a3673"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/strpos">strpos</a><span class="src-sym">(</span><span class="src-var">$parsed_code</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_START_IMPORTANT&quot;&gt;GESHI_START_IMPORTANT&lt;/a&gt;</span><span class="src-sym">))</span>&nbsp;===&nbsp;<span class="src-id">false</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3674"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_END_IMPORTANT&quot;&gt;GESHI_END_IMPORTANT&lt;/a&gt;</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-str">''</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$parsed_code</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3675"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3676"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3677"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Add&nbsp;HTML&nbsp;whitespace&nbsp;stuff&nbsp;if&nbsp;we're&nbsp;using&nbsp;the&nbsp;&lt;div&gt;&nbsp;header</span></span></div></li> <li><div class="src-line"><a name="a3678"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE&quot;&gt;GESHI_HEADER_PRE&lt;/a&gt;</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_VALID&quot;&gt;GESHI_HEADER_PRE_VALID&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3679"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">indent</span><span class="src-sym">(</span><span class="src-var">$parsed_code</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3680"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3681"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3682"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;purge&nbsp;some&nbsp;unnecessary&nbsp;stuff</span></span></div></li> <li><div class="src-line"><a name="a3683"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**&nbsp;NOTE:&nbsp;memorypeak&nbsp;#1&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a3684"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;=&nbsp;<a href="http://www.php.net/preg_replace">preg_replace</a><span class="src-sym">(</span><span class="src-str">'#&lt;span[^&gt;]+&gt;(\s*)&lt;/span&gt;#'</span><span class="src-sym">,</span>&nbsp;<span class="src-str">'\\1'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$parsed_code</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3685"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3686"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;If&nbsp;we&nbsp;are&nbsp;using&nbsp;IDs&nbsp;for&nbsp;line&nbsp;numbers,&nbsp;there&nbsp;needs&nbsp;to&nbsp;be&nbsp;an&nbsp;overall</span></span></div></li> <li><div class="src-line"><a name="a3687"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;ID&nbsp;set&nbsp;to&nbsp;prevent&nbsp;collisions.</span></span></div></li> <li><div class="src-line"><a name="a3688"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">add_ids</span>&nbsp;&amp;&amp;&nbsp;<span class="src-sym">!</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_id</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3689"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_id</span>&nbsp;=&nbsp;<span class="src-str">'geshi-'</span>&nbsp;.&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><a href="http://www.php.net/md5">md5</a><span class="src-sym">(</span><a href="http://www.php.net/microtime">microtime</a><span class="src-sym">(</span><span class="src-sym">))</span><span class="src-sym">,</span>&nbsp;<span class="src-num">0</span><span class="src-sym">,</span>&nbsp;<span class="src-num">4</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3690"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3691"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3692"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Get&nbsp;code&nbsp;into&nbsp;lines</span></span></div></li> <li><div class="src-line"><a name="a3693"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**&nbsp;NOTE:&nbsp;memorypeak&nbsp;#2&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a3694"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$code</span>&nbsp;=&nbsp;<a href="http://www.php.net/explode">explode</a><span class="src-sym">(</span><span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$parsed_code</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3695"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="http://www.php.net/header">header</a><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3696"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3697"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;If&nbsp;we're&nbsp;using&nbsp;line&nbsp;numbers,&nbsp;we&nbsp;insert&nbsp;&lt;li&gt;s&nbsp;and&nbsp;appropriate</span></span></div></li> <li><div class="src-line"><a name="a3698"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;markup&nbsp;to&nbsp;style&nbsp;them&nbsp;(otherwise&nbsp;we&nbsp;don't&nbsp;need&nbsp;to&nbsp;do&nbsp;anything)</span></span></div></li> <li><div class="src-line"><a name="a3699"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS&quot;&gt;GESHI_NO_LINE_NUMBERS&lt;/a&gt;</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_TABLE&quot;&gt;GESHI_HEADER_PRE_TABLE&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3700"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;If&nbsp;we're&nbsp;using&nbsp;the&nbsp;&lt;pre&gt;&nbsp;header,&nbsp;we&nbsp;shouldn't&nbsp;add&nbsp;newlines&nbsp;because</span></span></div></li> <li><div class="src-line"><a name="a3701"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;the&nbsp;&lt;pre&gt;&nbsp;will&nbsp;line-break&nbsp;them&nbsp;(and&nbsp;the&nbsp;&lt;li&gt;s&nbsp;already&nbsp;do&nbsp;this&nbsp;for&nbsp;us)</span></span></div></li> <li><div class="src-line"><a name="a3702"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$ls</span>&nbsp;=&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE&quot;&gt;GESHI_HEADER_PRE&lt;/a&gt;</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_VALID&quot;&gt;GESHI_HEADER_PRE_VALID&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-str">&quot;\n&quot;</span>&nbsp;:&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3703"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3704"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Set&nbsp;vars&nbsp;to&nbsp;defaults&nbsp;for&nbsp;following&nbsp;loop</span></span></div></li> <li><div class="src-line"><a name="a3705"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3706"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3707"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Foreach&nbsp;line...</span></span></div></li> <li><div class="src-line"><a name="a3708"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$n</span>&nbsp;=&nbsp;<a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">)</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$i</span>&nbsp;<&nbsp;<span class="src-var">$n</span><span class="src-sym">;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3709"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Reset&nbsp;the&nbsp;attributes&nbsp;for&nbsp;a&nbsp;new&nbsp;line&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a3710"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attrs</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3711"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3712"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Make&nbsp;lines&nbsp;have&nbsp;at&nbsp;least&nbsp;one&nbsp;space&nbsp;in&nbsp;them&nbsp;if&nbsp;they're&nbsp;empty</span></span></div></li> <li><div class="src-line"><a name="a3713"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;BenBE:&nbsp;Checking&nbsp;emptiness&nbsp;using&nbsp;trim&nbsp;instead&nbsp;of&nbsp;relying&nbsp;on&nbsp;blanks</span></span></div></li> <li><div class="src-line"><a name="a3714"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-str">''</span>&nbsp;==&nbsp;<a href="http://www.php.net/trim">trim</a><span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3715"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$code</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'&amp;nbsp;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3716"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3717"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3718"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;If&nbsp;this&nbsp;is&nbsp;a&nbsp;&quot;special&nbsp;line&quot;...</span></span></div></li> <li><div class="src-line"><a name="a3719"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_FANCY_LINE_NUMBERS&quot;&gt;GESHI_FANCY_LINE_NUMBERS&lt;/a&gt;</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a3720"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;%&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_nth_row</span>&nbsp;==&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_nth_row</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3721"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Set&nbsp;the&nbsp;attributes&nbsp;to&nbsp;style&nbsp;the&nbsp;line</span></span></div></li> <li><div class="src-line"><a name="a3722"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3723"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//$attr&nbsp;=&nbsp;'&nbsp;class=&quot;li2&quot;';</span></span></div></li> <li><div class="src-line"><a name="a3724"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attrs</span><span class="src-sym">[</span><span class="src-str">'class'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'li2'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3725"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$def_attr</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;de2&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3726"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3727"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//$attr&nbsp;=&nbsp;'&nbsp;style=&quot;'&nbsp;.&nbsp;$this-&gt;line_style2&nbsp;.&nbsp;'&quot;';</span></span></div></li> <li><div class="src-line"><a name="a3728"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attrs</span><span class="src-sym">[</span><span class="src-str">'style'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_style2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3729"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;This&nbsp;style&nbsp;&quot;covers&nbsp;up&quot;&nbsp;the&nbsp;special&nbsp;styles&nbsp;set&nbsp;for&nbsp;special&nbsp;lines</span></span></div></li> <li><div class="src-line"><a name="a3730"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;so&nbsp;that&nbsp;styles&nbsp;applied&nbsp;to&nbsp;special&nbsp;lines&nbsp;don't&nbsp;apply&nbsp;to&nbsp;the&nbsp;actual</span></span></div></li> <li><div class="src-line"><a name="a3731"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;code&nbsp;on&nbsp;that&nbsp;line</span></span></div></li> <li><div class="src-line"><a name="a3732"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$def_attr</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">code_style</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3733"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3734"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3735"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3736"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//$attr&nbsp;=&nbsp;'&nbsp;class=&quot;li1&quot;';</span></span></div></li> <li><div class="src-line"><a name="a3737"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attrs</span><span class="src-sym">[</span><span class="src-str">'class'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'li1'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3738"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$def_attr</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;de1&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3739"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3740"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//$attr&nbsp;=&nbsp;'&nbsp;style=&quot;'&nbsp;.&nbsp;$this-&gt;line_style1&nbsp;.&nbsp;'&quot;';</span></span></div></li> <li><div class="src-line"><a name="a3741"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attrs</span><span class="src-sym">[</span><span class="src-str">'style'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_style1</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3742"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$def_attr</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">code_style</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3743"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3744"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3745"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3746"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;which&nbsp;type&nbsp;of&nbsp;tag&nbsp;to&nbsp;insert&nbsp;for&nbsp;this&nbsp;line</span></span></div></li> <li><div class="src-line"><a name="a3747"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_VALID&quot;&gt;GESHI_HEADER_PRE_VALID&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3748"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-str">"</span></span>&lt;pre<span class="src-var">$def_attr</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3749"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$end</span>&nbsp;=&nbsp;<span class="src-str">'&lt;/pre&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3750"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3751"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Span&nbsp;or&nbsp;div?</span></span></div></li> <li><div class="src-line"><a name="a3752"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$start</span>&nbsp;=&nbsp;<span class="src-str">"</span></span>&lt;div<span class="src-var">$def_attr</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3753"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$end</span>&nbsp;=&nbsp;<span class="src-str">'&lt;/div&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3754"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3755"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3756"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$i</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3757"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3758"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Are&nbsp;we&nbsp;supposed&nbsp;to&nbsp;use&nbsp;ids?&nbsp;If&nbsp;so,&nbsp;add&nbsp;them</span></span></div></li> <li><div class="src-line"><a name="a3759"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">add_ids</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3760"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attrs</span><span class="src-sym">[</span><span class="src-str">'id'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">"</span></span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_id</span>-<span class="src-var">$i</span><span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3761"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3762"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3763"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Is&nbsp;this&nbsp;some&nbsp;line&nbsp;with&nbsp;extra&nbsp;styles???</span></span></div></li> <li><div class="src-line"><a name="a3764"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">in_array</span><span class="src-sym">(</span><span class="src-var">$i</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3765"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3766"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines_styles</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3767"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attrs</span><span class="src-sym">[</span><span class="src-str">'class'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">"</span></span>lx<span class="src-var">$i</span><span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3768"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3769"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attrs</span><span class="src-sym">[</span><span class="src-str">'class'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">&quot;ln-xtra&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3770"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3771"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3772"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/array_push">array_push</a><span class="src-sym">(</span><span class="src-var">$attrs</span><span class="src-sym">[</span><span class="src-str">'style'</span><span class="src-sym">]</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">get_line_style</span><span class="src-sym">(</span><span class="src-var">$i</span><span class="src-sym">))</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3773"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3774"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3775"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3776"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Add&nbsp;in&nbsp;the&nbsp;line&nbsp;surrounded&nbsp;by&nbsp;appropriate&nbsp;list&nbsp;HTML</span></span></div></li> <li><div class="src-line"><a name="a3777"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attr_string</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3778"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$attrs</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span>&nbsp;=&gt;&nbsp;<span class="src-var">$attr</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3779"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attr_string</span>&nbsp;.=&nbsp;<span class="src-str">'&nbsp;'</span>&nbsp;.&nbsp;<span class="src-var">$key</span>&nbsp;.&nbsp;<span class="src-str">'=&quot;'</span>&nbsp;.&nbsp;<a href="http://www.php.net/implode">implode</a><span class="src-sym">(</span><span class="src-str">'&nbsp;'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$attr</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3780"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3781"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3782"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">"</span></span>&lt;li<span class="src-var">$attr_string</span>&gt;<span class="src-var">$start</span>{<span class="src-var">$code</span><span class="src-sym">[</span><span class="src-var">$i</span>-<span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">}</span><span class="src-var">$end</span>&lt;/li&gt;<span class="src-var">$ls</span><span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3783"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">[</span><span class="src-var">$i</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3784"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3785"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3786"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$n</span>&nbsp;=&nbsp;<span class="src-id">count</span><span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3787"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3788"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;de1&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3789"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3790"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">code_style</span>&nbsp;.<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3791"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3792"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_VALID&quot;&gt;GESHI_HEADER_PRE_VALID&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3793"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;pre'</span>.&nbsp;<span class="src-var">$attributes</span>&nbsp;.<span class="src-str">'&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3794"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">elseif</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_TABLE&quot;&gt;GESHI_HEADER_PRE_TABLE&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3795"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS&quot;&gt;GESHI_NO_LINE_NUMBERS&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3796"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3797"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attrs</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;ln&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3798"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3799"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attrs</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">table_linenumber_style</span>&nbsp;.<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3800"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3801"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;td'</span>.<span class="src-var">$attrs</span>.<span class="src-str">'&gt;&lt;pre'</span>.<span class="src-var">$attributes</span>.<span class="src-str">'&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3802"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;get&nbsp;linenumbers</span></span></div></li> <li><div class="src-line"><a name="a3803"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;we&nbsp;don't&nbsp;merge&nbsp;it&nbsp;with&nbsp;the&nbsp;for&nbsp;below,&nbsp;since&nbsp;it&nbsp;should&nbsp;be&nbsp;better&nbsp;for</span></span></div></li> <li><div class="src-line"><a name="a3804"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;memory&nbsp;consumption&nbsp;this&nbsp;way</span></span></div></li> <li><div class="src-line"><a name="a3805"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;@todo:&nbsp;but...&nbsp;actually&nbsp;it&nbsp;would&nbsp;still&nbsp;be&nbsp;somewhat&nbsp;nice&nbsp;to&nbsp;merge&nbsp;the&nbsp;two&nbsp;loops</span></span></div></li> <li><div class="src-line"><a name="a3806"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;the&nbsp;mem&nbsp;peaks&nbsp;are&nbsp;at&nbsp;different&nbsp;positions</span></span></div></li> <li><div class="src-line"><a name="a3807"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$i</span>&nbsp;<&nbsp;<span class="src-var">$n</span><span class="src-sym">;</span>&nbsp;++<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3808"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3809"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;fancy&nbsp;lines</span></span></div></li> <li><div class="src-line"><a name="a3810"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_FANCY_LINE_NUMBERS&quot;&gt;GESHI_FANCY_LINE_NUMBERS&lt;/a&gt;</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a3811"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;%&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_nth_row</span>&nbsp;==&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_nth_row</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3812"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Set&nbsp;the&nbsp;attributes&nbsp;to&nbsp;style&nbsp;the&nbsp;line</span></span></div></li> <li><div class="src-line"><a name="a3813"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3814"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;span&nbsp;class=&quot;xtra&nbsp;li2&quot;&gt;&lt;span&nbsp;class=&quot;de2&quot;&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3815"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3816"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;This&nbsp;style&nbsp;&quot;covers&nbsp;up&quot;&nbsp;the&nbsp;special&nbsp;styles&nbsp;set&nbsp;for&nbsp;special&nbsp;lines</span></span></div></li> <li><div class="src-line"><a name="a3817"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;so&nbsp;that&nbsp;styles&nbsp;applied&nbsp;to&nbsp;special&nbsp;lines&nbsp;don't&nbsp;apply&nbsp;to&nbsp;the&nbsp;actual</span></span></div></li> <li><div class="src-line"><a name="a3818"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;code&nbsp;on&nbsp;that&nbsp;line</span></span></div></li> <li><div class="src-line"><a name="a3819"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;span&nbsp;style=&quot;display:block;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_style2</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&gt;'</span></span></div></li> <li><div class="src-line"><a name="a3820"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.<span class="src-str">'&lt;span&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">code_style</span>&nbsp;.<span class="src-str">'&quot;&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3821"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3822"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close</span>&nbsp;+=&nbsp;<span class="src-num">2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3823"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3824"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Is&nbsp;this&nbsp;some&nbsp;line&nbsp;with&nbsp;extra&nbsp;styles???</span></span></div></li> <li><div class="src-line"><a name="a3825"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/in_array">in_array</a><span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3826"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3827"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines_styles</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3828"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">"</span></span>&lt;span&nbsp;class=\&quot;xtra&nbsp;lx<span class="src-var">$i</span>\&quot;&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3829"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3830"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">&quot;&lt;span&nbsp;class=\&quot;xtra&nbsp;ln-xtra\&quot;&gt;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3831"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3832"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3833"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">&quot;&lt;span&nbsp;style=\&quot;display:block;&quot;</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">get_line_style</span><span class="src-sym">(</span><span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">&quot;\&quot;&gt;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3834"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3835"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$close</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3836"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3837"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers_start</span>&nbsp;+&nbsp;<span class="src-var">$i</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3838"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$close</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3839"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<a href="http://www.php.net/str_repeat">str_repeat</a><span class="src-sym">(</span><span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$close</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3840"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;!=&nbsp;<span class="src-var">$n</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3841"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">&quot;\n&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3842"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3843"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3844"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;/pre&gt;&lt;/td&gt;&lt;td'</span>.<span class="src-var">$attributes</span>.<span class="src-str">'&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3845"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3846"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;pre'</span>.&nbsp;<span class="src-var">$attributes</span>&nbsp;.<span class="src-str">'&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3847"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3848"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;No&nbsp;line&nbsp;numbers,&nbsp;but&nbsp;still&nbsp;need&nbsp;to&nbsp;handle&nbsp;highlighting&nbsp;lines&nbsp;extra.</span></span></div></li> <li><div class="src-line"><a name="a3849"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Have&nbsp;to&nbsp;use&nbsp;divs&nbsp;so&nbsp;the&nbsp;full&nbsp;width&nbsp;of&nbsp;the&nbsp;code&nbsp;is&nbsp;highlighted</span></span></div></li> <li><div class="src-line"><a name="a3850"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3851"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span>&nbsp;<span class="src-var">$i</span>&nbsp;<&nbsp;<span class="src-var">$n</span><span class="src-sym">;</span>&nbsp;++<span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3852"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Make&nbsp;lines&nbsp;have&nbsp;at&nbsp;least&nbsp;one&nbsp;space&nbsp;in&nbsp;them&nbsp;if&nbsp;they're&nbsp;empty</span></span></div></li> <li><div class="src-line"><a name="a3853"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;BenBE:&nbsp;Checking&nbsp;emptiness&nbsp;using&nbsp;trim&nbsp;instead&nbsp;of&nbsp;relying&nbsp;on&nbsp;blanks</span></span></div></li> <li><div class="src-line"><a name="a3854"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-str">''</span>&nbsp;==&nbsp;<a href="http://www.php.net/trim">trim</a><span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3855"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$code</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'&amp;nbsp;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3856"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3857"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;fancy&nbsp;lines</span></span></div></li> <li><div class="src-line"><a name="a3858"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_FANCY_LINE_NUMBERS&quot;&gt;GESHI_FANCY_LINE_NUMBERS&lt;/a&gt;</span>&nbsp;&amp;&amp;</span></div></li> <li><div class="src-line"><a name="a3859"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$i</span>&nbsp;%&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_nth_row</span>&nbsp;==&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_nth_row</span>&nbsp;-&nbsp;<span class="src-num">1</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3860"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Set&nbsp;the&nbsp;attributes&nbsp;to&nbsp;style&nbsp;the&nbsp;line</span></span></div></li> <li><div class="src-line"><a name="a3861"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3862"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;span&nbsp;class=&quot;xtra&nbsp;li2&quot;&gt;&lt;span&nbsp;class=&quot;de2&quot;&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3863"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3864"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;This&nbsp;style&nbsp;&quot;covers&nbsp;up&quot;&nbsp;the&nbsp;special&nbsp;styles&nbsp;set&nbsp;for&nbsp;special&nbsp;lines</span></span></div></li> <li><div class="src-line"><a name="a3865"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;so&nbsp;that&nbsp;styles&nbsp;applied&nbsp;to&nbsp;special&nbsp;lines&nbsp;don't&nbsp;apply&nbsp;to&nbsp;the&nbsp;actual</span></span></div></li> <li><div class="src-line"><a name="a3866"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;code&nbsp;on&nbsp;that&nbsp;line</span></span></div></li> <li><div class="src-line"><a name="a3867"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;span&nbsp;style=&quot;display:block;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_style2</span>&nbsp;.&nbsp;<span class="src-str">'&quot;&gt;'</span></span></div></li> <li><div class="src-line"><a name="a3868"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.<span class="src-str">'&lt;span&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">code_style</span>&nbsp;.<span class="src-str">'&quot;&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3869"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3870"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close</span>&nbsp;+=&nbsp;<span class="src-num">2</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3871"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3872"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Is&nbsp;this&nbsp;some&nbsp;line&nbsp;with&nbsp;extra&nbsp;styles???</span></span></div></li> <li><div class="src-line"><a name="a3873"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/in_array">in_array</a><span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-num">1</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3874"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3875"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines_styles</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3876"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">"</span></span>&lt;span&nbsp;class=\&quot;xtra&nbsp;lx<span class="src-var">$i</span>\&quot;&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3877"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3878"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">&quot;&lt;span&nbsp;class=\&quot;xtra&nbsp;ln-xtra\&quot;&gt;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3879"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3880"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3881"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">&quot;&lt;span&nbsp;style=\&quot;display:block;&quot;</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">get_line_style</span><span class="src-sym">(</span><span class="src-var">$i</span><span class="src-sym">)</span>&nbsp;.&nbsp;<span class="src-str">&quot;\&quot;&gt;&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3882"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3883"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$close</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3884"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3885"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3886"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-var">$code</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3887"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3888"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$close</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3889"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<a href="http://www.php.net/str_repeat">str_repeat</a><span class="src-sym">(</span><span class="src-str">'&lt;/span&gt;'</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$close</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3890"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close</span>&nbsp;=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3891"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3892"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">elseif</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$i</span>&nbsp;+&nbsp;<span class="src-num">1</span>&nbsp;<&nbsp;<span class="src-var">$n</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3893"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">&quot;\n&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3894"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3895"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$code</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3896"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3897"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3898"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_VALID&quot;&gt;GESHI_HEADER_PRE_VALID&lt;/a&gt;</span>&nbsp;||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_TABLE&quot;&gt;GESHI_HEADER_PRE_TABLE&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3899"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;/pre&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3900"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3901"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_TABLE&quot;&gt;GESHI_HEADER_PRE_TABLE&lt;/a&gt;</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS&quot;&gt;GESHI_NO_LINE_NUMBERS&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3902"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-str">'&lt;/td&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3903"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3904"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3905"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3906"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$parsed_code</span>&nbsp;.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">footer</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3907"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3908"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3909"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a3910"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Creates&nbsp;the&nbsp;header&nbsp;for&nbsp;the&nbsp;code&nbsp;block&nbsp;(with&nbsp;correct&nbsp;attributes)</span></div></li> <li><div class="src-line"><a name="a3911"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3912"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@return&nbsp;string&nbsp;The&nbsp;header&nbsp;for&nbsp;the&nbsp;code&nbsp;block</span></div></li> <li><div class="src-line"><a name="a3913"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a3914"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@access&nbsp;private</span></div></li> <li><div class="src-line"><a name="a3915"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a3916"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="http://www.php.net/header">header</a><span class="src-sym">(</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3917"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Get&nbsp;attributes&nbsp;needed</span></span></div></li> <li><div class="src-line"><a name="a3918"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a3919"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@todo&nbsp;&nbsp;&nbsp;Document&nbsp;behaviour&nbsp;change&nbsp;-&nbsp;class&nbsp;is&nbsp;outputted&nbsp;regardless&nbsp;of&nbsp;whether</span></div></li> <li><div class="src-line"><a name="a3920"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;we're&nbsp;using&nbsp;classes&nbsp;or&nbsp;not.&nbsp;Same&nbsp;with&nbsp;style</span></div></li> <li><div class="src-line"><a name="a3921"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a3922"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3923"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_class</span>&nbsp;!=&nbsp;<span class="src-str">''</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3924"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;.=&nbsp;<span class="src-str">&quot;&nbsp;&quot;</span>.<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_class</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3925"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3926"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;.=&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3927"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3928"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_id</span>&nbsp;!=&nbsp;<span class="src-str">''</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3929"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;.=&nbsp;<span class="src-str">"</span></span>&nbsp;id=\&quot;{<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_id</span><span class="src-sym">}</span>\&quot;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3930"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3931"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_style</span>&nbsp;!=&nbsp;<span class="src-str">''</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3932"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attributes</span>&nbsp;.=&nbsp;<span class="src-str">'&nbsp;style=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_style</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3933"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3934"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3935"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$ol_attributes</span>&nbsp;=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3936"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3937"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers_start</span>&nbsp;!=&nbsp;<span class="src-num">1</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3938"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$ol_attributes</span>&nbsp;.=&nbsp;<span class="src-str">'&nbsp;start=&quot;'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers_start</span>&nbsp;.&nbsp;<span class="src-str">'&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3939"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3940"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3941"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Get&nbsp;the&nbsp;header&nbsp;HTML</span></span></div></li> <li><div class="src-line"><a name="a3942"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$header</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_content</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3943"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$header</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3944"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE&quot;&gt;GESHI_HEADER_PRE&lt;/a&gt;</span>&nbsp;||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_VALID&quot;&gt;GESHI_HEADER_PRE_VALID&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3945"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$header</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">''</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$header</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3946"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3947"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$header</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">replace_keywords</span><span class="src-sym">(</span><span class="src-var">$header</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3948"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3949"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3950"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attr</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;head&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3951"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3952"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attr</span>&nbsp;=&nbsp;<span class="src-str">"</span></span>&nbsp;style=\&quot;{<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_content_style</span><span class="src-sym">}</span>\&quot;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3953"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3954"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">GESHI_HEADER_PRE_TABLE</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">GESHI_NO_LINE_NUMBERS</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3955"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$header</span>&nbsp;=&nbsp;</span><span class="src-str">&quot;</span>&lt;thead&gt;&lt;tr&gt;&lt;td&nbsp;colspan=\&quot;2\&quot;&nbsp;<span class="src-var">$attr</span>&gt;<span class="src-var">$header</span>&lt;/td&gt;&lt;/tr&gt;&lt;/thead&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3956"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3957"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$header</span>&nbsp;=&nbsp;</span><span class="src-str">&quot;</span>&lt;div<span class="src-var">$attr</span>&gt;<span class="src-var">$header</span>&lt;/div&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3958"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3959"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3960"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3961"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">GESHI_HEADER_NONE</span>&nbsp;==&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3962"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">GESHI_NO_LINE_NUMBERS</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3963"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;</span><span class="src-str">&quot;</span><span class="src-var">$header</span>&lt;ol<span class="src-var">$attributes$ol_attributes</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3964"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3965"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-var">$header</span>&nbsp;.&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">force_code_block</span>&nbsp;?&nbsp;<span class="src-str">'&lt;div&gt;'</span>&nbsp;:&nbsp;<span class="src-str">''</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3966"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3967"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3968"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Work&nbsp;out&nbsp;what&nbsp;to&nbsp;return&nbsp;and&nbsp;do&nbsp;it</span></span></div></li> <li><div class="src-line"><a name="a3969"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS&quot;&gt;GESHI_NO_LINE_NUMBERS&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3970"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE&quot;&gt;GESHI_HEADER_PRE&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3971"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-str">"</span></span>&lt;pre<span class="src-var">$attributes</span>&gt;<span class="src-var">$header</span>&lt;ol<span class="src-var">$ol_attributes</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3972"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">GESHI_HEADER_DIV</span>&nbsp;||</span></div></li> <li><div class="src-line"><a name="a3973"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">GESHI_HEADER_PRE_VALID</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3974"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;</span><span class="src-str">&quot;</span>&lt;div<span class="src-var">$attributes</span>&gt;<span class="src-var">$header</span>&lt;ol<span class="src-var">$ol_attributes</span>&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3975"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">GESHI_HEADER_PRE_TABLE</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3976"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;</span><span class="src-str">&quot;</span>&lt;table<span class="src-var">$attributes</span>&gt;<span class="src-var">$header</span>&lt;tbody&gt;&lt;tr&nbsp;class=\&quot;li1\&quot;&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3977"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3978"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3979"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">GESHI_HEADER_PRE</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3980"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;</span><span class="src-str">&quot;</span>&lt;pre<span class="src-var">$attributes</span>&gt;<span class="src-var">$header</span><span class="src-str">&quot;&nbsp;&nbsp;</span><span class="src-str">.</span></div></li> <li><div class="src-line"><a name="a3981"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">force_code_block</span>&nbsp;?&nbsp;<span class="src-str">'&lt;div&gt;'</span>&nbsp;:&nbsp;<span class="src-str">''</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3982"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3983"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-str">"</span></span>&lt;div<span class="src-var">$attributes</span>&gt;<span class="src-var">$header</span><span class="src-str">&quot;&nbsp;</span><span class="src-str">.</span></div></li> <li><div class="src-line"><a name="a3984"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">force_code_block</span>&nbsp;?&nbsp;<span class="src-str">'&lt;div&gt;'</span>&nbsp;:&nbsp;<span class="src-str">''</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3985"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3986"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3987"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a3988"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a3989"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a3990"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Returns&nbsp;the&nbsp;footer&nbsp;for&nbsp;the&nbsp;code&nbsp;block.</span></div></li> <li><div class="src-line"><a name="a3991"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a3992"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@return&nbsp;string&nbsp;The&nbsp;footer&nbsp;for&nbsp;the&nbsp;code&nbsp;block</span></div></li> <li><div class="src-line"><a name="a3993"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a3994"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@access&nbsp;private</span></div></li> <li><div class="src-line"><a name="a3995"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a3996"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">footer</span><span class="src-sym">(</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3997"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$footer</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">footer_content</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a3998"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$footer</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a3999"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE&quot;&gt;GESHI_HEADER_PRE&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4000"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$footer</span>&nbsp;=&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-str">&quot;\n&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-str">''</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$footer</span><span class="src-sym">)</span><span class="src-sym">;;</span></span></div></li> <li><div class="src-line"><a name="a4001"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4002"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$footer</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">replace_keywords</span><span class="src-sym">(</span><span class="src-var">$footer</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4003"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4004"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">use_classes</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4005"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attr</span>&nbsp;=&nbsp;<span class="src-str">'&nbsp;class=&quot;foot&quot;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4006"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4007"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$attr</span>&nbsp;=&nbsp;<span class="src-str">"</span></span>&nbsp;style=\&quot;{<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">footer_content_style</span><span class="src-sym">}</span>\&quot;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4008"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4009"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">GESHI_HEADER_PRE_TABLE</span>&nbsp;&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">linenumbers</span>&nbsp;!=&nbsp;<span class="src-id">GESHI_NO_LINE_NUMBERS</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4010"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$footer</span>&nbsp;=&nbsp;</span><span class="src-str">&quot;</span>&lt;tfoot&gt;&lt;tr&gt;&lt;td&nbsp;colspan=\&quot;2\&quot;&gt;<span class="src-var">$footer</span>&lt;/td&gt;&lt;/tr&gt;&lt;/tfoot&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4011"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4012"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$footer</span>&nbsp;=&nbsp;</span><span class="src-str">&quot;</span>&lt;div<span class="src-var">$attr</span>&gt;<span class="src-var">$footer</span>&lt;/div&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4013"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4014"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4015"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4016"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-id">GESHI_HEADER_NONE</span>&nbsp;==&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4017"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">GESHI_NO_LINE_NUMBERS</span><span class="src-sym">)</span>&nbsp;?&nbsp;<span class="src-str">'&lt;/ol&gt;'</span>&nbsp;.&nbsp;<span class="src-var">$footer</span>&nbsp;:&nbsp;<span class="src-var">$footer</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4018"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4019"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4020"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_DIV&quot;&gt;GESHI_HEADER_DIV&lt;/a&gt;</span>&nbsp;||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_HEADER_PRE_VALID&quot;&gt;GESHI_HEADER_PRE_VALID&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4021"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS&quot;&gt;GESHI_NO_LINE_NUMBERS&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4022"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-str">"</span></span>&lt;/ol&gt;<span class="src-var">$footer</span>&lt;/div&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4023"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4024"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">force_code_block</span>&nbsp;?&nbsp;<span class="src-str">'&lt;/div&gt;'</span>&nbsp;:&nbsp;<span class="src-str">''</span><span class="src-sym">)</span>&nbsp;.</span></div></li> <li><div class="src-line"><a name="a4025"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">"</span></span><span class="src-var">$footer</span>&lt;/div&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4026"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4027"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">elseif</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_type</span>&nbsp;==&nbsp;<span class="src-id">GESHI_HEADER_PRE_TABLE</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4028"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">GESHI_NO_LINE_NUMBERS</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4029"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;</span><span class="src-str">&quot;</span>&lt;/tr&gt;&lt;/tbody&gt;<span class="src-var">$footer</span>&lt;/table&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4030"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4031"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">force_code_block</span>&nbsp;?&nbsp;<span class="src-str">'&lt;/div&gt;'</span>&nbsp;:&nbsp;<span class="src-str">''</span><span class="src-sym">)</span>&nbsp;.</span></div></li> <li><div class="src-line"><a name="a4032"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">"</span></span><span class="src-var">$footer</span>&lt;/div&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4033"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4034"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4035"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">GESHI_NO_LINE_NUMBERS</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4036"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;</span><span class="src-str">&quot;</span>&lt;/ol&gt;<span class="src-var">$footer</span>&lt;/pre&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4037"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4038"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">force_code_block</span>&nbsp;?&nbsp;<span class="src-str">'&lt;/div&gt;'</span>&nbsp;:&nbsp;<span class="src-str">''</span><span class="src-sym">)</span>&nbsp;.</span></div></li> <li><div class="src-line"><a name="a4039"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">"</span></span><span class="src-var">$footer</span>&lt;/pre&gt;<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4040"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4041"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4042"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4043"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a4044"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Replaces&nbsp;certain&nbsp;keywords&nbsp;in&nbsp;the&nbsp;header&nbsp;and&nbsp;footer&nbsp;with</span></div></li> <li><div class="src-line"><a name="a4045"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;certain&nbsp;configuration&nbsp;values</span></div></li> <li><div class="src-line"><a name="a4046"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a4047"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;&nbsp;string&nbsp;The&nbsp;header&nbsp;or&nbsp;footer&nbsp;content&nbsp;to&nbsp;do&nbsp;replacement&nbsp;on</span></div></li> <li><div class="src-line"><a name="a4048"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@return&nbsp;string&nbsp;The&nbsp;header&nbsp;or&nbsp;footer&nbsp;with&nbsp;replaced&nbsp;keywords</span></div></li> <li><div class="src-line"><a name="a4049"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;&nbsp;1.0.2</span></div></li> <li><div class="src-line"><a name="a4050"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@access&nbsp;private</span></div></li> <li><div class="src-line"><a name="a4051"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a4052"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">replace_keywords</span><span class="src-sym">(</span><span class="src-var">$instr</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4053"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$keywords</span>&nbsp;=&nbsp;<span class="src-var">$replacements</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4054"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4055"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$keywords</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'&lt;TIME&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4056"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$keywords</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'{TIME}'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4057"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$replacements</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$replacements</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<a href="http://www.php.net/number_format">number_format</a><span class="src-sym">(</span><span class="src-var">$time</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodget_time">get_time</a><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">,</span>&nbsp;<span class="src-num">3</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4058"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4059"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$keywords</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'&lt;LANGUAGE&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4060"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$keywords</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'{LANGUAGE}'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4061"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$replacements</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$replacements</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'LANG_NAME'</span><span class="src-sym">]</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4062"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4063"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$keywords</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'&lt;VERSION&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4064"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$keywords</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'{VERSION}'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4065"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$replacements</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$replacements</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_VERSION&quot;&gt;GESHI_VERSION&lt;/a&gt;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4066"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4067"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$keywords</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'&lt;SPEED&gt;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4068"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$keywords</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'{SPEED}'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4069"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$time</span>&nbsp;&lt;=&nbsp;<span class="src-num">0</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4070"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$speed</span>&nbsp;=&nbsp;<span class="src-str">'N/A'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4071"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4072"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$speed</span>&nbsp;=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">source</span><span class="src-sym">)</span>&nbsp;/&nbsp;<span class="src-var">$time</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4073"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$speed</span>&nbsp;&gt;=&nbsp;<span class="src-num">1024</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4074"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$speed</span>&nbsp;=&nbsp;<a href="http://www.php.net/sprintf">sprintf</a><span class="src-sym">(</span><span class="src-str">&quot;%.2f&nbsp;KB/s&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$speed</span>&nbsp;/&nbsp;<span class="src-num">1024.0</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4075"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4076"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$speed</span>&nbsp;=&nbsp;<a href="http://www.php.net/sprintf">sprintf</a><span class="src-sym">(</span><span class="src-str">&quot;%.0f&nbsp;B/s&quot;</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$speed</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4077"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4078"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4079"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$replacements</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$replacements</span><span class="src-sym">[</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-var">$speed</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4080"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4081"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<a href="http://www.php.net/str_replace">str_replace</a><span class="src-sym">(</span><span class="src-var">$keywords</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$replacements</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$instr</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4082"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4083"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4084"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a4085"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Secure&nbsp;replacement&nbsp;for&nbsp;PHP&nbsp;built-in&nbsp;function&nbsp;htmlspecialchars().</span></div></li> <li><div class="src-line"><a name="a4086"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a4087"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;See&nbsp;ticket&nbsp;#427&nbsp;(http://wush.net/trac/wikka/ticket/427)&nbsp;for&nbsp;the&nbsp;rationale</span></div></li> <li><div class="src-line"><a name="a4088"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;for&nbsp;this&nbsp;replacement&nbsp;function.</span></div></li> <li><div class="src-line"><a name="a4089"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a4090"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;INTERFACE&nbsp;for&nbsp;this&nbsp;function&nbsp;is&nbsp;almost&nbsp;the&nbsp;same&nbsp;as&nbsp;that&nbsp;for</span></div></li> <li><div class="src-line"><a name="a4091"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;htmlspecialchars(),&nbsp;with&nbsp;the&nbsp;same&nbsp;default&nbsp;for&nbsp;quote&nbsp;style;&nbsp;however,&nbsp;there</span></div></li> <li><div class="src-line"><a name="a4092"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;is&nbsp;no&nbsp;'charset'&nbsp;parameter.&nbsp;The&nbsp;reason&nbsp;for&nbsp;this&nbsp;is&nbsp;as&nbsp;follows:</span></div></li> <li><div class="src-line"><a name="a4093"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a4094"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;The&nbsp;PHP&nbsp;docs&nbsp;say:</span></div></li> <li><div class="src-line"><a name="a4095"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&quot;The&nbsp;third&nbsp;argument&nbsp;charset&nbsp;defines&nbsp;character&nbsp;set&nbsp;used&nbsp;in&nbsp;conversion.&quot;</span></div></li> <li><div class="src-line"><a name="a4096"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a4097"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;I&nbsp;suspect&nbsp;PHP's&nbsp;htmlspecialchars()&nbsp;is&nbsp;working&nbsp;at&nbsp;the&nbsp;byte-value&nbsp;level&nbsp;and</span></div></li> <li><div class="src-line"><a name="a4098"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;thus&nbsp;_needs_&nbsp;to&nbsp;know&nbsp;(or&nbsp;asssume)&nbsp;a&nbsp;character&nbsp;set&nbsp;because&nbsp;the&nbsp;special</span></div></li> <li><div class="src-line"><a name="a4099"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;characters&nbsp;to&nbsp;be&nbsp;replaced&nbsp;could&nbsp;exist&nbsp;at&nbsp;different&nbsp;code&nbsp;points&nbsp;in</span></div></li> <li><div class="src-line"><a name="a4100"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;different&nbsp;character&nbsp;sets.&nbsp;(If&nbsp;indeed&nbsp;htmlspecialchars()&nbsp;works&nbsp;at</span></div></li> <li><div class="src-line"><a name="a4101"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;byte-value&nbsp;level&nbsp;that&nbsp;goes&nbsp;some&nbsp;&nbsp;way&nbsp;towards&nbsp;explaining&nbsp;why&nbsp;the</span></div></li> <li><div class="src-line"><a name="a4102"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;vulnerability&nbsp;would&nbsp;exist&nbsp;in&nbsp;this&nbsp;function,&nbsp;too,&nbsp;and&nbsp;not&nbsp;only&nbsp;in</span></div></li> <li><div class="src-line"><a name="a4103"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;htmlentities()&nbsp;which&nbsp;certainly&nbsp;is&nbsp;working&nbsp;at&nbsp;byte-value&nbsp;level.)</span></div></li> <li><div class="src-line"><a name="a4104"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a4105"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;This&nbsp;replacement&nbsp;function&nbsp;however&nbsp;works&nbsp;at&nbsp;character&nbsp;level&nbsp;and&nbsp;should</span></div></li> <li><div class="src-line"><a name="a4106"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;therefore&nbsp;be&nbsp;&quot;immune&quot;&nbsp;to&nbsp;character&nbsp;set&nbsp;differences&nbsp;-&nbsp;so&nbsp;no&nbsp;charset</span></div></li> <li><div class="src-line"><a name="a4107"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;parameter&nbsp;is&nbsp;needed&nbsp;or&nbsp;provided.&nbsp;If&nbsp;a&nbsp;third&nbsp;parameter&nbsp;is&nbsp;passed,&nbsp;it&nbsp;will</span></div></li> <li><div class="src-line"><a name="a4108"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;be&nbsp;silently&nbsp;ignored.</span></div></li> <li><div class="src-line"><a name="a4109"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a4110"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;In&nbsp;the&nbsp;OUTPUT&nbsp;there&nbsp;is&nbsp;a&nbsp;minor&nbsp;difference&nbsp;in&nbsp;that&nbsp;we&nbsp;use&nbsp;'&amp;#39;'&nbsp;instead</span></div></li> <li><div class="src-line"><a name="a4111"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;of&nbsp;PHP's&nbsp;'&amp;#039;'&nbsp;for&nbsp;a&nbsp;single&nbsp;quote:&nbsp;this&nbsp;provides&nbsp;compatibility&nbsp;with</span></div></li> <li><div class="src-line"><a name="a4112"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;get_html_translation_table(HTML_SPECIALCHARS,&nbsp;ENT_QUOTES)</span></div></li> <li><div class="src-line"><a name="a4113"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;(see&nbsp;comment&nbsp;by&nbsp;mikiwoz&nbsp;at&nbsp;yahoo&nbsp;dot&nbsp;co&nbsp;dot&nbsp;uk&nbsp;on</span></div></li> <li><div class="src-line"><a name="a4114"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;http://php.net/htmlspecialchars);&nbsp;it&nbsp;also&nbsp;matches&nbsp;the&nbsp;entity&nbsp;definition</span></div></li> <li><div class="src-line"><a name="a4115"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;for&nbsp;XML&nbsp;1.0</span></div></li> <li><div class="src-line"><a name="a4116"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;(http://www.w3.org/TR/xhtml1/dtds.html#a_dtd_Special_characters).</span></div></li> <li><div class="src-line"><a name="a4117"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Like&nbsp;PHP&nbsp;we&nbsp;use&nbsp;a&nbsp;numeric&nbsp;character&nbsp;reference&nbsp;instead&nbsp;of&nbsp;'&amp;apos;'&nbsp;for&nbsp;the</span></div></li> <li><div class="src-line"><a name="a4118"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;single&nbsp;quote.&nbsp;For&nbsp;the&nbsp;other&nbsp;special&nbsp;characters&nbsp;we&nbsp;use&nbsp;the&nbsp;named&nbsp;entity</span></div></li> <li><div class="src-line"><a name="a4119"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;references,&nbsp;as&nbsp;PHP&nbsp;is&nbsp;doing.</span></div></li> <li><div class="src-line"><a name="a4120"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a4121"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@author&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{@link&nbsp;http://wikkawiki.org/JavaWoman&nbsp;Marjolein&nbsp;Katsma}</span></div></li> <li><div class="src-line"><a name="a4122"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a4123"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@license&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;http://www.gnu.org/copyleft/lgpl.html</span></div></li> <li><div class="src-line"><a name="a4124"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;GNU&nbsp;Lesser&nbsp;General&nbsp;Public&nbsp;License</span></div></li> <li><div class="src-line"><a name="a4125"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@copyright&nbsp;&nbsp;&nbsp;Copyright&nbsp;2007,&nbsp;{@link&nbsp;http://wikkawiki.org/CreditsPage</span></div></li> <li><div class="src-line"><a name="a4126"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Wikka&nbsp;Development&nbsp;Team}</span></div></li> <li><div class="src-line"><a name="a4127"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a4128"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@access&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private</span></div></li> <li><div class="src-line"><a name="a4129"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;string&nbsp;&nbsp;$string&nbsp;string&nbsp;to&nbsp;be&nbsp;converted</span></div></li> <li><div class="src-line"><a name="a4130"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;integer&nbsp;$quote_style</span></div></li> <li><div class="src-line"><a name="a4131"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;ENT_COMPAT:&nbsp;&nbsp;&nbsp;escapes&nbsp;&amp;,&nbsp;&lt;,&nbsp;&gt;&nbsp;and&nbsp;double&nbsp;quote&nbsp;(default)</span></div></li> <li><div class="src-line"><a name="a4132"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;ENT_NOQUOTES:&nbsp;escapes&nbsp;only&nbsp;&amp;,&nbsp;&lt;&nbsp;and&nbsp;&gt;</span></div></li> <li><div class="src-line"><a name="a4133"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;ENT_QUOTES:&nbsp;&nbsp;&nbsp;escapes&nbsp;&amp;,&nbsp;&lt;,&nbsp;&gt;,&nbsp;double&nbsp;and&nbsp;single&nbsp;quotes</span></div></li> <li><div class="src-line"><a name="a4134"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@return&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;string&nbsp;&nbsp;converted&nbsp;string</span></div></li> <li><div class="src-line"><a name="a4135"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1.0.7.18</span></div></li> <li><div class="src-line"><a name="a4136"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a4137"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<span class="src-id">hsc</span><span class="src-sym">(</span><span class="src-var">$string</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$quote_style</span>&nbsp;=&nbsp;<span class="src-id">ENT_COMPAT</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4138"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;init</span></span></div></li> <li><div class="src-line"><a name="a4139"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">static</span>&nbsp;<span class="src-var">$aTransSpecchar</span>&nbsp;=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span></span></div></li> <li><div class="src-line"><a name="a4140"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&amp;'</span>&nbsp;=&gt;&nbsp;<span class="src-str">'&amp;amp;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a4141"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&quot;'</span>&nbsp;=&gt;&nbsp;<span class="src-str">'&amp;quot;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a4142"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&lt;'</span>&nbsp;=&gt;&nbsp;<span class="src-str">'&amp;lt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a4143"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'&gt;'</span>&nbsp;=&gt;&nbsp;<span class="src-str">'&amp;gt;'</span><span class="src-sym">,</span></span></div></li> <li><div class="src-line"><a name="a4144"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4145"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//This&nbsp;fix&nbsp;is&nbsp;related&nbsp;to&nbsp;SF#1923020,&nbsp;but&nbsp;has&nbsp;to&nbsp;be&nbsp;applied</span></span></div></li> <li><div class="src-line"><a name="a4146"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//regardless&nbsp;of&nbsp;actually&nbsp;highlighting&nbsp;symbols.</span></span></div></li> <li><div class="src-line"><a name="a4147"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a4148"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Circumvent&nbsp;a&nbsp;bug&nbsp;with&nbsp;symbol&nbsp;highlighting</span></span></div></li> <li><div class="src-line"><a name="a4149"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//This&nbsp;is&nbsp;required&nbsp;as&nbsp;;&nbsp;would&nbsp;produce&nbsp;undesirable&nbsp;side-effects&nbsp;if&nbsp;it</span></span></div></li> <li><div class="src-line"><a name="a4150"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//was&nbsp;not&nbsp;to&nbsp;be&nbsp;processed&nbsp;as&nbsp;an&nbsp;entity.</span></span></div></li> <li><div class="src-line"><a name="a4151"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">';'</span>&nbsp;=&gt;&nbsp;<span class="src-str">'&lt;SEMI&gt;'</span><span class="src-sym">,</span>&nbsp;<span class="src-comm">//&nbsp;Force&nbsp;;&nbsp;to&nbsp;be&nbsp;processed&nbsp;as&nbsp;entity</span></span></div></li> <li><div class="src-line"><a name="a4152"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'|'</span>&nbsp;=&gt;&nbsp;<span class="src-str">'&lt;PIPE&gt;'</span>&nbsp;<span class="src-comm">//&nbsp;Force&nbsp;|&nbsp;to&nbsp;be&nbsp;processed&nbsp;as&nbsp;entity</span></span></div></li> <li><div class="src-line"><a name="a4153"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">)</span><span class="src-sym">;</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;ENT_COMPAT&nbsp;set</span></span></div></li> <li><div class="src-line"><a name="a4154"></a></span><span class="src-str"><span class="src-comm"></span></span></div></li> <li><div class="src-line"><a name="a4155"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">switch</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$quote_style</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4156"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">case</span>&nbsp;<span class="src-id">ENT_NOQUOTES</span>:&nbsp;<span class="src-comm">//&nbsp;don't&nbsp;convert&nbsp;double&nbsp;quotes</span></span></div></li> <li><div class="src-line"><a name="a4157"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$aTransSpecchar</span><span class="src-sym">[</span><span class="src-str">'&quot;'</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4158"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4159"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">case</span>&nbsp;<span class="src-id">ENT_QUOTES</span>:&nbsp;<span class="src-comm">//&nbsp;convert&nbsp;single&nbsp;quotes&nbsp;as&nbsp;well</span></span></div></li> <li><div class="src-line"><a name="a4160"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$aTransSpecchar</span><span class="src-sym">[</span><span class="src-str">&quot;'&quot;</span><span class="src-sym">]</span>&nbsp;=&nbsp;<span class="src-str">'&amp;#39;'</span><span class="src-sym">;</span>&nbsp;<span class="src-comm">//&nbsp;(apos)&nbsp;htmlspecialchars()&nbsp;uses&nbsp;'&amp;#039;'</span></span></div></li> <li><div class="src-line"><a name="a4161"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4162"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4163"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4164"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;return&nbsp;translated&nbsp;string</span></span></div></li> <li><div class="src-line"><a name="a4165"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<a href="http://www.php.net/strtr">strtr</a><span class="src-sym">(</span><span class="src-var">$string</span><span class="src-sym">,</span>&nbsp;<span class="src-var">$aTransSpecchar</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4166"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4167"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4168"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;/**</span></div></li> <li><div class="src-line"><a name="a4169"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Returns&nbsp;a&nbsp;stylesheet&nbsp;for&nbsp;the&nbsp;highlighted&nbsp;code.&nbsp;If&nbsp;$economy&nbsp;mode</span></div></li> <li><div class="src-line"><a name="a4170"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;is&nbsp;true,&nbsp;we&nbsp;only&nbsp;return&nbsp;the&nbsp;stylesheet&nbsp;declarations&nbsp;that&nbsp;matter&nbsp;for</span></div></li> <li><div class="src-line"><a name="a4171"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;this&nbsp;code&nbsp;block&nbsp;instead&nbsp;of&nbsp;the&nbsp;whole&nbsp;thing</span></div></li> <li><div class="src-line"><a name="a4172"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</span></div></li> <li><div class="src-line"><a name="a4173"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;&nbsp;boolean&nbsp;Whether&nbsp;to&nbsp;use&nbsp;economy&nbsp;mode&nbsp;or&nbsp;not</span></div></li> <li><div class="src-line"><a name="a4174"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@return&nbsp;string&nbsp;A&nbsp;stylesheet&nbsp;built&nbsp;on&nbsp;the&nbsp;data&nbsp;for&nbsp;the&nbsp;current&nbsp;language</span></div></li> <li><div class="src-line"><a name="a4175"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;&nbsp;1.0.0</span></div></li> <li><div class="src-line"><a name="a4176"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li> <li><div class="src-line"><a name="a4177"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function</span>&nbsp;<a href="../geshi/core/GeSHi.html#methodget_stylesheet">get_stylesheet</a><span class="src-sym">(</span><span class="src-var">$economy_mode</span>&nbsp;=&nbsp;<span class="src-id">true</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4178"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;If&nbsp;there's&nbsp;an&nbsp;error,&nbsp;chances&nbsp;are&nbsp;that&nbsp;the&nbsp;language&nbsp;file</span></span></div></li> <li><div class="src-line"><a name="a4179"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;won't&nbsp;have&nbsp;populated&nbsp;the&nbsp;language&nbsp;data&nbsp;file,&nbsp;so&nbsp;we&nbsp;can't</span></span></div></li> <li><div class="src-line"><a name="a4180"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;risk&nbsp;getting&nbsp;a&nbsp;stylesheet...</span></span></div></li> <li><div class="src-line"><a name="a4181"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methoderror">error</a><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4182"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return</span>&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4183"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4184"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4185"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//Check&nbsp;if&nbsp;the&nbsp;style&nbsp;rearrangements&nbsp;have&nbsp;been&nbsp;processed&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a4186"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//This&nbsp;also&nbsp;does&nbsp;some&nbsp;preprocessing&nbsp;to&nbsp;check&nbsp;which&nbsp;style&nbsp;groups&nbsp;are&nbsp;useable&nbsp;...</span></span></div></li> <li><div class="src-line"><a name="a4187"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'NUMBERS_CACHE'</span><span class="src-sym">]</span><span class="src-sym">))</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4188"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">build_style_cache</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4189"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4190"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4191"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;First,&nbsp;work&nbsp;out&nbsp;what&nbsp;the&nbsp;selector&nbsp;should&nbsp;be.&nbsp;If&nbsp;there's&nbsp;an&nbsp;ID,</span></span></div></li> <li><div class="src-line"><a name="a4192"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;that&nbsp;should&nbsp;be&nbsp;used,&nbsp;the&nbsp;same&nbsp;for&nbsp;a&nbsp;class.&nbsp;Otherwise,&nbsp;a&nbsp;selector</span></span></div></li> <li><div class="src-line"><a name="a4193"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;of&nbsp;''&nbsp;means&nbsp;that&nbsp;these&nbsp;styles&nbsp;will&nbsp;be&nbsp;applied&nbsp;anywhere</span></span></div></li> <li><div class="src-line"><a name="a4194"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_id</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4195"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$selector</span>&nbsp;=&nbsp;<span class="src-str">'#'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_id</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4196"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4197"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$selector</span>&nbsp;=&nbsp;<span class="src-str">'.'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4198"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_class</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4199"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$selector</span>&nbsp;.=&nbsp;<span class="src-str">'.'</span>&nbsp;.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_class</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4200"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4201"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4202"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$selector</span>&nbsp;.=&nbsp;<span class="src-str">'&nbsp;'</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4203"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4204"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Header&nbsp;of&nbsp;the&nbsp;stylesheet</span></span></div></li> <li><div class="src-line"><a name="a4205"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$economy_mode</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4206"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet</span>&nbsp;=&nbsp;<span class="src-str">&quot;/**\n&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a4207"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;&nbsp;*&nbsp;GeSHi&nbsp;Dynamically&nbsp;Generated&nbsp;Stylesheet\n&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a4208"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;&nbsp;*&nbsp;--------------------------------------\n&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a4209"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">"</span></span>&nbsp;*&nbsp;Dynamically&nbsp;generated&nbsp;stylesheet&nbsp;for&nbsp;{<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language</span><span class="src-sym">}</span>\n<span class="src-str">&quot;</span><span class="src-str">.</span></div></li> <li><div class="src-line"><a name="a4210"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="src-str">&quot;</span>&nbsp;*&nbsp;CSS&nbsp;class:&nbsp;{<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_class</span><span class="src-sym">}</span>,&nbsp;CSS&nbsp;id:&nbsp;{<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_id</span><span class="src-sym">}</span>\n<span class="src-str">&quot;</span><span class="src-str">.</span></div></li> <li><div class="src-line"><a name="a4211"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;&nbsp;*&nbsp;GeSHi&nbsp;(C)&nbsp;2004&nbsp;-&nbsp;2007&nbsp;Nigel&nbsp;McNie,&nbsp;2007&nbsp;-&nbsp;2008&nbsp;Benny&nbsp;Baumann\n&quot;</span>&nbsp;.</span></div></li> <li><div class="src-line"><a name="a4212"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;&nbsp;*&nbsp;(http://qbnz.com/highlighter/&nbsp;and&nbsp;http://geshi.org/)\n&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a4213"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;&nbsp;*&nbsp;--------------------------------------\n&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a4214"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;&nbsp;*/\n&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4215"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span>&nbsp;<span class="src-key">else</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4216"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet</span>&nbsp;=&nbsp;<span class="src-str">&quot;/**\n&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a4217"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;&nbsp;*&nbsp;GeSHi&nbsp;(C)&nbsp;2004&nbsp;-&nbsp;2007&nbsp;Nigel&nbsp;McNie,&nbsp;2007&nbsp;-&nbsp;2008&nbsp;Benny&nbsp;Baumann\n&quot;</span>&nbsp;.</span></div></li> <li><div class="src-line"><a name="a4218"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;&nbsp;*&nbsp;(http://qbnz.com/highlighter/&nbsp;and&nbsp;http://geshi.org/)\n&quot;</span>.</span></div></li> <li><div class="src-line"><a name="a4219"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">&quot;&nbsp;*/\n&quot;</span><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4220"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4221"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4222"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Set&nbsp;the&nbsp;&lt;ol&gt;&nbsp;to&nbsp;have&nbsp;no&nbsp;effect&nbsp;at&nbsp;all&nbsp;if&nbsp;there&nbsp;are&nbsp;line&nbsp;numbers</span></span></div></li> <li><div class="src-line"><a name="a4223"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;(&lt;ol&gt;s&nbsp;have&nbsp;margins&nbsp;that&nbsp;should&nbsp;be&nbsp;destroyed&nbsp;so&nbsp;all&nbsp;layout&nbsp;is</span></span></div></li> <li><div class="src-line"><a name="a4224"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;controlled&nbsp;by&nbsp;the&nbsp;set_overall_style&nbsp;method,&nbsp;which&nbsp;works&nbsp;on&nbsp;the</span></span></div></li> <li><div class="src-line"><a name="a4225"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;&lt;pre&gt;&nbsp;or&nbsp;&lt;div&gt;&nbsp;container).&nbsp;Additionally,&nbsp;set&nbsp;default&nbsp;styles&nbsp;for&nbsp;lines</span></span></div></li> <li><div class="src-line"><a name="a4226"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$economy_mode</span>&nbsp;||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers</span>&nbsp;!=&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS&quot;&gt;GESHI_NO_LINE_NUMBERS&lt;/a&gt;</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4227"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//$stylesheet&nbsp;.=&nbsp;&quot;$selector,&nbsp;{$selector}ol,&nbsp;{$selector}ol&nbsp;li&nbsp;{margin:&nbsp;0;}\n&quot;;</span></span></div></li> <li><div class="src-line"><a name="a4228"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet</span>&nbsp;.=&nbsp;<span class="src-str">"</span></span><span class="src-var">$selector</span>.de1,&nbsp;<span class="src-var">$selector</span>.de2&nbsp;{{<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">code_style</span><span class="src-sym">}</span>}\n<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4229"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4230"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4231"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Add&nbsp;overall&nbsp;styles</span></span></div></li> <li><div class="src-line"><a name="a4232"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;note:&nbsp;neglect&nbsp;economy_mode,&nbsp;empty&nbsp;styles&nbsp;are&nbsp;meaningless</span></span></div></li> <li><div class="src-line"><a name="a4233"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_style</span>&nbsp;!=&nbsp;<span class="src-str">''</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4234"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet</span>&nbsp;.=&nbsp;<span class="src-str">"</span></span><span class="src-var">$selector</span>&nbsp;{{<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">overall_style</span><span class="src-sym">}</span>}\n<span class="src-str">&quot;</span><span class="src-str"><span class="src-sym">;</span></span></div></li> <li><div class="src-line"><a name="a4235"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></span></div></li> <li><div class="src-line"><a name="a4236"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4237"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Add&nbsp;styles&nbsp;for&nbsp;links</span></span></div></li> <li><div class="src-line"><a name="a4238"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;note:&nbsp;economy&nbsp;mode&nbsp;does&nbsp;not&nbsp;make&nbsp;_any_&nbsp;sense&nbsp;here</span></span></div></li> <li><div class="src-line"><a name="a4239"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;either&nbsp;the&nbsp;style&nbsp;is&nbsp;empty&nbsp;and&nbsp;thus&nbsp;no&nbsp;selector&nbsp;is&nbsp;needed</span></span></div></li> <li><div class="src-line"><a name="a4240"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;or&nbsp;the&nbsp;appropriate&nbsp;key&nbsp;is&nbsp;given.</span></span></div></li> <li><div class="src-line"><a name="a4241"></a></span><span class="src-str"><span class="src-comm"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">link_styles</span>&nbsp;<span class="src-key">as</span>&nbsp;<span class="src-var">$key</span>&nbsp;=&gt;&nbsp;<span class="src-var">$style</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4242"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$style</span>&nbsp;!=&nbsp;<span class="src-str">''</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4243"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">switch</span>&nbsp;<span class="src-sym">(</span><span class="src-var">$key</span><span class="src-sym">)</span>&nbsp;<span class="src-sym">{</span></span></div></li> <li><div class="src-line"><a name="a4244"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">case</span>&nbsp;<span class="src-id">&lt;a&nbsp;href=&quot;../geshi/core/_geshi.php.html#defineGESHI_LINK&quot;&gt;GESHI_LINK&lt;/a&gt;</span>:</span></div></li> <li><div class="src-line"><a name="a4245"></a></span><span class="src-str">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet</span>&nbsp;.=&nbsp;<span class="src-str">"</span>{<span class="src-var">$selector</span><span class="src-sym">}</span>a:link&nbsp;{{<span class="src-var">$style</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4246"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4247"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">case&nbsp;</span><span class="src-id"><a href="../geshi/core/_geshi.php.html#defineGESHI_HOVER">GESHI_HOVER</a></span>:</div></li> <li><div class="src-line"><a name="a4248"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span>{<span class="src-var">$selector</span><span class="src-str"></span><span class="src-sym">}</span>a:hover&nbsp;{{<span class="src-var">$style</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4249"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4250"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">case&nbsp;</span><span class="src-id"><a href="../geshi/core/_geshi.php.html#defineGESHI_ACTIVE">GESHI_ACTIVE</a></span>:</div></li> <li><div class="src-line"><a name="a4251"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span>{<span class="src-var">$selector</span><span class="src-str"></span><span class="src-sym">}</span>a:active&nbsp;{{<span class="src-var">$style</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4252"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4253"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">case&nbsp;</span><span class="src-id"><a href="../geshi/core/_geshi.php.html#defineGESHI_VISITED">GESHI_VISITED</a></span>:</div></li> <li><div class="src-line"><a name="a4254"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span>{<span class="src-var">$selector</span><span class="src-str"></span><span class="src-sym">}</span>a:visited&nbsp;{{<span class="src-var">$style</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4255"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4256"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4257"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4258"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4259"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4260"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Header&nbsp;and&nbsp;footer</span></div></li> <li><div class="src-line"><a name="a4261"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;note:&nbsp;neglect&nbsp;economy_mode,&nbsp;empty&nbsp;styles&nbsp;are&nbsp;meaningless</span></div></li> <li><div class="src-line"><a name="a4262"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">header_content_style&nbsp;</span>!=&nbsp;<span class="src-str">''</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4263"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.head&nbsp;{{<span class="src-var">$this</span></span><span class="src-sym">-&gt;</span><span class="src-id">header_content_style</span><span class="src-str"></span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4264"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4265"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">footer_content_style&nbsp;</span>!=&nbsp;<span class="src-str">''</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4266"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.foot&nbsp;{{<span class="src-var">$this</span></span><span class="src-sym">-&gt;</span><span class="src-id">footer_content_style</span><span class="src-str"></span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4267"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4268"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4269"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Styles&nbsp;for&nbsp;important&nbsp;stuff</span></div></li> <li><div class="src-line"><a name="a4270"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;note:&nbsp;neglect&nbsp;economy_mode,&nbsp;empty&nbsp;styles&nbsp;are&nbsp;meaningless</span></div></li> <li><div class="src-line"><a name="a4271"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">important_styles&nbsp;</span>!=&nbsp;<span class="src-str">''</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4272"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.imp&nbsp;{{<span class="src-var">$this</span></span><span class="src-sym">-&gt;</span><span class="src-id">important_styles</span><span class="src-str"></span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4273"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4274"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4275"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Simple&nbsp;line&nbsp;number&nbsp;styles</span></div></li> <li><div class="src-line"><a name="a4276"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">((</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers&nbsp;</span>!=&nbsp;<span class="src-id"><a href="../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS">GESHI_NO_LINE_NUMBERS</a></span><span class="src-sym">)&nbsp;</span>&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_style1&nbsp;</span>!=&nbsp;<span class="src-str">''</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4277"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span>{<span class="src-var">$selector</span><span class="src-str"></span><span class="src-sym">}</span>li,&nbsp;{<span class="src-var">$selector</span><span class="src-sym">}</span>.li1&nbsp;{{<span class="src-var">$this</span></span><span class="src-sym">-&gt;</span><span class="src-id">line_style1</span><span class="src-str"></span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4278"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4279"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">((</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers&nbsp;</span>!=&nbsp;<span class="src-id"><a href="../geshi/core/_geshi.php.html#defineGESHI_NO_LINE_NUMBERS">GESHI_NO_LINE_NUMBERS</a></span><span class="src-sym">)&nbsp;</span>&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">table_linenumber_style&nbsp;</span>!=&nbsp;<span class="src-str">''</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4280"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span>{<span class="src-var">$selector</span><span class="src-str"></span><span class="src-sym">}</span>.ln&nbsp;{{<span class="src-var">$this</span></span><span class="src-sym">-&gt;</span><span class="src-id">table_linenumber_style</span><span class="src-str"></span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4281"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4282"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;If&nbsp;there&nbsp;is&nbsp;a&nbsp;style&nbsp;set&nbsp;for&nbsp;fancy&nbsp;line&nbsp;numbers,&nbsp;echo&nbsp;it&nbsp;out</span></div></li> <li><div class="src-line"><a name="a4283"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">((</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_numbers&nbsp;</span>==&nbsp;<span class="src-id"><a href="../geshi/core/_geshi.php.html#defineGESHI_FANCY_LINE_NUMBERS">GESHI_FANCY_LINE_NUMBERS</a></span><span class="src-sym">)&nbsp;</span>&amp;&amp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">line_style2&nbsp;</span>!=&nbsp;<span class="src-str">''</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4284"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span>{<span class="src-var">$selector</span><span class="src-str"></span><span class="src-sym">}</span>.li2&nbsp;{{<span class="src-var">$this</span></span><span class="src-sym">-&gt;</span><span class="src-id">line_style2</span><span class="src-str"></span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4285"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4286"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4287"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;note:&nbsp;empty&nbsp;styles&nbsp;are&nbsp;meaningless</span></div></li> <li><div class="src-line"><a name="a4288"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]&nbsp;</span><span class="src-key">as&nbsp;</span><span class="src-var">$group&nbsp;</span>=&gt;&nbsp;<span class="src-var">$styles</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4289"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$styles&nbsp;</span>!=&nbsp;<span class="src-str">''&nbsp;</span>&amp;&amp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||</div></li> <li><div class="src-line"><a name="a4290"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span><span class="src-sym">)&nbsp;</span>&amp;&amp;</div></li> <li><div class="src-line"><a name="a4291"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'KEYWORDS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span><span class="src-sym">)))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4292"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.kw<span class="src-var">$group</span>&nbsp;{{<span class="src-var">$styles</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4293"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4294"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4295"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]&nbsp;</span><span class="src-key">as&nbsp;</span><span class="src-var">$group&nbsp;</span>=&gt;&nbsp;<span class="src-var">$styles</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4296"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$styles&nbsp;</span>!=&nbsp;<span class="src-str">''&nbsp;</span>&amp;&amp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||</div></li> <li><div class="src-line"><a name="a4297"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span><span class="src-sym">)&nbsp;</span>&amp;&amp;</div></li> <li><div class="src-line"><a name="a4298"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'COMMENTS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span><span class="src-sym">)&nbsp;</span>||</div></li> <li><div class="src-line"><a name="a4299"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'COMMENT_REGEXP'</span><span class="src-sym">]</span><span class="src-sym">)&nbsp;</span>&amp;&amp;</div></li> <li><div class="src-line"><a name="a4300"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'COMMENT_REGEXP'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span><span class="src-sym">))))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4301"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.co<span class="src-var">$group</span>&nbsp;{{<span class="src-var">$styles</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4302"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4303"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4304"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]&nbsp;</span><span class="src-key">as&nbsp;</span><span class="src-var">$group&nbsp;</span>=&gt;&nbsp;<span class="src-var">$styles</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4305"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$styles&nbsp;</span>!=&nbsp;<span class="src-str">''&nbsp;</span>&amp;&amp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'ESCAPE_CHAR'</span><span class="src-sym">]</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4306"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;NEW:&nbsp;since&nbsp;1.0.8&nbsp;we&nbsp;have&nbsp;to&nbsp;handle&nbsp;hardescapes</span></div></li> <li><div class="src-line"><a name="a4307"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$group&nbsp;</span>===&nbsp;<span class="src-str">'HARD'</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4308"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$group&nbsp;</span>=&nbsp;<span class="src-str">'_h'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4309"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4310"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.es<span class="src-var">$group</span>&nbsp;{{<span class="src-var">$styles</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4311"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4312"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4313"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]&nbsp;</span><span class="src-key">as&nbsp;</span><span class="src-var">$group&nbsp;</span>=&gt;&nbsp;<span class="src-var">$styles</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4314"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$styles&nbsp;</span>!=&nbsp;<span class="src-str">''&nbsp;</span>&amp;&amp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'BRACKETS'</span><span class="src-sym">]</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4315"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.br<span class="src-var">$group</span>&nbsp;{{<span class="src-var">$styles</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4316"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4317"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4318"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]&nbsp;</span><span class="src-key">as&nbsp;</span><span class="src-var">$group&nbsp;</span>=&gt;&nbsp;<span class="src-var">$styles</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4319"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$styles&nbsp;</span>!=&nbsp;<span class="src-str">''&nbsp;</span>&amp;&amp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'SYMBOLS'</span><span class="src-sym">]</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4320"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.sy<span class="src-var">$group</span>&nbsp;{{<span class="src-var">$styles</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4321"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4322"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4323"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'STRINGS'</span><span class="src-sym">]&nbsp;</span><span class="src-key">as&nbsp;</span><span class="src-var">$group&nbsp;</span>=&gt;&nbsp;<span class="src-var">$styles</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4324"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$styles&nbsp;</span>!=&nbsp;<span class="src-str">''&nbsp;</span>&amp;&amp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'STRINGS'</span><span class="src-sym">]</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4325"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;NEW:&nbsp;since&nbsp;1.0.8&nbsp;we&nbsp;have&nbsp;to&nbsp;handle&nbsp;hardquotes</span></div></li> <li><div class="src-line"><a name="a4326"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$group&nbsp;</span>===&nbsp;<span class="src-str">'HARD'</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4327"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$group&nbsp;</span>=&nbsp;<span class="src-str">'_h'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4328"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4329"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.st<span class="src-var">$group</span>&nbsp;{{<span class="src-var">$styles</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4330"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4331"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4332"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]&nbsp;</span><span class="src-key">as&nbsp;</span><span class="src-var">$group&nbsp;</span>=&gt;&nbsp;<span class="src-var">$styles</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4333"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$styles&nbsp;</span>!=&nbsp;<span class="src-str">''&nbsp;</span>&amp;&amp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'NUMBERS'</span><span class="src-sym">]</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4334"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.nu<span class="src-var">$group</span>&nbsp;{{<span class="src-var">$styles</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4335"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4336"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4337"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'METHODS'</span><span class="src-sym">]&nbsp;</span><span class="src-key">as&nbsp;</span><span class="src-var">$group&nbsp;</span>=&gt;&nbsp;<span class="src-var">$styles</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4338"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$styles&nbsp;</span>!=&nbsp;<span class="src-str">''&nbsp;</span>&amp;&amp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'METHODS'</span><span class="src-sym">]</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4339"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.me<span class="src-var">$group</span>&nbsp;{{<span class="src-var">$styles</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4340"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4341"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4342"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;note:&nbsp;neglect&nbsp;economy_mode,&nbsp;empty&nbsp;styles&nbsp;are&nbsp;meaningless</span></div></li> <li><div class="src-line"><a name="a4343"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'SCRIPT'</span><span class="src-sym">]&nbsp;</span><span class="src-key">as&nbsp;</span><span class="src-var">$group&nbsp;</span>=&gt;&nbsp;<span class="src-var">$styles</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4344"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$styles&nbsp;</span>!=&nbsp;<span class="src-str">''</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4345"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.sc<span class="src-var">$group</span>&nbsp;{{<span class="src-var">$styles</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4346"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4347"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4348"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'STYLES'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]&nbsp;</span><span class="src-key">as&nbsp;</span><span class="src-var">$group&nbsp;</span>=&gt;&nbsp;<span class="src-var">$styles</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4349"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$styles&nbsp;</span>!=&nbsp;<span class="src-str">''&nbsp;</span>&amp;&amp;&nbsp;<span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||</div></li> <li><div class="src-line"><a name="a4350"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span><span class="src-sym">)&nbsp;</span>&amp;&amp;</div></li> <li><div class="src-line"><a name="a4351"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">lexic_permissions</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span><span class="src-sym">)))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4352"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><a href="http://www.php.net/is_array">is_array</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span><span class="src-sym">)&nbsp;</span>&amp;&amp;</div></li> <li><div class="src-line"><a name="a4353"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/array_key_exists">array_key_exists</a><span class="src-sym">(</span><span class="src-id">GESHI_CLASS</span><span class="src-sym">,&nbsp;</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4354"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4355"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">language_data</span><span class="src-sym">[</span><span class="src-str">'REGEXPS'</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$group</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-id">GESHI_CLASS</span><span class="src-sym">]</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4356"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str">&nbsp;{{<span class="src-var">$styles</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4357"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}&nbsp;</span><span class="src-key">else&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4358"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span><span class="src-str"><span class="src-var">$selector</span>.re<span class="src-var">$group</span>&nbsp;{{<span class="src-var">$styles</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4359"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4360"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4361"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4362"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;Styles&nbsp;for&nbsp;lines&nbsp;being&nbsp;highlighted&nbsp;extra</span></div></li> <li><div class="src-line"><a name="a4363"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$economy_mode&nbsp;</span>||&nbsp;<span class="src-sym">(</span><a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines</span><span class="src-sym">)</span>!=<a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines_styles</span><span class="src-sym">)))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4364"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span>{<span class="src-var">$selector</span><span class="src-str"></span><span class="src-sym">}</span>.ln-xtra,&nbsp;{<span class="src-var">$selector</span><span class="src-sym">}</span>li.ln-xtra,&nbsp;{<span class="src-var">$selector</span><span class="src-sym">}</span>div.ln-xtra&nbsp;{{<span class="src-var">$this</span></span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines_style</span><span class="src-str"></span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4365"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4366"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span>{<span class="src-var">$selector</span><span class="src-str"></span><span class="src-sym">}</span>span.xtra&nbsp;{&nbsp;display:block;&nbsp;}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4367"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach&nbsp;</span><span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines_styles&nbsp;</span><span class="src-key">as&nbsp;</span><span class="src-var">$lineid&nbsp;</span>=&gt;&nbsp;<span class="src-var">$linestyle</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4368"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$stylesheet&nbsp;</span>.=&nbsp;<span class="src-str">&quot;</span>{<span class="src-var">$selector</span><span class="src-str"></span><span class="src-sym">}</span>.lx<span class="src-var">$lineid</span>,&nbsp;{<span class="src-var">$selector</span><span class="src-sym">}</span>li.lx<span class="src-var">$lineid</span>,&nbsp;{<span class="src-var">$selector</span><span class="src-sym">}</span>div.lx<span class="src-var">$lineid</span>&nbsp;{{<span class="src-var">$linestyle</span><span class="src-sym">}</span>}\n</span><span class="src-str">&quot;</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4369"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4370"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4371"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><span class="src-var">$stylesheet</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4372"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4373"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4374"></a>&nbsp;&nbsp;&nbsp;&nbsp;/**</div></li> <li><div class="src-line"><a name="a4375"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Get's&nbsp;the&nbsp;style&nbsp;that&nbsp;is&nbsp;used&nbsp;for&nbsp;the&nbsp;specified&nbsp;line</div></li> <li><div class="src-line"><a name="a4376"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</div></li> <li><div class="src-line"><a name="a4377"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;int&nbsp;The&nbsp;line&nbsp;number&nbsp;information&nbsp;is&nbsp;requested&nbsp;for</div></li> <li><div class="src-line"><a name="a4378"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@access&nbsp;private</div></li> <li><div class="src-line"><a name="a4379"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;1.0.7.21</div></li> <li><div class="src-line"><a name="a4380"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</div></li> <li><div class="src-line"><a name="a4381"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function&nbsp;</span><span class="src-id">get_line_style</span><span class="src-sym">(</span><span class="src-var">$line</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4382"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//$style&nbsp;=&nbsp;null;</span></div></li> <li><div class="src-line"><a name="a4383"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$style&nbsp;</span>=&nbsp;<span class="src-id">null</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4384"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines_styles</span><span class="src-sym">[</span><span class="src-var">$line</span><span class="src-sym">]</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4385"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$style&nbsp;</span>=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines_styles</span><span class="src-sym">[</span><span class="src-var">$line</span><span class="src-sym">]</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4386"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}&nbsp;</span><span class="src-key">else&nbsp;</span><span class="src-sym">{&nbsp;</span><span class="src-comm">//&nbsp;if&nbsp;no&nbsp;&quot;extra&quot;&nbsp;style&nbsp;assigned</span></div></li> <li><div class="src-line"><a name="a4387"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$style&nbsp;</span>=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">highlight_extra_lines_style</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4388"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4389"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4390"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><span class="src-var">$style</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4391"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4392"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4393"></a>&nbsp;&nbsp;&nbsp;&nbsp;/**</div></li> <li><div class="src-line"><a name="a4394"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;this&nbsp;functions&nbsp;creates&nbsp;an&nbsp;optimized&nbsp;regular&nbsp;expression&nbsp;list</div></li> <li><div class="src-line"><a name="a4395"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;of&nbsp;an&nbsp;array&nbsp;of&nbsp;strings.</div></li> <li><div class="src-line"><a name="a4396"></a>&nbsp;&nbsp;&nbsp;&nbsp;*</div></li> <li><div class="src-line"><a name="a4397"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Example:</div></li> <li><div class="src-line"><a name="a4398"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&lt;code&gt;$list&nbsp;=&nbsp;array('faa',&nbsp;'foo',&nbsp;'foobar');</div></li> <li><div class="src-line"><a name="a4399"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=&gt;&nbsp;string&nbsp;'f(aa|oo(bar)?)'&lt;/code&gt;</div></li> <li><div class="src-line"><a name="a4400"></a>&nbsp;&nbsp;&nbsp;&nbsp;*</div></li> <li><div class="src-line"><a name="a4401"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;$list&nbsp;array&nbsp;of&nbsp;(unquoted)&nbsp;strings</div></li> <li><div class="src-line"><a name="a4402"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;$regexp_delimiter&nbsp;your&nbsp;regular&nbsp;expression&nbsp;delimiter,&nbsp;@see&nbsp;preg_quote()</div></li> <li><div class="src-line"><a name="a4403"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@return&nbsp;string&nbsp;for&nbsp;regular&nbsp;expression</div></li> <li><div class="src-line"><a name="a4404"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@author&nbsp;Milian&nbsp;Wolff&nbsp;&lt;mail@milianw.de&gt;</div></li> <li><div class="src-line"><a name="a4405"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;1.0.8</div></li> <li><div class="src-line"><a name="a4406"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@access&nbsp;private</div></li> <li><div class="src-line"><a name="a4407"></a>&nbsp;&nbsp;&nbsp;&nbsp;*/</div></li> <li><div class="src-line"><a name="a4408"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function&nbsp;</span><span class="src-id">optimize_regexp_list</span><span class="src-sym">(</span><span class="src-var">$list</span><span class="src-sym">,&nbsp;</span><span class="src-var">$regexp_delimiter&nbsp;</span>=&nbsp;<span class="src-str">'/'</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4409"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$regex_chars&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">'.'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'\\'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'+'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'*'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'?'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'['</span><span class="src-sym">,&nbsp;</span><span class="src-str">'^'</span><span class="src-sym">,&nbsp;</span><span class="src-str">']'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'$'</span><span class="src-sym">,</span></div></li> <li><div class="src-line"><a name="a4410"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-str">'('</span><span class="src-sym">,&nbsp;</span><span class="src-str">')'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'{'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'}'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'='</span><span class="src-sym">,&nbsp;</span><span class="src-str">'!'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'&lt;'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'&gt;'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'|'</span><span class="src-sym">,&nbsp;</span><span class="src-str">':'</span><span class="src-sym">,&nbsp;</span><span class="src-var">$regexp_delimiter</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4411"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/sort">sort</a><span class="src-sym">(</span><span class="src-var">$list</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4412"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$regexp_list&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">''</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4413"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$num_subpatterns&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4414"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$list_key&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4415"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4416"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;the&nbsp;tokens&nbsp;which&nbsp;we&nbsp;will&nbsp;use&nbsp;to&nbsp;generate&nbsp;the&nbsp;regexp&nbsp;list</span></div></li> <li><div class="src-line"><a name="a4417"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$tokens&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4418"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$prev_keys&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4419"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;go&nbsp;through&nbsp;all&nbsp;entries&nbsp;of&nbsp;the&nbsp;list&nbsp;and&nbsp;generate&nbsp;the&nbsp;token&nbsp;list</span></div></li> <li><div class="src-line"><a name="a4420"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$cur_len&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4421"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">for&nbsp;</span><span class="src-sym">(</span><span class="src-var">$i&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">,&nbsp;</span><span class="src-var">$i_max&nbsp;</span>=&nbsp;<a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$list</span><span class="src-sym">)</span><span class="src-sym">;&nbsp;</span><span class="src-var">$i&nbsp;</span>&lt;&nbsp;<span class="src-var">$i_max</span><span class="src-sym">;&nbsp;</span>++<span class="src-var">$i</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4422"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$cur_len&nbsp;</span>&gt;&nbsp;<span class="src-id">GESHI_MAX_PCRE_LENGTH</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4423"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;seems&nbsp;like&nbsp;the&nbsp;length&nbsp;of&nbsp;this&nbsp;pcre&nbsp;is&nbsp;growing&nbsp;exorbitantly</span></div></li> <li><div class="src-line"><a name="a4424"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$regexp_list</span><span class="src-sym">[</span>++<span class="src-var">$list_key</span><span class="src-sym">]&nbsp;</span>=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_optimize_regexp_list_tokens_to_string</span><span class="src-sym">(</span><span class="src-var">$tokens</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4425"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$num_subpatterns&nbsp;</span>=&nbsp;<a href="http://www.php.net/substr_count">substr_count</a><span class="src-sym">(</span><span class="src-var">$regexp_list</span><span class="src-sym">[</span><span class="src-var">$list_key</span><span class="src-sym">]</span><span class="src-sym">,&nbsp;</span><span class="src-str">'(?:'</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4426"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$tokens&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4427"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$cur_len&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4428"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4429"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$level&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4430"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$entry&nbsp;</span>=&nbsp;<a href="http://www.php.net/preg_quote">preg_quote</a><span class="src-sym">(</span>(string)&nbsp;<span class="src-var">$list</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">,&nbsp;</span><span class="src-var">$regexp_delimiter</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4431"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$pointer&nbsp;</span>=&nbsp;<span class="src-sym">&amp;</span><span class="src-var">$tokens</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4432"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;properly&nbsp;assign&nbsp;the&nbsp;new&nbsp;entry&nbsp;to&nbsp;the&nbsp;correct&nbsp;position&nbsp;in&nbsp;the&nbsp;token&nbsp;array</span></div></li> <li><div class="src-line"><a name="a4433"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;possibly&nbsp;generate&nbsp;smaller&nbsp;common&nbsp;denominator&nbsp;keys</span></div></li> <li><div class="src-line"><a name="a4434"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">while&nbsp;</span><span class="src-sym">(</span><span class="src-id">true</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4435"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;get&nbsp;the&nbsp;common&nbsp;denominator</span></div></li> <li><div class="src-line"><a name="a4436"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$prev_keys</span><span class="src-sym">[</span><span class="src-var">$level</span><span class="src-sym">]</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4437"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$prev_keys</span><span class="src-sym">[</span><span class="src-var">$level</span><span class="src-sym">]&nbsp;</span>==&nbsp;<span class="src-var">$entry</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4438"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;this&nbsp;is&nbsp;a&nbsp;duplicate&nbsp;entry,&nbsp;skip&nbsp;it</span></div></li> <li><div class="src-line"><a name="a4439"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue&nbsp;</span><span class="src-num">2</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4440"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4441"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$char&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4442"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">while&nbsp;</span><span class="src-sym">(</span>isset<span class="src-sym">(</span><span class="src-var">$entry</span><span class="src-sym">[</span><span class="src-var">$char</span><span class="src-sym">]</span><span class="src-sym">)&nbsp;</span>&amp;&amp;&nbsp;isset<span class="src-sym">(</span><span class="src-var">$prev_keys</span><span class="src-sym">[</span><span class="src-var">$level</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$char</span><span class="src-sym">]</span><span class="src-sym">)</span></div></li> <li><div class="src-line"><a name="a4443"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&amp;&amp;&nbsp;<span class="src-var">$entry</span><span class="src-sym">[</span><span class="src-var">$char</span><span class="src-sym">]&nbsp;</span>==&nbsp;<span class="src-var">$prev_keys</span><span class="src-sym">[</span><span class="src-var">$level</span><span class="src-sym">]</span><span class="src-sym">[</span><span class="src-var">$char</span><span class="src-sym">]</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4444"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$char</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4445"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4446"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$char&nbsp;</span>&gt;&nbsp;<span class="src-num">0</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4447"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;this&nbsp;entry&nbsp;has&nbsp;at&nbsp;least&nbsp;some&nbsp;chars&nbsp;in&nbsp;common&nbsp;with&nbsp;the&nbsp;current&nbsp;key</span></div></li> <li><div class="src-line"><a name="a4448"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$char&nbsp;</span>==&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$prev_keys</span><span class="src-sym">[</span><span class="src-var">$level</span><span class="src-sym">]</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4449"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;current&nbsp;key&nbsp;is&nbsp;totally&nbsp;matched,&nbsp;i.e.&nbsp;this&nbsp;entry&nbsp;has&nbsp;just&nbsp;some&nbsp;bits&nbsp;appended</span></div></li> <li><div class="src-line"><a name="a4450"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$pointer&nbsp;</span>=&nbsp;<span class="src-sym">&amp;</span><span class="src-var">$pointer</span><span class="src-sym">[</span><span class="src-var">$prev_keys</span><span class="src-sym">[</span><span class="src-var">$level</span><span class="src-sym">]]</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4451"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}&nbsp;</span><span class="src-key">else&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4452"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;only&nbsp;part&nbsp;of&nbsp;the&nbsp;keys&nbsp;match</span></div></li> <li><div class="src-line"><a name="a4453"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$new_key_part1&nbsp;</span>=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$prev_keys</span><span class="src-sym">[</span><span class="src-var">$level</span><span class="src-sym">]</span><span class="src-sym">,&nbsp;</span><span class="src-num">0</span><span class="src-sym">,&nbsp;</span><span class="src-var">$char</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4454"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$new_key_part2&nbsp;</span>=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$prev_keys</span><span class="src-sym">[</span><span class="src-var">$level</span><span class="src-sym">]</span><span class="src-sym">,&nbsp;</span><span class="src-var">$char</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4455"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4456"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><a href="http://www.php.net/in_array">in_array</a><span class="src-sym">(</span><span class="src-var">$new_key_part1</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">,&nbsp;</span><span class="src-var">$regex_chars</span><span class="src-sym">)</span></div></li> <li><div class="src-line"><a name="a4457"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;||&nbsp;<a href="http://www.php.net/in_array">in_array</a><span class="src-sym">(</span><span class="src-var">$new_key_part2</span><span class="src-sym">[</span><span class="src-num">0</span><span class="src-sym">]</span><span class="src-sym">,&nbsp;</span><span class="src-var">$regex_chars</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4458"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;this&nbsp;is&nbsp;bad,&nbsp;a&nbsp;regex&nbsp;char&nbsp;as&nbsp;first&nbsp;character</span></div></li> <li><div class="src-line"><a name="a4459"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$pointer</span><span class="src-sym">[</span><span class="src-var">$entry</span><span class="src-sym">]&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">''&nbsp;</span>=&gt;&nbsp;<span class="src-id">true</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4460"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/array_splice">array_splice</a><span class="src-sym">(</span><span class="src-var">$prev_keys</span><span class="src-sym">,&nbsp;</span><span class="src-var">$level</span><span class="src-sym">,&nbsp;</span><a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$prev_keys</span><span class="src-sym">)</span><span class="src-sym">,&nbsp;</span><span class="src-var">$entry</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4461"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$cur_len&nbsp;</span>+=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$entry</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4462"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4463"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}&nbsp;</span><span class="src-key">else&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4464"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;relocate&nbsp;previous&nbsp;tokens</span></div></li> <li><div class="src-line"><a name="a4465"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$pointer</span><span class="src-sym">[</span><span class="src-var">$new_key_part1</span><span class="src-sym">]&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-var">$new_key_part2&nbsp;</span>=&gt;&nbsp;<span class="src-var">$pointer</span><span class="src-sym">[</span><span class="src-var">$prev_keys</span><span class="src-sym">[</span><span class="src-var">$level</span><span class="src-sym">]]</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4466"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$pointer</span><span class="src-sym">[</span><span class="src-var">$prev_keys</span><span class="src-sym">[</span><span class="src-var">$level</span><span class="src-sym">]]</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4467"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$pointer&nbsp;</span>=&nbsp;<span class="src-sym">&amp;</span><span class="src-var">$pointer</span><span class="src-sym">[</span><span class="src-var">$new_key_part1</span><span class="src-sym">]</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4468"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;recreate&nbsp;key&nbsp;index</span></div></li> <li><div class="src-line"><a name="a4469"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/array_splice">array_splice</a><span class="src-sym">(</span><span class="src-var">$prev_keys</span><span class="src-sym">,&nbsp;</span><span class="src-var">$level</span><span class="src-sym">,&nbsp;</span><a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$prev_keys</span><span class="src-sym">)</span><span class="src-sym">,&nbsp;</span><span class="src-key">array</span><span class="src-sym">(</span><span class="src-var">$new_key_part1</span><span class="src-sym">,&nbsp;</span><span class="src-var">$new_key_part2</span><span class="src-sym">))</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4470"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$cur_len&nbsp;</span>+=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$new_key_part2</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4471"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4472"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4473"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++<span class="src-var">$level</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4474"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$entry&nbsp;</span>=&nbsp;<a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$entry</span><span class="src-sym">,&nbsp;</span><span class="src-var">$char</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4475"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">continue</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4476"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4477"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;else:&nbsp;fall&nbsp;trough,&nbsp;i.e.&nbsp;no&nbsp;common&nbsp;denominator&nbsp;was&nbsp;found</span></div></li> <li><div class="src-line"><a name="a4478"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4479"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$level&nbsp;</span>==&nbsp;<span class="src-num">0&nbsp;</span>&amp;&amp;&nbsp;<span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$tokens</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4480"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;we&nbsp;can&nbsp;dump&nbsp;current&nbsp;tokens&nbsp;into&nbsp;the&nbsp;string&nbsp;and&nbsp;throw&nbsp;them&nbsp;away&nbsp;afterwards</span></div></li> <li><div class="src-line"><a name="a4481"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$new_entry&nbsp;</span>=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_optimize_regexp_list_tokens_to_string</span><span class="src-sym">(</span><span class="src-var">$tokens</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4482"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$new_subpatterns&nbsp;</span>=&nbsp;<a href="http://www.php.net/substr_count">substr_count</a><span class="src-sym">(</span><span class="src-var">$new_entry</span><span class="src-sym">,&nbsp;</span><span class="src-str">'(?:'</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4483"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-id">GESHI_MAX_PCRE_SUBPATTERNS&nbsp;</span>&amp;&amp;&nbsp;<span class="src-var">$num_subpatterns&nbsp;</span>+&nbsp;<span class="src-var">$new_subpatterns&nbsp;</span>&gt;&nbsp;<span class="src-id">GESHI_MAX_PCRE_SUBPATTERNS</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4484"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$regexp_list</span><span class="src-sym">[</span>++<span class="src-var">$list_key</span><span class="src-sym">]&nbsp;</span>=&nbsp;<span class="src-var">$new_entry</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4485"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$num_subpatterns&nbsp;</span>=&nbsp;<span class="src-var">$new_subpatterns</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4486"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}&nbsp;</span><span class="src-key">else&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4487"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$regexp_list</span><span class="src-sym">[</span><span class="src-var">$list_key</span><span class="src-sym">]</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4488"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$new_entry&nbsp;</span>=&nbsp;<span class="src-str">'|'&nbsp;</span>.&nbsp;<span class="src-var">$new_entry</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4489"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4490"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$regexp_list</span><span class="src-sym">[</span><span class="src-var">$list_key</span><span class="src-sym">]&nbsp;</span>.=&nbsp;<span class="src-var">$new_entry</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4491"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$num_subpatterns&nbsp;</span>+=&nbsp;<span class="src-var">$new_subpatterns</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4492"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4493"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$tokens&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4494"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$cur_len&nbsp;</span>=&nbsp;<span class="src-num">0</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4495"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4496"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;no&nbsp;further&nbsp;common&nbsp;denominator&nbsp;found</span></div></li> <li><div class="src-line"><a name="a4497"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$pointer</span><span class="src-sym">[</span><span class="src-var">$entry</span><span class="src-sym">]&nbsp;</span>=&nbsp;<span class="src-key">array</span><span class="src-sym">(</span><span class="src-str">''&nbsp;</span>=&gt;&nbsp;<span class="src-id">true</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4498"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.php.net/array_splice">array_splice</a><span class="src-sym">(</span><span class="src-var">$prev_keys</span><span class="src-sym">,&nbsp;</span><span class="src-var">$level</span><span class="src-sym">,&nbsp;</span><a href="http://www.php.net/count">count</a><span class="src-sym">(</span><span class="src-var">$prev_keys</span><span class="src-sym">)</span><span class="src-sym">,&nbsp;</span><span class="src-var">$entry</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4499"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4500"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$cur_len&nbsp;</span>+=&nbsp;<a href="http://www.php.net/strlen">strlen</a><span class="src-sym">(</span><span class="src-var">$entry</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4501"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">break</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4502"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4503"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$list</span><span class="src-sym">[</span><span class="src-var">$i</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4504"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4505"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;make&nbsp;sure&nbsp;the&nbsp;last&nbsp;tokens&nbsp;get&nbsp;converted&nbsp;as&nbsp;well</span></div></li> <li><div class="src-line"><a name="a4506"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$new_entry&nbsp;</span>=&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_optimize_regexp_list_tokens_to_string</span><span class="src-sym">(</span><span class="src-var">$tokens</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4507"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-id">GESHI_MAX_PCRE_SUBPATTERNS&nbsp;</span>&amp;&amp;&nbsp;<span class="src-var">$num_subpatterns&nbsp;</span>+&nbsp;<a href="http://www.php.net/substr_count">substr_count</a><span class="src-sym">(</span><span class="src-var">$new_entry</span><span class="src-sym">,&nbsp;</span><span class="src-str">'(?:'</span><span class="src-sym">)&nbsp;</span>&gt;&nbsp;<span class="src-id">GESHI_MAX_PCRE_SUBPATTERNS</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4508"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$regexp_list</span><span class="src-sym">[</span>++<span class="src-var">$list_key</span><span class="src-sym">]&nbsp;</span>=&nbsp;<span class="src-var">$new_entry</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4509"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}&nbsp;</span><span class="src-key">else&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4510"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$regexp_list</span><span class="src-sym">[</span><span class="src-var">$list_key</span><span class="src-sym">]</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4511"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$new_entry&nbsp;</span>=&nbsp;<span class="src-str">'|'&nbsp;</span>.&nbsp;<span class="src-var">$new_entry</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4512"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4513"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$regexp_list</span><span class="src-sym">[</span><span class="src-var">$list_key</span><span class="src-sym">]&nbsp;</span>.=&nbsp;<span class="src-var">$new_entry</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4514"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4515"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><span class="src-var">$regexp_list</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4516"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4517"></a>&nbsp;&nbsp;&nbsp;&nbsp;/**</div></li> <li><div class="src-line"><a name="a4518"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;this&nbsp;function&nbsp;creates&nbsp;the&nbsp;appropriate&nbsp;regexp&nbsp;string&nbsp;of&nbsp;an&nbsp;token&nbsp;array</div></li> <li><div class="src-line"><a name="a4519"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;you&nbsp;should&nbsp;not&nbsp;call&nbsp;this&nbsp;function&nbsp;directly,&nbsp;@see&nbsp;$this-&gt;optimize_regexp_list().</div></li> <li><div class="src-line"><a name="a4520"></a>&nbsp;&nbsp;&nbsp;&nbsp;*</div></li> <li><div class="src-line"><a name="a4521"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;&amp;$tokens&nbsp;array&nbsp;of&nbsp;tokens</div></li> <li><div class="src-line"><a name="a4522"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;$recursed&nbsp;bool&nbsp;to&nbsp;know&nbsp;wether&nbsp;we&nbsp;recursed&nbsp;or&nbsp;not</div></li> <li><div class="src-line"><a name="a4523"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@return&nbsp;string</div></li> <li><div class="src-line"><a name="a4524"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@author&nbsp;Milian&nbsp;Wolff&nbsp;&lt;mail@milianw.de&gt;</div></li> <li><div class="src-line"><a name="a4525"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;1.0.8</div></li> <li><div class="src-line"><a name="a4526"></a>&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@access&nbsp;private</div></li> <li><div class="src-line"><a name="a4527"></a>&nbsp;&nbsp;&nbsp;&nbsp;*/</div></li> <li><div class="src-line"><a name="a4528"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function&nbsp;</span><span class="src-id">_optimize_regexp_list_tokens_to_string</span><span class="src-sym">(</span><span class="src-sym">&amp;</span><span class="src-var">$tokens</span><span class="src-sym">,&nbsp;</span><span class="src-var">$recursed&nbsp;</span>=&nbsp;<span class="src-id">false</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4529"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$list&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4530"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">foreach&nbsp;</span><span class="src-sym">(</span><span class="src-var">$tokens&nbsp;</span><span class="src-key">as&nbsp;</span><span class="src-var">$token&nbsp;</span>=&gt;&nbsp;<span class="src-var">$sub_tokens</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4531"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$list&nbsp;</span>.=&nbsp;<span class="src-var">$token</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4532"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$close_entry&nbsp;</span>=&nbsp;isset<span class="src-sym">(</span><span class="src-var">$sub_tokens</span><span class="src-sym">[</span><span class="src-str">''</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4533"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unset<span class="src-sym">(</span><span class="src-var">$sub_tokens</span><span class="src-sym">[</span><span class="src-str">''</span><span class="src-sym">]</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4534"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-var">$sub_tokens</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4535"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$list&nbsp;</span>.=&nbsp;<span class="src-str">'(?:'&nbsp;</span>.&nbsp;<span class="src-var">$this</span><span class="src-sym">-&gt;</span><span class="src-id">_optimize_regexp_list_tokens_to_string</span><span class="src-sym">(</span><span class="src-var">$sub_tokens</span><span class="src-sym">,&nbsp;</span><span class="src-id">true</span><span class="src-sym">)&nbsp;</span>.&nbsp;<span class="src-str">')'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4536"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$close_entry</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4537"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;make&nbsp;sub_tokens&nbsp;optional</span></div></li> <li><div class="src-line"><a name="a4538"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$list&nbsp;</span>.=&nbsp;<span class="src-str">'?'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4539"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4540"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4541"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$list&nbsp;</span>.=&nbsp;<span class="src-str">'|'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4542"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4543"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span><span class="src-var">$recursed</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4544"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;do&nbsp;some&nbsp;optimizations</span></div></li> <li><div class="src-line"><a name="a4545"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;common&nbsp;trailing&nbsp;strings</span></div></li> <li><div class="src-line"><a name="a4546"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;BUGGY!</span></div></li> <li><div class="src-line"><a name="a4547"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//$list&nbsp;=&nbsp;preg_replace_callback('#(?&lt;=^|\:|\|)\w+?(\w+)(?:\|.+\1)+(?=\|)#',&nbsp;create_function(</span></div></li> <li><div class="src-line"><a name="a4548"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;&nbsp;&nbsp;&nbsp;'$matches',&nbsp;'return&nbsp;&quot;(?:&quot;&nbsp;.&nbsp;preg_replace(&quot;#&quot;&nbsp;.&nbsp;preg_quote($matches[1],&nbsp;&quot;#&quot;)&nbsp;.&nbsp;&quot;(?=\||$)#&quot;,&nbsp;&quot;&quot;,&nbsp;$matches[0])&nbsp;.&nbsp;&quot;)&quot;&nbsp;.&nbsp;$matches[1];'),&nbsp;$list);</span></div></li> <li><div class="src-line"><a name="a4549"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;(?:p)?&nbsp;=&gt;&nbsp;p?</span></div></li> <li><div class="src-line"><a name="a4550"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$list&nbsp;</span>=&nbsp;<a href="http://www.php.net/preg_replace">preg_replace</a><span class="src-sym">(</span><span class="src-str">'#\(\?\:(.)\)\?#'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'\1?'</span><span class="src-sym">,&nbsp;</span><span class="src-var">$list</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4551"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;(?:a|b|c|d|...)?&nbsp;=&gt;&nbsp;[abcd...]?</span></div></li> <li><div class="src-line"><a name="a4552"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;TODO:&nbsp;a|bb|c&nbsp;=&gt;&nbsp;[ac]|bb</span></div></li> <li><div class="src-line"><a name="a4553"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">static&nbsp;</span><span class="src-var">$callback_2</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4554"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span>isset<span class="src-sym">(</span><span class="src-var">$callback_2</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4555"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$callback_2&nbsp;</span>=&nbsp;<a href="http://www.php.net/create_function">create_function</a><span class="src-sym">(</span><span class="src-str">'$matches'</span><span class="src-sym">,&nbsp;</span><span class="src-str">'return&nbsp;&quot;[&quot;&nbsp;.&nbsp;str_replace(&quot;|&quot;,&nbsp;&quot;&quot;,&nbsp;$matches[1])&nbsp;.&nbsp;&quot;]&quot;;'</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4556"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4557"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$list&nbsp;</span>=&nbsp;<a href="http://www.php.net/preg_replace_callback">preg_replace_callback</a><span class="src-sym">(</span><span class="src-str">'#\(\?\:((?:.\|)+.)\)#'</span><span class="src-sym">,&nbsp;</span><span class="src-var">$callback_2</span><span class="src-sym">,&nbsp;</span><span class="src-var">$list</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4558"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4559"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;return&nbsp;$list&nbsp;without&nbsp;trailing&nbsp;pipe</span></div></li> <li><div class="src-line"><a name="a4560"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><a href="http://www.php.net/substr">substr</a><span class="src-sym">(</span><span class="src-var">$list</span><span class="src-sym">,&nbsp;</span><span class="src-num">0</span><span class="src-sym">,&nbsp;</span>-<span class="src-num">1</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4561"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4562"></a><span class="src-sym">}&nbsp;</span><span class="src-comm">//&nbsp;End&nbsp;Class&nbsp;GeSHi</span></div></li> <li><div class="src-line"><a name="a4563"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4564"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4565"></a><span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-sym">!</span><a href="http://www.php.net/function_exists">function_exists</a><span class="src-sym">(</span><span class="src-str">'geshi_highlight'</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4566"></a>&nbsp;&nbsp;&nbsp;&nbsp;/**</div></li> <li><div class="src-line"><a name="a4567"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;Easy&nbsp;way&nbsp;to&nbsp;highlight&nbsp;stuff.&nbsp;Behaves&nbsp;just&nbsp;like&nbsp;highlight_string</div></li> <li><div class="src-line"><a name="a4568"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*</div></li> <li><div class="src-line"><a name="a4569"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;string&nbsp;The&nbsp;code&nbsp;to&nbsp;highlight</div></li> <li><div class="src-line"><a name="a4570"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;string&nbsp;The&nbsp;language&nbsp;to&nbsp;highlight&nbsp;the&nbsp;code&nbsp;in</div></li> <li><div class="src-line"><a name="a4571"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;string&nbsp;The&nbsp;path&nbsp;to&nbsp;the&nbsp;language&nbsp;files.&nbsp;You&nbsp;can&nbsp;leave&nbsp;this&nbsp;blank&nbsp;if&nbsp;you&nbsp;need</div></li> <li><div class="src-line"><a name="a4572"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;as&nbsp;from&nbsp;version&nbsp;1.0.7&nbsp;the&nbsp;path&nbsp;should&nbsp;be&nbsp;automatically&nbsp;detected</div></li> <li><div class="src-line"><a name="a4573"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@param&nbsp;boolean&nbsp;Whether&nbsp;to&nbsp;return&nbsp;the&nbsp;result&nbsp;or&nbsp;to&nbsp;echo</div></li> <li><div class="src-line"><a name="a4574"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@return&nbsp;string&nbsp;The&nbsp;code&nbsp;highlighted&nbsp;(if&nbsp;$return&nbsp;is&nbsp;true)</div></li> <li><div class="src-line"><a name="a4575"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*&nbsp;@since&nbsp;1.0.2</div></li> <li><div class="src-line"><a name="a4576"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</div></li> <li><div class="src-line"><a name="a4577"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">function&nbsp;</span><a href="../geshi/core/_geshi.php.html#functiongeshi_highlight">geshi_highlight</a><span class="src-sym">(</span><span class="src-var">$string</span><span class="src-sym">,&nbsp;</span><span class="src-var">$language</span><span class="src-sym">,&nbsp;</span><span class="src-var">$path&nbsp;</span>=&nbsp;<span class="src-id">null</span><span class="src-sym">,&nbsp;</span><span class="src-var">$return&nbsp;</span>=&nbsp;<span class="src-id">false</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4578"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$geshi&nbsp;</span>=&nbsp;<span class="src-key">new&nbsp;</span><a href="../geshi/core/GeSHi.html#methodGeSHi">GeSHi</a><span class="src-sym">(</span><span class="src-var">$string</span><span class="src-sym">,&nbsp;</span><span class="src-var">$language</span><span class="src-sym">,&nbsp;</span><span class="src-var">$path</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4579"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$geshi</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodset_header_type">set_header_type</a><span class="src-sym">(</span><span class="src-id"><a href="../geshi/core/_geshi.php.html#defineGESHI_HEADER_NONE">GESHI_HEADER_NONE</a></span><span class="src-sym">)</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4580"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4581"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$return</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4582"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><span class="src-str">'&lt;code&gt;'&nbsp;</span>.&nbsp;<span class="src-var">$geshi</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodparse_code">parse_code</a><span class="src-sym">(</span><span class="src-sym">)&nbsp;</span>.&nbsp;<span class="src-str">'&lt;/code&gt;'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4583"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4584"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4585"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo&nbsp;<span class="src-str">'&lt;code&gt;'&nbsp;</span>.&nbsp;<span class="src-var">$geshi</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methodparse_code">parse_code</a><span class="src-sym">(</span><span class="src-sym">)&nbsp;</span>.&nbsp;<span class="src-str">'&lt;/code&gt;'</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4586"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4587"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(</span><span class="src-var">$geshi</span><span class="src-sym">-&gt;</span><a href="../geshi/core/GeSHi.html#methoderror">error</a><span class="src-sym">(</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li> <li><div class="src-line"><a name="a4588"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><span class="src-id">false</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4589"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4590"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><span class="src-id">true</span><span class="src-sym">;</span></div></li> <li><div class="src-line"><a name="a4591"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4592"></a><span class="src-sym">}</span></div></li> <li><div class="src-line"><a name="a4593"></a>&nbsp;</div></li> <li><div class="src-line"><a name="a4594"></a><span class="src-php">?&gt;</span></div></li> </ol></div> </div> <p class="notes" id="credit"> Documentation generated on Thu, 25 Dec 2008 14:34:52 +0100 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.4.2</a> </p> </body> </html>

Resultaat

Made by Thijs Aarnoudse