macfanpl Posted April 10, 2020 Share Posted April 10, 2020 OK so to start. We have our domain in the format X.com. Our new-mail form (php) is under mails.X.com. We use phpmail for sending mails. Receiving is disabled. There is apcall for mail() function in button's onclick event. Works as intended (gets call transmitted to phpmail function as well as MTP's) but mails never leaves our servers (and reaches receipient(s)). What may the problem be? Quote Link to comment https://forums.phpfreaks.com/topic/310522-mail-with-php-mailer/ Share on other sites More sharing options...
gw1500se Posted April 10, 2020 Share Posted April 10, 2020 Postfix configuration. Quote Link to comment https://forums.phpfreaks.com/topic/310522-mail-with-php-mailer/#findComment-1576643 Share on other sites More sharing options...
macfanpl Posted April 10, 2020 Author Share Posted April 10, 2020 2 hours ago, gw1500se said: Postfix configuration. What about it? Quote Link to comment https://forums.phpfreaks.com/topic/310522-mail-with-php-mailer/#findComment-1576650 Share on other sites More sharing options...
gw1500se Posted April 10, 2020 Share Posted April 10, 2020 You asked what the problem may be. That is my answer based on the code, details and error messages you posted. 1 Quote Link to comment https://forums.phpfreaks.com/topic/310522-mail-with-php-mailer/#findComment-1576653 Share on other sites More sharing options...
macfanpl Posted April 10, 2020 Author Share Posted April 10, 2020 1 hour ago, gw1500se said: You asked what the problem may be. That is my answer based on the code, details and error messages you posted. There is no need to be ironic here. You know well I didnt post either of these..... Quote Link to comment https://forums.phpfreaks.com/topic/310522-mail-with-php-mailer/#findComment-1576664 Share on other sites More sharing options...
gw1500se Posted April 10, 2020 Share Posted April 10, 2020 Exactly, thus the only answer possible. Quote Link to comment https://forums.phpfreaks.com/topic/310522-mail-with-php-mailer/#findComment-1576665 Share on other sites More sharing options...
macfanpl Posted April 11, 2020 Author Share Posted April 11, 2020 21 hours ago, gw1500se said: Exactly, thus the only answer possible. Disagree, but make peace, not war. Anyone else? Quote Link to comment https://forums.phpfreaks.com/topic/310522-mail-with-php-mailer/#findComment-1576708 Share on other sites More sharing options...
ginerjm Posted April 11, 2020 Share Posted April 11, 2020 You don't seem to be offering us anything to work on. At least one person responded with a guess. As for what you are asking us to do - your opening post makes absolutely no sense to me and apparently nobody else since they haven't responded either. What is "phpmail"? Never heard of that one. Maybe you meant phpmailer? A typo then. What is "MTP"? Perhaps you meant to say SMTP? What does "receiving is disabled" mean? Got me. What is a "new-mail form"? Got me What is an "ap-call for mail()"? Have no idea what you are trying to convey with this one. So many (apparently) mis-typed references here I can't follow what you are trying to say. Have you done any debugging of your process to see what it is doing? Any error messages you haven't read yet? You certainly haven't passed any on to us? But that was already mentioned. Quote Link to comment https://forums.phpfreaks.com/topic/310522-mail-with-php-mailer/#findComment-1576710 Share on other sites More sharing options...
macfanpl Posted April 12, 2020 Author Share Posted April 12, 2020 (edited) On 4/11/2020 at 7:12 PM, ginerjm said: What is "phpmail"? PHPMail is mail functionality built-in to PHP..... On 4/11/2020 at 7:12 PM, ginerjm said: What is "MTP"? MTP = Mail Transfer Protocol On 4/11/2020 at 7:12 PM, ginerjm said: What does "receiving is disabled" mean? It means you can (theoretically) send mail outwards. but this form does not allow you to receive ( = read) inward mails. On 4/11/2020 at 7:12 PM, ginerjm said: What is a "new-mail form"? It means the PHP form (webpage) for sending mails. On 4/11/2020 at 7:12 PM, ginerjm said: What is an "ap-call for mail()"? I meant API On 4/11/2020 at 7:12 PM, ginerjm said: Have you done any debugging of your process to see what it is doing? Oh yes..... main problem with debugger is that no errors are being reported. One reason may be faulty debugger. Edited April 12, 2020 by macfanpl Quote Link to comment https://forums.phpfreaks.com/topic/310522-mail-with-php-mailer/#findComment-1576743 Share on other sites More sharing options...
ginerjm Posted April 12, 2020 Share Posted April 12, 2020 Debugging sometimes is best done by you putting outputs into your script to track the path your logic is taking. As well as to confirm your assumptions. In my experience forms never receive mail, hence my confusion. Using the term PHPMail is so close to name of the PHPMailer product that there was confusion. I've never seen anyone capitalize the PHP mail function that way before - hence the confusion. I do believe that if anyone else were to jump in here (and in 48 hrs. it doesn't seem to be happening) the first thing they would suggest is to download and use PHPMailer, a different and well-respected mailing package. And anytime you want to post some code in the general area of concern with this problem, I"m sure you would get some additional help. Quote Link to comment https://forums.phpfreaks.com/topic/310522-mail-with-php-mailer/#findComment-1576744 Share on other sites More sharing options...
macfanpl Posted April 12, 2020 Author Share Posted April 12, 2020 51 minutes ago, ginerjm said: Debugging sometimes is best done by you putting outputs into your script to track the path your logic is taking You are absolutely right. But, its a bit tricky when it comes to mail forms (templates).... 52 minutes ago, ginerjm said: In my experience forms never receive mail, To be precise, its mail-server which receives mail, and this (incoming mail) triggers some sort of action (eg. notification) in the form (template). 53 minutes ago, ginerjm said: Using the term PHPMail is so close to name of the PHPMailer product that there was confusion. What do you suggest than? 54 minutes ago, ginerjm said: And anytime you want to post some code in the general area of concern with this problem, I"m sure you would get some additional help. Thanks for this tip. Quote Link to comment https://forums.phpfreaks.com/topic/310522-mail-with-php-mailer/#findComment-1576746 Share on other sites More sharing options...
ginerjm Posted April 12, 2020 Share Posted April 12, 2020 I have given you several suggestions. All you want to do is debate them. Good luck. I've obviously been wasting my time and energy. Quote Link to comment https://forums.phpfreaks.com/topic/310522-mail-with-php-mailer/#findComment-1576747 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.