Before you pass $word to the mysql_query function, why don't you test to see if it is 'ok' or 'o k'. You could then modify it so that it's 'O & K'. You could it simply like this:
if(($word == 'ok') || ($word == 'o k')) {
$word = 'O & K';
}
Then, when $word is queried in mysql, it will...