note 52774 added to function.array-count-values
| From: | alwaysdrunkatgmailcom at osu1 dot php dot net | Date: | Thu, 12 May 2005 07:14:28 +0000 |
| Subject: | note 52774 added to function.array-count-values | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-89303@lists.php.net to get a copy of this message | ||
if you have too many values in $_POST,$_GET array that needs to be controlled with isset() in oreder
to understand the form is filled completely and have no empty text boxes.
you can try this,it saves time.
<?
$n = array_count_values($_POST);
if (!isset($n[''])) {
echo "The form is filled completely";
}
else
{ die("Please fill the form comlpetely"); }
//tested in php 5
?>
----
Manual Page -- http://www.php.net/manual/en/function.array-count-values.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+52774
Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+52774&report=yes&reason=added+to+the+manual
Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+52774&report=yes&reason=bad+code
Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+52774&report=yes&reason=spam
Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+52774&report=yes&reason=useless
Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+52774&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+52774&report=yes
Search -- http://master.php.net/manage/user-notes.php