I have a mysterious problem with my PHP contact form not resolving to the correct email account.
I recently changed hosting service and obviously this required me to migrate my whole website to a new server.
My old hosting company, I'll call them "Badhost," also provided me with free email accounts for my domain.
My domain has always been registered with Network Solutions.
About 8 months ago, I switched my hosting services from Badhost to Network Solutions, and I switched my email services to Rackspace.
My new hosting package with NS uses the Unix OS and Apache server.
I still use the same PHP script in my contact form that I used when it was hosted with Badhost, but I've just made a few changes in the string-objects that get sent in my call to the PHP
mail()
function.
I updated the MX records in my NS account with the proper Rackspace records. (This was months ago and the MX records still correctly point to Rackspace.)
Most contact form requests submitted through my PHP script resolve correctly to my Rackspace email inbox.
However, once every month or so, I'll get a submission that resolves to my
old Badhost email account as if I still used the Badhost MX records (I have NOT YET closed the Badhost account). On top of that, the submitted contact information is in the old format (by that I mean the email message does not reflect how I changed the string-objects in my PHP
mail()
call).
I am not sure what to do. The annual billing cycle for Badhost is approaching and I obviously do not want to renew with them. But what will happen to those emails that resolve to the Badhost account if I close the account?
I don't understand why, with new MX records, would my PHP script send an email to the old email account? And I really don't understand why it seems like the PHP script
itself is my old, out-of-date script using my old formatting.
Should I close my Badhost account and just hope that once it's disabled all my PHP form submissions will resolve correctly to Rackspace?