[eluser]nevsie[/eluser]
SPAM / JUNK folders can be cause by numerous things. 99% of time it will not be the script doing the sending causing this, but more that:
1. Subject and Body text contains word(s) that are triggering the SPAM filters
2. Your repeated sending of emails in mass all at one time may have caused your email address, servers IP address, domain to be blacklisted as a SPAMMER, hence all other systems refer to this central database of blocked addresses and block you too.
3. a person has reported you as SPAM and therefore the above block has been added
4. your mailservers/web server are not on the same IP and therefore systems can tell these emails are not coming from your mailserver, know they are automated, and detect them as spam. Look into SPF / TXT records for getting the other IP approved
5. you sending through scripts instead of using SMTP - they can detect this on the other end and see that its automated
etc etc etc etc etc etc...
My bet is if you sent 10,000 mails, your blacklisted for spamming - hence you ended up in spam folder.