--- khing2 <[EMAIL PROTECTED]> wrote:
> Is there a php function that removes all these characters?? \n \r etc 
> etc etc.
> 
> I found one way was to do a preg_match and do a specific pattern for 
> them. but i was just wondering if there is something build in for that?


str_replace() is faster than preg_match() in most cases.  You will have to run
the function twice, once for each word, or put the search values in an
associative array.  See the docs for details:

http://www.php.net/str_replace

James
_____


James D. Keeline
http://www.Keeline.com  http://www.Keeline.com/articles
http://Stratemeyer.org  http://www.Keeline.com/TSCollection

http://www.ITeachPHP.com -- Free Computer Classes: Linux, PHP, etc.
Spring Semester Begins Jan 31 -- New Classes Start Every Few Weeks.


Community email addresses:
  Post message: [email protected]
  Subscribe:    [EMAIL PROTECTED]
  Unsubscribe:  [EMAIL PROTECTED]
  List owner:   [EMAIL PROTECTED]

Shortcut URL to this page:
  http://groups.yahoo.com/group/php-list 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/php-list/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to