Welcome Guest, Not a member yet? Register   Sign In
Mail system Error
#1

[eluser]Shiju S S[/eluser]
I have done code for sending mails
Code:
$emailto = '[email protected]';
$subject = $fname.' '.$position;
  
$body  ="Name: $fname \n\n";
$body .="Email: $email \n\n";
$body .="Phone:$phone\n\n";
   $body .="City:$city\n\n";
  
        $this->email->to($emailto);
        $this->email->from($email);
$this->email->subject($subject);
$this->email->message($body);
$this->email->send();


I am getting an error message in the FROM email address:

Mail Delivery Subsystem [email protected]

The original message was received at Sat, 17 Mar 2012 13:04:29 -0700
from localhost [127.0.0.1]

----- The following addresses had permanent fatal errors -----
<[email protected]>
(reason: 553 sorry, your mail was administratively denied. (#5.7.1))

----- Transcript of session follows -----
... while talking to relay-hosting.secureserver.net.:
>>> MAIL From:<[email protected]> SIZE=1059
<<< 553 sorry, your mail was administratively denied. (#5.7.1)
501 5.6.0 Data format error

Final-Recipient: RFC822; [email protected]
Action: failed
Status: 5.1.3
Diagnostic-Code: SMTP; 553 sorry, your mail was administratively denied. (#5.7.1)
Last-Attempt-Date: Sat, 17 Mar 2012 13:04:29 -0700


---------- Forwarded message ----------
From: <[email protected]>
To: [email protected]
Cc:
Date: Sat, 17 Mar 2012 13:04:29 -0700
Subject: Shiju S S Team Leader – New Client Acquisition
Name: Shiju S S

Email: [email protected]

Phone:9895036243

City:Ekm

What can be the reason:
The conventional mail is working well
Code:
$headers = 'From: '.'Manager '.' <'.$emailto.'>' . "\r\n" . 'Reply-To: ' . $email;
mail($emailto, $subject, $body, $headers);
#2

[eluser]InsiteFX[/eluser]
Because you forgot the second parameter!
Code:
$this->email->from('[email protected]', 'Your Name');
#3

[eluser]Shiju S S[/eluser]
Changed code to
Code:
$fname = $this->input->post('fname');
   $email = $this->input->post('email');
   $position = $this->input->post('position');
   $phone = $this->input->post('phone');
   $city = $this->input->post('city');
  
   $emailto = '[email protected]';
   $subject = $fname.' '.$position;
  
   $body  ="Name: $fname \n\n";
   $body .="Email: $email \n\n";
   $body .="Phone:$phone\n\n";
   $body .="City:$city\n\n";

  
   $this->email->to($emailto);
      $this->email->from($email,$fname);
   $this->email->reply_to($email,$fname);
      $this->email->subject($subject);
   $this->email->set_newline("\r\n");
      $this->email->message($body);
   $this->email->send();
Again getting the same error:
Quote:The original message was received at Sat, 17 Mar 2012 16:08:13 -0700
from localhost [127.0.0.1]

----- The following addresses had permanent fatal errors -----
<[email protected]>
(reason: 553 sorry, your mail was administratively denied. (#5.7.1))

----- Transcript of session follows -----
... while talking to relay-hosting.secureserver.net.:
>>> MAIL From:<[email protected]> SIZE=1071
<<< 553 sorry, your mail was administratively denied. (#5.7.1)
501 5.6.0 Data format error

Final-Recipient: RFC822; [email protected]
Action: failed
Status: 5.1.3
Diagnostic-Code: SMTP; 553 sorry, your mail was administratively denied. (#5.7.1)
Last-Attempt-Date: Sat, 17 Mar 2012 16:08:13 -0700


---------- Forwarded message ----------
From: "Shiju S S" <[email protected]>
To: [email protected]
Cc:
Date: Sat, 17 Mar 2012 16:08:13 -0700
Subject: Shiju S S Team Leader – New Client Acquisition
Name: Shiju S S

Email: [email protected]

Phone:9895036243

City:Ekm

My error reporting function gives message:
Quote:From: "Shiju S S"
Return-Path:
Reply-To: "[email protected]"
X-Sender: [email protected]
X-Mailer: CodeIgniter
X-Priority: 3 (Normal)
Message-ID: <[email protected]>
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
=?utf-8?Q?Shiju_S_S_Team_Leader_=e2=80=93_New_Client_Acquisition?=
Name: Shiju S S

Email: [email protected]

Phone:9895036243

City:Ekm

Please help. My server is in godaddy
#4

[eluser]InsiteFX[/eluser]
Try changing the email to to some other address, some server will not allow send from and to to the same server.

Also did you setup your email in php.in and your email config?
#5

[eluser]Shiju S S[/eluser]
I think the problem is with the goddady. The mail sending worked by using an emailid registered in goddady in the from field.

Is there any other solution. Thanks for the help.




Theme © iAndrew 2016 - Forum software by © MyBB