Hello,
Is there any way to allow PHP mail only send emails to local email addresses,
For Example:
Lets say we have a contact form on a website "example.com" and its coded to sent email to [email protected] if someone fills that form on website it should work, But if its coded to sent emails to [email protected].net or [email protected] or any external domain it should not work.
Reason:
I don't want to turn off PHP mail function on server but as I have 900+ websites hosted on a server if a single WordPress website gets hacked it starts sending SPAM and gets main IP blacklisted.
Is there any way to allow PHP mail only send emails to local email addresses,
For Example:
Lets say we have a contact form on a website "example.com" and its coded to sent email to [email protected] if someone fills that form on website it should work, But if its coded to sent emails to [email protected].net or [email protected] or any external domain it should not work.
Reason:
I don't want to turn off PHP mail function on server but as I have 900+ websites hosted on a server if a single WordPress website gets hacked it starts sending SPAM and gets main IP blacklisted.
Last edited by a moderator: