PHP Classes

Class doesn't work for me

Recommend this page to a friend!

      PHP Mail Class  >  All threads  >  Class doesn't work for me  >  (Un) Subscribe thread alerts  
Subject:Class doesn't work for me
Summary:Fatal error on line 204
Author:karl kir
Date:2019-04-02 15:55:38

  1. Class doesn't work for me   Reply   Report abuse  
karl kir - 2019-04-02 15:55:38

I try you class and when i try to send a smtp mail with i receive this error :

Fatal error: Default value for parameters with a class type hint can only be NULL in /public_html/class/Mail.class.php on line 204

//Example using smtp
$mail = new Mail;

//Set subject and sender of the mail.
$mail->setSubject('Example mail');
//Set the plain content of the mail.
$mail->setContentPlain('Example plain-content!');
//Add a receiver of the mail (you can add more than one receiver too).

//Finally send the mail.

Do you have any solution for me?


  2. Re: Class doesn't work for me   Reply   Report abuse  
Muhammad Umer Farooq - 2019-04-03 02:18:51 - In reply to message 1 from karl kir
Which version of php you were used?