Reply To: thenewsletter plugin and quform2 :-)

Home Forums Quform WordPress thenewsletter plugin and quform2 :-) Reply To: thenewsletter plugin and quform2 :-)

#36094
deranaloge
Participant

hm now i tried something myself:

add_filter(‘quform_post_process_2’, function($result, $form) {
if (class_exists(‘TNP_Subscription’)) {
$email = $form->getValue(‘quform_2_4’);
if (!empty($email)) {
$name = $form->getValue(‘quform_2_3’);
$subscription = new TNP_Subscription();
$subscription->email = $email;
$subscription->first_name = $name[2];
$subscription->last_name = $name[4];
$subscription->lists = array(1);
$subscription->send_welcome = true; // Setzen Sie dies auf true, um die Willkommens-E-Mail zu senden

TNP::subscribe2($subscription);
}
}

return $result;
}, 10, 2);

but i got an ajax error now…

Be inspired. © 2024 ThemeCatcher Ltd. 20-22 Wenlock Road, London, England, N1 7GU | Company No. 08120384 | Built with React | Privacy Policy