Hello,
This is a reply to an e-mail that you wrote on Thu, 26 Jun 2003 at 12:36, lines prefixed by '>' were originally written by you. > foreach($words as $thisword){ > if(in_array($thisword, $array)){ > $array[$thisword]++; > } else { > $array[$thisword]=1; > } Just realised my own mistake... The if statement shoud be if(isset($array[$thisword])) as the word is the key and not a value in the array. David. -- phpmachine :: The quick and easy to use service providing you with professionally developed PHP scripts :: http://www.phpmachine.com/ Professional Web Development by David Nicholson http://www.djnicholson.com/ QuizSender.com - How well do your friends actually know you? http://www.quizsender.com/ (developed entirely in PHP) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php