How To Count Array Values Php Counting Arrays Holds Variables Script
RegisterLogin
How To Count Array Values Php Counting Arrays Holds Variables Script
Post Description: How To Count Array Values Php Counting Arrays Holds Variables Script
Tags: How, To, Count, Array, Values, Php, Counting, Arrays, Holds, Variables, Script
This Post Was Posted On Feb 29, 2008 By web hosting #1292
Post Description: How To Count Array Values Php Counting Arrays Holds Variables Script
Tags: How, To, Count, Array, Values, Php, Counting, Arrays, Holds, Variables, Script
This Post Was Posted On Feb 29, 2008 By web hosting #1292
How To Count Array Values Php Counting Arrays Holds Variables Script by web hosting
example:
$items = array("one", "two", "three", "four", "five", "six", "seven");
Leave Your Comments
Related Pages: [Add Your Website]
Post New Topic
Julius
#1721 1
thanks this was helpful. i was storing some values in a comma separated list and converting it to an array with explode and didn't notice the comma at the end of the list nothing after it was being counted as an element and causing problems until i counted the number of value s in the array.
Feb 14, 2008 Reply Report abuse
lucas
#1720 2
that's very easy, just use the count() function in php..
you can do this:
PHP CODE:
OUTPUT
you can do this:
PHP CODE:
<?
$items = array("one", "two", "three", "four", "five", "six", "seven");
echo count($items);
?>
$items = array("one", "two", "three", "four", "five", "six", "seven");
echo count($items);
?>
OUTPUT
7
Feb 11, 2008 Reply Report abuse
©2011 Webune Forums - Mon Dec 19, 2011 6:23 pm
Powered by: Webune Forums V3
Powered by: Webune Forums V3