638 posts
  • Has been part of the Envato Community for over 5 years
  • Has sold $100+ on Envato Market
  • Has collected 100+ items on Envato Market
  • Sells items exclusively on Envato Market
+2 more
RobbyDesigns says

Thanks for looking. I need to overcome this final obstacle so’s I can get my site online, appreciate your help.

Ok, my PHP mail just wont work. Here’s the code:

<?php $headers = “MIME-Version: 1.0\r\n”; $headers .= “Content-type: text/html; charset=iso-8859-1\r\n”;

$senderName = $_POST[‘iname’]; $senderEmail = $_POST[‘iemail’]; $senderSubject = $_POST[‘isubject’]; $senderMsg = nl2br($_POST[‘imensage’]); $to = “example@robbydesigns.com”; $date = date(“d-m-Y / H:i:s”);

$EmailBody = “Name: $senderName<br ?> Email: $senderEmail
Message:
$senderMsg”; $EmailFooter = “
Date / Time: $date

”; $Message = $EmailBody.$EmailFooter; $ok = mail($to, $senderSubject, $Message, $headers . “From:$senderName <”.$to.”>”); if($ok){ echo “retval=1”; }else{ echo “retval=0”; }

?>

I was told it may be a port problem so I asked JustHost.com and they said:

“1.port 25 isn’t blocked on our server. Your developer also can try to use port 2626, this is alternate SMTP port. Regarding this problem I can advise to enable option “SMTP authentication” in your script as server required SMTP authentication.

2. sendmail isn’t disabled. You can find sendmail path in your cPANEL.

3. Our server uses ports 25 and 2626 for mail sending.”

..Any ideas please?

Helpful Information

  • Please read our community guidelines. Self promotion and discussion of piracy is not allowed.
  • Open a support ticket if you would like specific help with your account, deposits or purchases.
  • Item Support by authors is optional and may vary. Please see the Support tab on each item page.

Most of all, enjoy your time here. Thank you for being a valued Envato community member.

Post Reply

Format your entry with some basic HTML. Read the Full Details, or here is a refresher:

<strong></strong> to make things bold
<em></em> to emphasize
<ul><li> or <ol><li> to make lists
<h3> or <h4> to make headings
<pre></pre> for code blocks
<code></code> for a few words of code
<a></a> for links
<img> to paste in an image (it'll need to be hosted somewhere else though)
<blockquote></blockquote> to quote somebody

:grin: :shocked: :cry: Complete List of Smiley Codes

by
by
by
by
by
by