Dan, if you are entering the words in a form, when the variable holding the string hits your script do something like this.... (Hey I just figured this out myself too!!!!
Gotta love these lists!!!!!!!! $tmpStr= whatever the form passes your script // turn string into an array // use EXPLODE() to seperate the words into an array // since they are seperated by a " " (blank space) $tmpAry = explode(' ',$tmpStr); // if they were seperated by commas you would write $tmpAry = explode(',',$tmpStr); // DIG???? // then just use count($tmpAry) to figure out the size of your array // and you have the number of words! There might be an easier way than that, but it workes for me. -Peace dude!!!!!!!! PS: Thank Andrew Braund for the solution, he sent a varriant of it to me!!!!!!!!!!!! That's two people you helpes Andrew! YOU RULE!!!!!!!!!!!!!!! - NorthBayShane -----Original Message----- From: Peter [mailto:[EMAIL PROTECTED]] Sent: Thursday, July 11, 2002 6:20 PM To: Dan McCullough; PHP General List Subject: RE: [PHP] HELP!!! Word count if i remember correctly there was something on word counts posted in the last week or or .. maybe even last couple days... have a scroll thru and u will find it :) > -----Original Message----- > From: Dan McCullough [mailto:[EMAIL PROTECTED]] > Sent: Friday, 12 July 2002 11:08 AM > To: PHP General List > Subject: [PHP] HELP!!! Word count > > > I have some clients who want to charge a flat rate for words > entered, but over a certain number of > words there is an additional charge, to complicate matters there > is an option/addon where you can > bold the lines, and there is a charge per line, so you have to > calculate the total number of lines > based on character total. > > Anyone know of way to accomplish this, I know that it will have > to be done in seperate ways. but > does anyone have an idea or two .. hlp > > thanks, > > dan > > __________________________________________________ > Do You Yahoo!? > Sign up for SBC Yahoo! Dial - First Month Free > http://sbc.yahoo.com > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php