Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Function set_magic_quotes_runtime() is deprecated in phpmailer

I want to embed an image with PHP Mailer version 5.1.. and my PHP version is 5.4.7

The script execution is a success, and I can receive emails with embedded images, but the problem is warnings appear like this:

Deprecated: Function set_magic_quotes_runtime() is deprecated in C:\xampp\htdocs\form\class.phpmailer.php on line 1480

Deprecated: Function set_magic_quotes_runtime() is deprecated in C:\xampp\htdocs\form\class.phpmailer.php on line 1484

and my script is is

$mail->AddEmbeddedImage('filename', 'cid', 'name');
$mail->AddEmbeddedImage('sgu_logo.gif', 'my-pics', 'sgu_logo.gif');

$mail->Body     =  "Thank you for registering at SGU. For further processing please complete a registration fee before &nbsp; ". $e['testschedule']." <br> For future information please contact us at sgu.ac.id/support <br><br> 
<img src='cid:sgu_logo.gif' alt='my-pics' />.";
like image 903
Prabu Karana Avatar asked Nov 26 '22 10:11

Prabu Karana


1 Answers

It's because magic_quotes_runtime functions are deprecated starting from 5.3 PHP version, but 5.1 version of PHPmailer still uses them. Try to upgrade to PHPmailer 5.2, the problem should be solved, more info here: http://code.google.com/a/apache-extras.org/p/phpmailer/source/detail?r=66

like image 170
antodippo Avatar answered Nov 29 '22 05:11

antodippo