I hope this is what you mean.
$string = "word1 word2 word3 word4";
$word = explode (" ", $string); // or use the split function
for ($cnt=0; $cnt<sizeof($word); $cnt++)
{
if ($word[$cnt] == strtoupper($word[$cnt]))
{
$word[$cnt] = strtolower($word[$cnt]);
}
}