• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: Can't redeclare class phpmailerException on submit

Can't redeclare class phpmailerException on submit 10 years 4 months ago #29709

  • rsforms5
  • rsforms5's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
When I press submit on my RSForm (rsform pro 1.5.6) in Joomla 3.3.6, I get the following exception:

Fatal error: Cannot redeclare class phpmailerException in /home/path_to_site/public_html/libraries/phpmailer/phpmailer.php on line 2951

I've managed to deduce that most likely RSform Pro and either Joomla or some plugin is trying to load the phpmailer class twice, but am stumped as to how to fix this. Any ideas?
The administrator has disabled public write access.

Can't redeclare class phpmailerException on submit 10 years 4 months ago #29710

  • octavian
  • octavian's Avatar
  • OFFLINE
  • RSJoomla! Official Staff
  • Posts: 783
  • Thank you received: 110
Looking at the Joomla! source code, line 2951 isn't related to 'phpmailerException'.
You can try creating a new Joomla! user (Users > User Manager > Add New User) - an email will be automatically sent to the newly created user's email address. See if the same error occurs.
Please note: my help is not official customer support. To receive your support, submit a ticket by clicking here
Regards,
RSJoomla! Development Team
The administrator has disabled public write access.

Can't redeclare class phpmailerException on submit 10 years 4 months ago #29711

  • rsforms5
  • rsforms5's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
In my copy of 3.3.6 (both the site one, and a fresh download) the line number does match up, this is lines 2938-2951:

/**
 * Exception handler for PHPMailer
 * @package PHPMailer
 */
class phpmailerException extends Exception {
  /**
   * Prettify error message output
   * @return string
   */
  public function errorMessage() {
    $errorMsg = '<strong>' . $this->getMessage() . "</strong><br />\n";
    return $errorMsg;
  }
}

edit: I've traced the way RSform Pro handles email (essentially importing the class through jimport in the end, which does include_once) and so it seems unlikely that it is the culprit. Still have to find the plugin/module that does the non-standard phpmailer load though.
Last Edit: 10 years 4 months ago by rsforms5.
The administrator has disabled public write access.

Can't redeclare class phpmailerException on submit 10 years 4 months ago #29712

  • octavian
  • octavian's Avatar
  • OFFLINE
  • RSJoomla! Official Staff
  • Posts: 783
  • Thank you received: 110
You didn't answer if the same error happens when you create a new Joomla! user.
Please note: my help is not official customer support. To receive your support, submit a ticket by clicking here
Regards,
RSJoomla! Development Team
The administrator has disabled public write access.

Can't redeclare class phpmailerException on submit 10 years 4 months ago #29713

  • rsforms5
  • rsforms5's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
Apologies :) No, the error doesn't happen when creating a new user and the mail gets sent normally.

Could be relevant: this is a site which has recently been upgraded from Joomla 2.5 tot 3.3, and RSform Pro from rev46 (I think) tot 1.5.6
Last Edit: 10 years 4 months ago by rsforms5.
The administrator has disabled public write access.

Can't redeclare class phpmailerException on submit 10 years 4 months ago #29714

  • octavian
  • octavian's Avatar
  • OFFLINE
  • RSJoomla! Official Staff
  • Posts: 783
  • Thank you received: 110
Ok, so it sounds like your Joomla! installation is running fine. We'd love to help if you'd submit a ticket with access (a Joomla! Administrator account) to your website.
Please note: my help is not official customer support. To receive your support, submit a ticket by clicking here
Regards,
RSJoomla! Development Team
The administrator has disabled public write access.

Can't redeclare class phpmailerException on submit 10 years 4 months ago #29715

  • rsforms5
  • rsforms5's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
Ticket submitted.
The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!