note 106238 deleted from function.strip-tags by aharvey

From: Date: Thu, 20 Sep 2012 12:15:38 +0000
Subject: note 106238 deleted from function.strip-tags by aharvey
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-190928@lists.php.net to get a copy of this message
Note Submitter: shimy1984 ---- The following is an easy way to use strip_tags() with a simple array or a multidimensional array. <?php function strip_tags_array($data, $tags = null) { $stripped_data = array(); foreach ($data as $value) { if (is_array($value)) { $stripped_data[] = strip_tags_array($value, $tags); } else { $stripped_data[] = strip_tags($value, $tags); } } return $stripped_data; } ?>

« previous php.notes (#190928) next »