Joomla 5 Mitteilung

Wir freuen uns mitteilen zu können, dass seit dem 29. Januar 2024 alle unsere Joomla Erweiterungen mit Joomla 5 kompatible sind.

Für alle die gerade noch von Joomla 3 auf 4 aktualisieren: Anleitungen für die Joomla 4 Migration gibt es hier:

Es gibt nun auch eine eigenständige Dokumentation für Visforms für Joomla 4 und für Visforms auf Joomla 5

Forum

Visforms Subscription Inhaber können in unserem Forum Fragen stellen. Bitte mit dem entsprechenden Benutzer anmelden.
Jeder kann lesend auf das Forum zugreifen.

Bitte stellen Sie nur 1 Frage pro Thema.

Wichtig Angaben für fast jede Frage:
V1: Welche Visforms-Version läuft?
V2: Welche Joomla-Version läuft?
V3: Welche PHP-Version läuft?

Aufgrund von Feiertagen und Urlaub ist bei Anfragen im Forum in der Zeit vom 20. Dezember 2024 bis zum 8.Januar 2025 mit verlängerten Antwortzeiten zu rechnen.

SMTP error on submit, but only in Visforms

Mehr
10 Jahre 3 Wochen her - 10 Jahre 3 Wochen her #1062 von carsten
SMTP error on submit, but only in Visforms wurde erstellt von carsten
First I want to give Visforms a big congratulations on making such a great extension. I'm migrating from chronoforms and have tried the 6 top form extension on the JED. This one is by far the best GUI (althou I have some tips to make that even better, I might post those later). If only I could make it send an email :(

On submit I get this error:

Attentie
SMTP fout! Verzenden naar de volgende ontvangers is mislukt: fjvhbfdjsh@zjhfdvsjdh.nl

SMTP serverfout: 5.7.1 : Client host rejected: Access denied

But the Joomla contact form also uses the SMTP settings as set in the Joomla config and sending mail with the normal Joomla contact form works fine. Also another extension send mail with that without problem. I've googled the error and found no solution. I've been pondering this for a few hours, but can't think of a solution.

I have tried with in the Joomla config 'php mail', which gives no error, but email never arrives. And 'sendmail' which on submit just gives a white screen (no code output at all).

Joomla 3.3.6 Visforms 3.1.1

How to solve this SMTP issue?
Letzte Änderung: 10 Jahre 3 Wochen her von carsten.

Mehr
10 Jahre 3 Wochen her #1065 von Administrator AV
Administrator AV antwortete auf SMTP error on submit, but only in Visforms
Hi Casten,

I was out of office yesterday. I will check into this as soon as possible.
If I need further information, I will let you know.

Regards,
Aicha

:idea: I recommend you the new and up-to-date documentation for Joomla 4:
docs.joomla-5.visforms.vi-solutions.de/en/docs/
Most of this also applies retrospectively to Joomla 3.
Please only ask 1 question per topic :-).

:idea: Ich empfehle Dir die neue und aktuelle Dokumentation für Joomla 4:
docs.joomla-5.visforms.vi-solutions.de/docs/
Das meiste gilt rückwirkend auch für Joomla 3.
Bitte immer nur 1 Frage pro Thema stellen :-).

Mehr
10 Jahre 3 Wochen her #1070 von Administrator AV
Administrator AV antwortete auf SMTP error on submit, but only in Visforms
Hi Carsten,

I think I know, what the problem is.
Here a brief explanation.
When I started with Visforms the result mail used the parameters "email from" and "email from name" (from the form configuration) as mail from headers. That was awkward because you could not use the "answer" button of your email client to answer, but you had to copy the email adress form the mail text manually into the reply email.

As an "improvement" I made a change for the next release, which uses now the email address a user enters in the form als mail from header in the email. That allow you now to use the "answer" button in an email client but some mailer, especially SMTP mailer, may require, that the mail from header is consistant with your domain and if not consider the mail as spam. So this one isn't a really good one either

As there are obviously not so many mailer with this feature, the problem does not occure too often and as the error messages of the mailer are often just useless (I found this interessting article on google www.massmailsoftware.com/smtp/554-5-7-1.php ) it was difficutl to figure the problem, but with the help of one Visforms user it was possible some weeks ago. I just then realized, that there is a replyTo header., which I should use.

So in Visform 3.2.0 I changed the code once again. The replyTo header contains the user email and allows you to easily answer a result mail. The mail from headers contain the correct mail from which you set up in your configuration and which should be an email address with your domain in the address.

I do not want to push you to update to Visforms 3.2.0 for this is a beta and I rely on Visforms users to test it before I can savely say, you can use it on a productive system. But you can just make some small changes to the code of your 3.1.1 installation and I think this will (hopefully) solve your problem.

Open the file components/com_visforms/models/visforms.php and find the

private function sendResultMail($visform)

find the following code (it's the last function of the file and this code ist almost at the bottom of the file).
Code:
if ($emailSender == "") { $emailSender = $visform->emailfrom; } $mail->setSender( array( $emailSender, $visform->emailfromname ) );

and replace it with
Code:
$mail->setSender( array( $visform->emailfrom, $visform->emailfromname ) ); if ($emailSender != "") { $mail->addReplyTo($emailSender); }

Regards,
Aicha

:idea: I recommend you the new and up-to-date documentation for Joomla 4:
docs.joomla-5.visforms.vi-solutions.de/en/docs/
Most of this also applies retrospectively to Joomla 3.
Please only ask 1 question per topic :-).

:idea: Ich empfehle Dir die neue und aktuelle Dokumentation für Joomla 4:
docs.joomla-5.visforms.vi-solutions.de/docs/
Das meiste gilt rückwirkend auch für Joomla 3.
Bitte immer nur 1 Frage pro Thema stellen :-).

Mehr
10 Jahre 3 Wochen her #1071 von carsten
Thank you for your time.

unfortunately, that did not solve the issue.

I also tried with changing both the mail_from and mail_to adress to the main adress from the domain itself. Same result.

Mehr
10 Jahre 3 Wochen her #1072 von carsten
I'm sorry to have bothered you with this.

It seems this is not a problem with visforms at all.

I tried this code which works fine on other sites, but not on this one domain. So the problem must be domain-specific.
Code:
$mailer = JFactory::getMailer(); $sender = array('webmaster@domain.com', 'test');//from mail and name $mailer->setSender($sender); $mailer->addRecipient('cljhbkjbne@domain.com'); $body = "Your body string\nin double quotes if you want to parse the \nnewlines etc"; $mailer->setSubject('Your subject string'); $mailer->isHTML(true); $mailer->setBody($body); $send = $mailer->Send(); if ( $send !== true ) { echo 'Error sending email: ' . $send->__toString(); } else { echo 'Mail sent'; }
sample code taken from docs.joomla.org/Sending_email_from_extensions

Still a mystery why the joomla contact form and another extension have no problem sending mail.

Moderatoren: Administrator AVAdministrator IV
Powered by Kunena Forum