bibabutze
asked on
preg_match problem with line breaks
Hello Experts,
I´m using the following preg_match expression:
if (preg_match("/^FULLTEXT:(. *)",$descr iption,$de scarr))
to filter a variable called $description.
The following works fine:
$description = "FULLTEXT: Hello World, i´m a text";
As soon as i use line breaks, the preg_match does not work any more... e.g.
$description = "FULLTEXT: Hello World, i´m a text
And this is another line ";
The reason why there´s a line break is that the $description is a textarea field from a post form.
Does anybody know how i can tell preg_match to regard line breaks.
I´m using the following preg_match expression:
if (preg_match("/^FULLTEXT:(.
to filter a variable called $description.
The following works fine:
$description = "FULLTEXT: Hello World, i´m a text";
As soon as i use line breaks, the preg_match does not work any more... e.g.
$description = "FULLTEXT: Hello World, i´m a text
And this is another line ";
The reason why there´s a line break is that the $description is a textarea field from a post form.
Does anybody know how i can tell preg_match to regard line breaks.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.