Tagged: , ,

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #533769

    Hi!

    I got a custom subject line based on the entry in the form.

    See post here
    https://kriesi.at/support/topic/form-email-subject-line/

    After the latest update 3.4 it doesn’t work anymore ?

    I get the custom subject line but it doesn’t add the entry into it.

    Code i used is as follow

    add_filter('avf_form_subject','avia_change_mail_subject', 10, 3);
    function avia_change_mail_subject($subject, $new_post, $form_params)
    {
    $subject = "Table reservation request from " . urldecode($new_post['namn_'.(avia_form::$form_id - 1)]);
    return $subject;
    }

    Thanx!

    #535978

    Hi Paul,,

    Can you please hand me a WordPress administrator account or a FTP account? post it here as a private reply.

    Regards,
    Josue

    #536242

    Ok Thanx!

    #536362

    Hey!

    Thanks for the access, can you indicate where’s the form in question?

    Cheers!
    Josue

    #536366

    Hi thank you!

    There are multiple forms (pretty much identical, apart from to which adress it goes) one on each page (restaurant)

    the top right “valj restaurang” drop down menu you can find all the pages that contains a form.

    It did work perfectly before the latest update, so i don’t think multiple form is the issue ?

    Thanx!

    #538658

    Hi!

    Form field names are now numeric based so the code should be updated to something like this:

    add_filter('avf_form_subject','avia_change_mail_subject', 10, 3);
    function avia_change_mail_subject($subject, $new_post, $form_params)
    {
    $subject = "Table reservation request from " . urldecode($new_post['avia_1_1']);
    return $subject;
    }

    Assuming name will always be the first element in the form.

    Best regards,
    Josue

    #539119

    Thanx!

    I copied that and replaced the old code, but still no difference ? Should i add something to the above code ?

    Thanx!

    #539412

    Should work now, check it.

    Regards,
    Josue

    #540022

    Thank it works now, was there something i missed ? (i have more then one site that needs this code added)

    #540025

    The code that did the trick was the following:

    add_filter('avf_form_subject','avia_change_mail_subject', 10, 3);
    function avia_change_mail_subject($subject, $new_post, $form_params)
    {
    $subject = "Table reservation request from " . urldecode($new_post['1_1']);
    return $subject;
    }

    Cheers!
    Josue

Viewing 10 posts - 1 through 10 (of 10 total)
  • You must be logged in to reply to this topic.