Welcome Guest, Not a member yet? Register   Sign In
email problem with localhost XAMPP
#1

[eluser]Unknown[/eluser]
Code:
$config = array(
    'protocol' => 'smtp',
    'smtp_host' => 'ssl://smtp.gmail.com/',
    'smtp_port' => 465,
    'smtp_user' => '[email protected]',
    'smtp_pass' => 'nothing'
);

$this->load->library('email',$config);
$this->email->set_newline("\r\n");

$this->email->from('[email protected]','Hello..');
$this->email->to('[email protected]');
$this->email->subject('About...');
$this->email->message('Hello...!');

if($this->email->sent()){
    echo 'Sent!';
}
else{
    show_error($this->email->send_debugger());
    echo 'Sending message failed';  
}

help me...
when i access it will show the error referring to the line if($this->email->sent()){ :
Fatal error: Call to undefined method CI_Email:Confusedent()
#2

[eluser]toopay[/eluser]
Code:
//$this->email->sent() <== There is no 'sent' method within CI email library
$this->email->send()
#3

[eluser]Unknown[/eluser]
Whenever you works in local server (XAMPP or WAMP) for developing any email functionality in website, than you might be wonder that why email is not going from localhost(XAMPP or WAMP) in windows environment. Well, i faced the same situation and in this case i can help you. Below is the error you might get when working with email.
"Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in"
mouse control
#4

[eluser]Unknown[/eluser]
@ballerfollev: how did you solve your localhost email problem!
#5

[eluser]InsiteFX[/eluser]
He's a SPAMMER!
#6

[eluser]michalsn[/eluser]
@gchimuel for testing email functionality on localhost I always use this: http://www.toolheap.com/test-mail-server-tool/




Theme © iAndrew 2016 - Forum software by © MyBB