Hello,
I am trying to clean up my string before I make my sql statement. I am haveing trouble with going through my noise word list and kicking out matches. I am currently using the ereg_replace(), but that is not going to work because in "Colorado" it kicks out the the "a" so then it letter becomes two words "Color" "do". If a user types "A Colorado" I want to kick out the "A" so it looks like "Colorado". Thanks for any help...
$queryCleanUp=ereg_replace("[[:alnum:]]"," ",trim($query));
//////////////////////////////////////////
for ($i=0;$i<188;++$i){
$queryCleanUp=ereg_replace("$noiseWord[$i]"," ",strtoupper(trim($queryCleanUp)));
}
//////////////////////////////////////////
$queryCleanUp=ereg_replace("[[:space:]]+"," ",trim($queryCleanUp));
$queryWords=split(" ", $queryCleanUp);
$queryNum=count($queryWords);