Welcome Guest, Not a member yet? Register   Sign In
Mailing content, getting unwanted characters
#1

[eluser]grezly[/eluser]
I'm trying to create a mailinglist (small one).

But if i'm sending email i get the following characters in my email:
"00" en "3D"

Code:
<div class=3D"block">
=00
<h3>Nieuwsbrief 2</h3>
<h4>Nieuwsbrief van 2008-08-26 11:01:11<br /></h4>
<p>

or
Code:
link href=3D"testing.com" rel=
=3D"stylesheet" type=3D"text/css" />
eg. The testing.com is a replaced url
I'm getting the content with
Code:
$content = file_get_contents($data['url'].$newsbrief_url.$id);
If i'm watching that url that's been given with file_get_contents everything is normal.

For the loop to email i'm using the following

Code:
foreach($users as $user)
        {
            $this->email->clear(TRUE);
            $this->email->initialize($config);
            $this->email->from($this->config->item('to_email'), 'testing');
            $this->email->message($content);
            $this->email->subject($onderwerp);
            $this->email->to($user);
            $this->email->send();
            $data['block'] .= $this->email->print_debugger();
        }

The config files that i use are
Code:
$config['mailtype'] = 'html';



So when i'm getting the html-mail in my mailbox it will quit opening until the "00" character (00-byte?).
#2

[eluser]eldiablo[/eluser]
i'm getting the same thing
any solutions?
#3

[eluser]eldiablo[/eluser]
Same thing here
running Windows Wamp any solutions
#4

[eluser]aidehua[/eluser]
Were you on localhost? I was, and had this problem. Here's how I fixed it

See http://ellislab.com/forums/viewthread/69463/#818990
#5

[eluser]chamil sanjeewa[/eluser]
this code is working fine
$this->load->library('email');
$this->load->library('parser');



$this->email->clear();
$config['mailtype'] = "html";
$this->email->initialize($config);
$this->email->set_newline("\r\n");
$this->email->from('[email protected]', 'Website');
$list = array('[email protected]', '[email protected]');
$this->email->to($list);
$data = array();
$htmlMessage = $this->parser->parse('messages/email', $data, true);
$this->email->subject('This is an email test');
$this->email->message($htmlMessage);



if ($this->email->send()) {
echo 'Your email was sent, thanks chamil.';
} else {
show_error($this->email->print_debugger());
}




Theme © iAndrew 2016 - Forum software by © MyBB