Facebook Pixel Dynamic Value based on Selected Menu

Home Forums Quform WordPress Facebook Pixel Dynamic Value based on Selected Menu

This topic is: resolved
Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #31593
    AudiojungleDaniel
    Participant

    Hi, thank you for a great Form! I just love Quform for WordPress!
    With no code-skills Im trying to ad a correct value in my Facebook Pixel.

    I used the JavaScript below in the in the Custom JavaScript Section and it works great!

    But I need to set up a Dynamic Value based on the Amount that is selected in the dropdown menu in the form. The Dropdown has a Unique Identifier. In this case it is: 27_26.

    Can you help me with a fill out the the script correctly for a Dynamic Value based on the selected value in the unique dropdown menu. 
    For example, If a visitor fill out the form and selects the value 3 in the dropdown and Submit I like to see the value 3×79 in my Facebook ads purchase value. 
    Possible?

    jQuery(function ($) {
        $(‘.quform-form-27’).on(‘quform:successStart’, function () {
            if (window.fbq) {
                fbq(‘track’, ‘Purchase’, {value: 79.00, currency: ‘SEK’});
            }
        });
    });

    Attachments:
    You must be logged in to view attached files.
    #31599
    Ally
    Support Staff

    You don't have permission to view this content. Please log in or register and then verify your purchases to gain access.

    #31600
    AudiojungleDaniel
    Participant

    Hi Ally, looks good but it didn’t work. It still shows up a value of 79 in my Facebook Pixel Helper no matter what I select in the dropdown.

    Should I add something else or was it meant to just copy paste it in to the Custom JavaScript Section?

    I was hoping for if I select 3 bottles in the dropdown it would end up as 3×79=237 SEK

    Check for your self here:

    Barone Montalto Pinot Grigio Brut

    Attachments:
    You must be logged in to view attached files.
    #31605
    Ally
    Support Staff

    You don't have permission to view this content. Please log in or register and then verify your purchases to gain access.

    #32223
    AudiojungleDaniel
    Participant

    Hi, I have 12 licens of Quform and I love it. Is there any way to see a overview what site Im using my different licens on? Like a Dashboard or My pages?

    #32226
    Ally
    Support Staff

    You don't have permission to view this content. Please log in or register and then verify your purchases to gain access.

    #32527
    AudiojungleDaniel
    Participant

    Hi, and thanks for your help the problem with the Facebook pixel and the Dynamic Value based on the Amount that is selected in the dropdown menu in the form.

    Im trying to get the same result on my new site with this landing-page with no luck.

    Black Bush

    Same problem here as above. The price for the bottle is 369 Kr. And if I add 2 bottles it should end up with
    369 Kr x 2. But it ends up with only as one bottle. I use the code below in the java Scrips field.

    The Dropdown has a Unique Identifier. In this case it is: 18_38.

    jQuery(function ($) {
    $(‘.quform-form-18’).on(‘quform:successStart’, function () {
    if (window.fbq) {
    var value = 369.00,
    selectValue = $(‘.quform-field-18_38’).val();

    if(selectValue && $.isNumeric(selectValue)) {
    value = value * parseInt(selectValue, 10);
    }

    fbq(‘track’, ‘Purchase’, {value: value, currency: ‘SEK’});
    }
    });
    });

    Attachments:
    You must be logged in to view attached files.
    #32531
    Ally
    Support Staff

    You don't have permission to view this content. Please log in or register and then verify your purchases to gain access.

    • This reply was modified 5 months, 2 weeks ago by Ally.
Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.
Be inspired. © 2020 ThemeCatcher Ltd. 20-22 Wenlock Road, London, England, N1 7GU | Company No. 08120384 | Built with React | Privacy Policy