{"id":1041,"date":"2011-10-17T21:20:02","date_gmt":"2011-10-18T04:20:02","guid":{"rendered":"http:\/\/truelogic.org\/wordpress\/?p=1041"},"modified":"2011-10-17T21:20:02","modified_gmt":"2011-10-18T04:20:02","slug":"php-mail-function-not-working-in-windows-server","status":"publish","type":"post","link":"https:\/\/truelogic.org\/wordpress\/2011\/10\/17\/php-mail-function-not-working-in-windows-server\/","title":{"rendered":"PHP Mail function not working in Windows Server"},"content":{"rendered":"<p>For all of the people struggling with getting <strong>PHP<\/strong> <strong>mail<\/strong>() sending to some, but <strong>not<\/strong> all, recipients&#8230;look no farther. Your solution has been posted here.<\/p>\n<p>It appears PHP-generated emails don&#8217;t play nice <strong>on<\/strong> <strong>Windows<\/strong> <strong>mail<\/strong> servers. So, when your <strong>mail<\/strong> goes to anyone who uses a <strong>Windows<\/strong> <strong>mail<\/strong> server , the recipients won&#8217;t get it. UNLESS YOU ADD THE LINE:<\/p>\n<p>&lt;?<\/p>\n<div id=\"code1232824924_1\">\n<div>ini_set (&#8220;SMTP&#8221;,&#8221;mail.mydomainname.com&#8221;);<br \/>\nini_set(&#8220;smtp_port&#8221;,&#8221;25&#8243;);<br \/>\nini_set(&#8220;sendmail_from&#8221;, &#8220;info@mydomainname.com&#8221;);<\/div>\n<div>?&gt;<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<div class=\"mh-excerpt\"><p>For all of the people struggling with getting PHP mail() sending to some, but not all, recipients&#8230;look no farther. Your solution has been posted here. <a class=\"mh-excerpt-more\" href=\"https:\/\/truelogic.org\/wordpress\/2011\/10\/17\/php-mail-function-not-working-in-windows-server\/\" title=\"PHP Mail function not working in Windows Server\">[&#8230;]<\/a><\/p>\n<\/div>","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-1041","post","type-post","status-publish","format-standard","hentry","category-apachephp"],"_links":{"self":[{"href":"https:\/\/truelogic.org\/wordpress\/wp-json\/wp\/v2\/posts\/1041","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/truelogic.org\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/truelogic.org\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/truelogic.org\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/truelogic.org\/wordpress\/wp-json\/wp\/v2\/comments?post=1041"}],"version-history":[{"count":0,"href":"https:\/\/truelogic.org\/wordpress\/wp-json\/wp\/v2\/posts\/1041\/revisions"}],"wp:attachment":[{"href":"https:\/\/truelogic.org\/wordpress\/wp-json\/wp\/v2\/media?parent=1041"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/truelogic.org\/wordpress\/wp-json\/wp\/v2\/categories?post=1041"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/truelogic.org\/wordpress\/wp-json\/wp\/v2\/tags?post=1041"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}