<?xml version=\"1.0\" encoding=\"utf-8\" ?>
<!DOCTYPE modification SYSTEM \"
http://www.simplemachines.org/xml/modification\">\'>
http://www.simplemachines.org/xml/modification\">
<modification xmlns=\"
http://www.simplemachines.org/xml/modification\" xmlns:smf=\"
http://www.simplemachines.org/\">
<id>PawnoBBKod</id>
<version>1.8</version>
<file name=\"$sourcedir/Subs.php\">
<operation>
<search position=\"after\"><![CDATA[array(
\'tag\' => \'color\',
\'type\' => \'unparsed_equals\',
\'test\' => \'(#[\\da-fA-F]{3}|#[\\da-fA-F]{6}|[A-Za-z]{1,20}|rgb\\(\\d{1,3}, ?\\d{1,3}, ?\\d{1,3}\\))\\]\',
\'before\' => \'<span style=\"color: $1;\" class=\"bbc_color\">\',
\'after\' => \'</span>\',
),]]></search>
<add><![CDATA[
array(
\'tag\' => \'pawno\',
\'type\' => \'unparsed_content\',
\'content\' => \'<div class=codeheader\">\' . $txt[\'pawnocode] . \': <a href=\"javascript:void(0);\" onclick=\"return smfSelectText(this);\" class=\"codeoperation\">\' . $txt[\'code_select\'] . \'</a></div>\' . ($context[\'browser\'][\'is_gecko\'] || $context[\'browser\'][\'is_opera\'] ? \'<pre style=\"margin: 0; padding: 0;\">\' : \'\') . \'<code class=\"bbc_code\">$1</code>\' . ($context[\'browser\'][\'is_gecko\'] || $context[\'browser\'][\'is_opera\'] ? \'</pre>\' : \'\'),
\'validate\' => create_function(\'&$tag, &$data, $disabled\', \'
global $context;
if (!isset($disabled[\\\'pawn\\\']))
{
$data = str_replace(
array(
\\\'public\\\',
\\\'return\\\',
\\\'sizeof\\\',
\\\'switch\\\',
\\\'true\\\',
\\\'false\\\',
\\\'if\\\',
\\\'new\\\',
\\\'else\\\',
\\\'for\\\',
\\\'while\\\',
\\\'case\\\',
\\\'default\\\',
\\\'goto\\\',
\\\'do\\\',
\\\'continue\\\',
\\\'break\\\',
\\\'(\\\',
\\\')\\\',
\\\'[\\\',
\\\']\\\',
\\\'{\\\',
\\\'}\\\',
),
array(
\\\'<span style=\"color: blue;\">public</span>\\\',
\\\'<span style=\"color: blue;\">return</span>\\\',
\\\'<span style=\"color: blue;\">sizeof</span>\\\',
\\\'<span style=\"color: blue;\">switch</span>\\\',
\\\'<span style=\"color: blue;\">true</span>\\\',
\\\'<span style=\"color: blue;\">false</span>\\\',
\\\'<span style=\"color: blue;\">if</span>\\\',
\\\'<span style=\"color: blue;\">new</span>\\\',
\\\'<span style=\"color: blue;\">else</span>\\\',
\\\'<span style=\"color: blue;\">for</span>\\\',
\\\'<span style=\"color: blue;\">while</span>\\\',
\\\'<span style=\"color: blue;\">case</span>\\\',
\\\'<span style=\"color: blue;\">default</span>\\\',
\\\'<span style=\"color: blue;\">goto</span>\\\',
\\\'<span style=\"color: blue;\">do</span>\\\',
\\\'<span style=\"color: blue;\">continue</span>\\\',
\\\'<span style=\"color: blue;\">break</span>\\\',
\\\'<span style=\"color: red;\">(</span>\\\',
\\\'<span style=\"color: red;\">)</span>\\\',
\\\'<span style=\"color: red;\">[</span>\\\',
\\\'<span style=\"color: red;\">]</span>\\\',
\\\'<span style=\"color: red;\">{</span>\\\',
\\\'<span style=\"color: red;\">}</span>\\\',
), $data);
$data = preg_replace(
array(
\\\'~#(.+?)\\<br \\/>~is\\\',
\\\'~\\/\\/(.+?)\\<br \\/\\>~i\\\',
\\\'~\\/\\*(.+?)\\*\\/~i\\\'
),
array(
\\\'<span style=\"color: blue;\">#$1<br /></span>\\\',
\\\'<span style=\"color: green;\">//$1<br /></span>\\\',
\\\'<span style=\"color: green;\">/*$1*/</span>\\\'
), $data);
// Older browsers are annoying, aren\\\'t they?
if ($context[\\\'browser\\\'][\\\'is_ie4\\\'] || $context[\\\'browser\\\'][\\\'is_ie5\\\'] || $context[\\\'browser\\\'][\\\'is_ie5.5\\\'])
$data = str_replace(\"\\t\", \"<pre style=\\\"display: inline;\\\">\\t</pre>\", $data);
elseif (!$context[\\\'browser\\\'][\\\'is_gecko\\\'])
$data = str_replace(\"\\t\", \"<span style=\\\"white-space: pre;\\\">\\t</span>\", $data);
}\'),
\'block_level\' => true,
),
]]></add>
</operation>
</file>
<file name=\"$sourcedir/Subs-Editor.php\">
<operation>
<search position=\"before\"><![CDATA[array(
\'image\' => \'quote\',
\'code\' => \'quote\',
\'before\' => \'
\',
\'after\' => \'
[/quote]\',
\'description\' => $txt[\'bbc_quote]
),]]></search>
<add><![CDATA[
array(
\'image\' => \'pawno\',
\'code\' => \'pawno\',
\'before\' => \'[pawno]\',
\'after\' => \'[/pawno]\',
\'description\' => $txt[\'bbc_pawn\']
),]]></add>
</operation>
</file>
<file name=\"$themedir/languages/Modifications.english.php\">
<operation>
<search position=\"end\" />
<add><![CDATA[
// Pawno Code Start
$txt[\'bbc_pawn\'] = \'Pawno Kod\';
$txt[\'pawnocode\'] = \'Pawno Kod\';
// Pawno Code End
]]></add>
</operation>
</file>
<file name=\"$sourcedir/QueryString.php\">
<operation>
<search position=\"replace\"><![CDATA[// If $scripturl is set to nothing, or the SID is not defined (SSI?) just quit.]]></search>
<add><![CDATA[
// Pawno BBCode Start
$buffer = preg_replace(\'~(, Simple Machines LLC</a>)~\', \', Simple Machines LLC</a><br /><span class=\"smalltext\"><a href=\"http://www.xerom-zone.com\" target=\"_blank\">Pawno BBCode by www.Xerom-Zone.com</a></span>\', $buffer);
$buffer = preg_replace(\'~(class=\"new_win\">Simple Machines</a>)~\', \'class=\"new_win\">Simple Machines</a><br /><span class=\"smalltext\"><a href=\"http://www.xerom-zone.com\" target=\"_blank\">Pawno BBCode by www.Xerom-Zone.com</a></span>\', $buffer);
// End Pawno BBCode
// If $scripturl is set to nothing, or the SID is not defined (SSI?) just quit.]]></add>
</operation>
</file>
</modification>