How do I make it so if it finds the word News in a variable such as $text, it sets the $category variable to 1? Thanks!
According to the manual stripos() is php 5 only. If you are using php 4 use this code: $SearchWord = 'news'; if ( preg_match( "/$SearchWord/i", $text ) ) $category = 1; PHP: Brew