RE: [PHP] question reg trim-strlen

2002-01-31 Thread B. Verbeek
Doing it... Thanks -Oorspronkelijk bericht- Van: Niklas Lampén [mailto:[EMAIL PROTECTED]] Verzonden: donderdag 31 januari 2002 13:53 Aan: [EMAIL PROTECTED]; Php-General Onderwerp: RE: [PHP] question reg trim-strlen Then why don't you just trim() it before comparing? $var = trim

RE: [PHP] question reg trim-strlen

2002-01-31 Thread Niklas Lampén
Then why don't you just trim() it before comparing? $var = trim($var); Niklas -Original Message- From: B. Verbeek [mailto:[EMAIL PROTECTED]] Sent: 31. tammikuuta 2002 13:33 To: [EMAIL PROTECTED] Subject: RE: [PHP] question reg trim-strlen I want to trim it then check and th

RE: [PHP] question reg trim-strlen

2002-01-31 Thread Niklas Lampén
I think it won't work. If you don't want to trim the actual variable, but check if the trimmed variable is longer than 50 chars, here you go: if (strlen(trim($cust_adres)) > 50) { } Niklas -Original Message- From: B. Verbeek [mailto:[EMAIL PROTECTED]] Sent: 31. tammikuut

Re: [PHP] question reg trim-strlen

2002-01-31 Thread Mike Maltese
Yep. - Original Message - From: "B. Verbeek" <[EMAIL PROTECTED]> To: "Php-General (E-mail)" <[EMAIL PROTECTED]> Sent: Thursday, January 31, 2002 2:48 AM Subject: [PHP] question reg trim-strlen > Does this work? > > >>if(strlen($cust_adres = trim($cust_adres)) > 50){ /*code here*