Re: [PHP] Byte size of text?

2004-09-08 Thread Marek Kilimajer
Rasmus Lerdorf wrote: On Wed, 8 Sep 2004, Marek Kilimajer wrote: John Smith wrote: What's the most accurate way to get the byte count of some text? Is strlen() accurate with Unicode, ASCII, etc.? John strlen() is fine even for multibyte encodings, it does not know about encoding and returns the "ra

Re: [PHP] Byte size of text?

2004-09-08 Thread Rasmus Lerdorf
On Wed, 8 Sep 2004, Marek Kilimajer wrote: > John Smith wrote: > > What's the most accurate way to get the byte count of > > some text? Is strlen() accurate with Unicode, ASCII, > > etc.? > > > > John > > > > strlen() is fine even for multibyte encodings, it does not know about > encoding and retur

Re: [PHP] Byte size of text?

2004-09-08 Thread Marek Kilimajer
John Smith wrote: What's the most accurate way to get the byte count of some text? Is strlen() accurate with Unicode, ASCII, etc.? John strlen() is fine even for multibyte encodings, it does not know about encoding and returns the "raw" size. If you wanted the number of characters, you would need

Re: [PHP] Byte size of text?

2004-09-07 Thread raditha dissanayake
John Smith wrote: What's the most accurate way to get the byte count of some text? Is strlen() accurate with Unicode, ASCII, etc.? if you are working with non ASCII characters you might want to install the mulitbyte string extension. -- Raditha Dissanayake.

[PHP] Byte size of text?

2004-09-07 Thread John Smith
What's the most accurate way to get the byte count of some text? Is strlen() accurate with Unicode, ASCII, etc.? John __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com -- PHP General Mailing