onokazu
onoka****@users*****
2005年 6月 6日 (月) 14:59:39 JST
Index: xoops2jp/html/class/module.textsanitizer.php diff -u xoops2jp/html/class/module.textsanitizer.php:1.2.6.1 xoops2jp/html/class/module.textsanitizer.php:1.2.6.2 --- xoops2jp/html/class/module.textsanitizer.php:1.2.6.1 Mon Jun 6 08:10:31 2005 +++ xoops2jp/html/class/module.textsanitizer.php Mon Jun 6 14:59:39 2005 @@ -1,5 +1,5 @@ <?php -// $Id: module.textsanitizer.php,v 1.2.6.1 2005/06/05 23:10:31 onokazu Exp $ +// $Id: module.textsanitizer.php,v 1.2.6.2 2005/06/06 05:59:39 onokazu Exp $ // ------------------------------------------------------------------------ // // XOOPS - PHP Content Management System // // Copyright (c) 2000 XOOPS.org // @@ -401,11 +401,11 @@ $patterns = "/\[code](.*)\[\/code\]/esU"; if ($image != 0) { // image allowed - $replacements = "'<div class=\"xoopsCode\"><code>'.MyTextSanitizer::codeSanitizer('$1').'</code></div>'"; + $replacements = "'<div class=\"xoopsCode\"><code><pre>'.MyTextSanitizer::codeSanitizer('$1').'</pre></code></div>'"; //$text =& $this->xoopsCodeDecode($text); } else { // image not allowed - $replacements = "'<div class=\"xoopsCode\"><code>'.MyTextSanitizer::codeSanitizer('$1', 0).'</code></div>'"; + $replacements = "'<div class=\"xoopsCode\"><code><pre>'.MyTextSanitizer::codeSanitizer('$1', 0).'</pre></code></div>'"; //$text =& $this->xoopsCodeDecode($text, 0); } $text = preg_replace($patterns, $replacements, $text);