sounds like php is sending the email ok.
curious, what domain are you trying to send an email to? like for example, hotmail.com?
hotmail seems to flag emails as spam unless they contain certain headers
try using these headers
$headers = "From: $from\n";
$headers .= "Reply-To: $from\n";
$headers .= "X-MSMail-Priority: High\n";
it could also be that your from email address is on a spam blacklist for some reason, causing emails from you to be flagged as spam.