cvs: php-gtk-web /include layout.php

From: Date: Thu, 09 Aug 2001 17:02:19 +0000
Subject: cvs: php-gtk-web /include layout.php
Groups: php.gtk 
Request: Send a blank email to php-gtk+get-2671@lists.php.net to get a copy of this message
cmv Thu Aug 9 13:02:19 2001 EDT Modified files: /php-gtk-web/include layout.php Log: clean_note() was inside another function ... duh Index: php-gtk-web/include/layout.php diff -u php-gtk-web/include/layout.php:1.10 php-gtk-web/include/layout.php:1.11 --- php-gtk-web/include/layout.php:1.10 Thu Aug 9 12:24:15 2001 +++ php-gtk-web/include/layout.php Thu Aug 9 13:02:17 2001 @@ -1,5 +1,5 @@ <?php -/* $Id: layout.php,v 1.10 2001/08/09 16:24:15 cmv Exp $ */ +/* $Id: layout.php,v 1.11 2001/08/09 17:02:17 cmv Exp $ */ # spacer() @@ -297,18 +297,17 @@ </html> <?php - -function clean_note($text) { - $text = htmlspecialchars($text); - $fixes = array('<br>','<p>','</p>'); - reset($fixes); - while (list(,$f)=each($fixes)) { - $text=str_replace(htmlspecialchars($f), $f, $text); - $text=str_replace(htmlspecialchars(strtoupper($f)), $f, $text); - } - $text = "<tt>".nl2br($text)."</tt>"; - return $text; } + +function clean_note($text) { + $text = htmlspecialchars($text); + $fixes = array('<br>','<p>','</p>'); + foreach ($fixes as $f) { + $text=str_replace(htmlspecialchars($f), $f, $text); + $text=str_replace(htmlspecialchars(strtoupper($f)), $f, $text); + } + $text = "<tt>".nl2br($text)."</tt>"; + return $text; }

« previous php.gtk (#2671) next »