Categories

Featured templates

Joomla 3.x Troubleshooter. “TM Ajax Contact Form” module stopped working after engine update to Joomla 3.5.x version

Rating: 5.0. From 3 votes.
Please wait...

This tutorial shows how to get rid of the phpmailerException: Invalid address error after engine update to Joomla 3.5.x version.

Joomla 3.x Troubleshooter. TM Ajax Contact Form module stopped working after engine update to1
  1. Please, open modules/mod_tm_ajax_contact_form/helper.php file in your editor.

    Joomla 3.x Troubleshooter. TM Ajax Contact Form module stopped working after engine update to2
  2. There are two versions of code structure in helper.php file.

    Example 1. Replace the following code:

    if(isset($_POST['email']))
    $sender = array($email, $name);
    else
    $sender = $name;
    $mail->setSender($sender);
    $mail->addRecipient($recipient);
    if(isset($cc_email))
    $mail->addCC($cc_email);
    if(isset($bcc_email))
    $mail->addBCC($bcc_email);
    $mail->setSubject($subject);
    $mail->isHTML(true);
    $mail->Encoding = 'base64';
    $mail->setBody($formcontent);

    With the following:

    if(isset($email)){
    $mail->setSender($email, $name);	
    }
    else{
    $mail->setSender($name);
    }	
    $mail->addRecipient($recipient);
    if(isset($cc_email) && $cc_email>0){
    $mail->addCC($cc_email);
    }
    if(isset($bcc_email) && $bcc_email>0)
    $mail->addBCC($bcc_email);
    }
    $mail->setSubject($subject);
    $mail->isHTML(true);
    $mail->Encoding = 'base64';
    $mail->setBody($formcontent);

    Example 2. Replace the following code:

    if(isset($cc_email)) $mail->addCC($cc_email);
    if(isset($bcc_email)) $mail->addBCC($bcc_email);
    if(isset($subject)) $mail->setSubject($subject);

    With the following:

    if(isset($cc_email) && $cc_email>0){
    $mail->addCC($cc_email);
    }
    if(isset($bcc_email) && $bcc_email>0){
    $mail->addBCC($bcc_email);
    }
    if(isset($subject)){
    $mail->setSubject($subject);			}
  3. Save changes and re-upload an updated file. Refresh the page and submit contact form. It works fine now.

    Joomla 3.x Troubleshooter. TM Ajax Contact Form module stopped working after engine update to3

Feel free to check the detailed video tutorial below:

Joomla 3.x Troubleshooter. “TM Ajax Contact Form” module stopped working after engine update to Joomla 3.5.x version
Latest Joomla templates
This entry was posted in Joomla! Tutorials and tagged contact form, error, joomla, tm ajax contact form, troubleshooter. Bookmark the permalink.

Submit a ticket

If you are still unable to find a sufficient tutorial regarding your issue please use the following link to submit a request to our technical support team. We'll provide you with our help and assistance within next 24 hours: Submit a ticket

Live Chat
We help you to choose the right product.