Re: [PHP] vertical word match SOLUTION

2002-07-24 Thread Analysis Solutions
Hi Joe: On Fri, Jul 19, 2002 at 12:50:53PM -0500, 'Joe Rice' wrote: $answer = hello\na\np\np\nl\ne\n; /*from textarea in form*/ /* replace all whitespace and newlines with nothing */ $tempanswer = preg_replace(/\s*|\n*/,,$answer); Easier: $tempanswer = preg_replace('/\s/', '', $answer);

[PHP] vertical word match

2002-07-18 Thread Joe Rice
hello, any regex gurus? i'm trying to match words put into a textarea that are in the form of a\np\np\l\e or any combination of new lines in between, before or after. $answer = hello\na\np\np\nl\ne\n; /*from textarea in form*/ $word = apple; $word =

RE: [PHP] vertical word match

2002-07-18 Thread Martin Towell
try changing the +'s with *'s + = 1 or more * = 0 or more -Original Message- From: Joe Rice [mailto:[EMAIL PROTECTED]] Sent: Friday, July 19, 2002 3:30 PM To: [EMAIL PROTECTED] Subject: [PHP] vertical word match hello, any regex gurus? i'm trying to match words put into a textarea