Jump to content

PHP Mail shot help


Orionsbelter

Recommended Posts

Hi when i send off a mail shot, it comes up as it was sent by @ip-68-178-248-83.ip.secureserver.net, i want it to just come up as my domain.

 

here is the code


		$subj		=	"Invitation From Lock Down City";
		$emess		=	"Hi There $v,
You Have Been Invited To Visit http://www.lock-down-city.com, 
One Of The Newest and greatest online games, But Needs Players Online So It Can Go Bigger. This Will Most Probably Be The Best Browser Based Gangster RPG You Ever Set Your Eyes on.

Just Visit The Tite & View The List Of Features, If Your Not Satisfied Then Post A Support Ticket To Have Your Account Deleted. Its That Simple! You Never Know You Might End Up Loving It.";
		mail("$v","$subj","$emess","From: Lock-Down-City");

Link to comment
https://forums.phpfreaks.com/topic/130888-php-mail-shot-help/
Share on other sites

Try this code:

 

<?php 

mail("$v","$subj","$emess","from: noreply@".str_replace('www.','',$_SERVER['HTTP_HOST']), "-fnoreply@".str_replace('www.','',$_SERVER['HTTP_HOST']));

?>

 

If your site is foo.com then it will appear from: [email protected]

As I remember the -f specifies "return path" that is related to your issue.

 

I hope this helps.

Link to comment
https://forums.phpfreaks.com/topic/130888-php-mail-shot-help/#findComment-680001
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.