: Problems using PHP on a Plesk Windows dedicated server I'm having a few issues with my dedicated Windows server that has a Plesk panel: 1.) I can't send e-mail via PHP's mail() function, it
I'm having a few issues with my dedicated Windows server that has a Plesk panel:
1.) I can't send e-mail via PHP's mail() function, it always returns the following error:
SMTP server response: 550 Requested action not taken: mailbox
unavailable or not local
Which setting should I alter in order to enable sending mail?
2.) The exec() and passthru() PHP functions don't work; their outputs are blank even when I try to run simple commands such as dir. Is there an option that I can toggle in the control panel to enable this functionality?
More posts by @Bryan171
1 Comments
Sorted by latest first Latest Oldest Best
2.) This is a common problem for PHP in Plesk due to the security settings that it adds:
Find httpd.include in the vhosts directory you're running the PHP script from and set the value for safe_mode to off.
Also make sure you have enabled PHP Support under: Websites & Domains -> Web Scripting and Statistics, as covered here.
1.) There could be a number of different possibilities (in order of likelihood):
As the message indicates, you could be trying to send an email to a local email address (like via a contact form) that isn't defined in your mail server. Check to see if you're using a valid local email address (i.e., it appears as an email account under the associated domain), and also use this address as the "from" address too (e.g., postmaster@yourdomain.com)
The email address you're sending to doesn't exist on the external mail server. Verify that the email address you're sending to is valid and can receive email from your domain (e.g., use Webmail for the "from" address account to send an email to this address).
The settings for your mail server could be set to reject relaying if you're trying to send an email to an external address (e.g., a Gmail address). Check the Relay Options under Mail Settings and make sure that SMTP is checked and that Use no relay restrictions for the following networks includes: 127.0.0.1/32
Make sure you have the correct SMTP settings and "from" address in your php.ini file:
[mail function]
SMTP = localhost
smtp_port = 25
sendmail_from = postmaster@yourdomain.com
For any additional help, I'd suggest posting a question at Parallels Plesk forum
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.