• Resolved ctrue321

    (@ctrue321)


    I’m curious if there’s a way to have a form post data in a serialized thread to another site, as well as still post the data to Salesforce (aside from doing some dirty hacking).

    Situation:
    We use a form submit to auto-create a trial of a product on our site, that is handled on another site. Currently we use ajax to post serialized data to another URL and at the same time populate a hidden Pardot iframe to add the lead to our system.

    We are moving all forms to Salesforce Web-to-Lead forms on our WordPress sites and this one is turning into a head scratcher for our web team. Anything helps. Thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Nick Ciske

    (@nickciske)

    salesforce_w2l_after_submit

    Allows you to do something (read only) with the post data after it’s submitted to SalesForce.

    e.g. Send it to another API, log it to a database, etc.

    add_action('salesforce_w2l_after_submit', 'salesforce_w2l_after_submit_example', 10, 3 );
    
    function salesforce_w2l_after_submit_example( $post, $form_id, $form_type ){
        error_log( 'AFTER SUBMIT '.print_r($post,1) );
    }

    Source:
    https://www.ads-software.com/plugins/salesforce-wordpress-to-lead/other_notes/

    • This reply was modified 7 years, 11 months ago by Nick Ciske.
    Thread Starter ctrue321

    (@ctrue321)

    Thanks Nick, looks promising. Are there any other examples of this specific approach available anywhere? Just determining if I need to involve another developer or not.

    Thread Starter ctrue321

    (@ctrue321)

    Specifically, we’re just wanting to post the data to another URL after Salesforce, but not able to figure out exactly how to do it. My web dev was asking me what the “10, 3” were relating to and I couldn’t find any specifics.

    Plugin Author Nick Ciske

    (@nickciske)

    Your web dev has never used a hook before?

    https://developer.www.ads-software.com/reference/functions/add_action/

    10 = priority
    3 = number of arguments to pass to the custom function

    I gave you the all the code I can. I don’t know what your external API looks like so I can’t give you more than that.

    You have the POST variables as an array –all your dev needs to do is send that data to the API in the format it expects.

    If you want, I can write the hook for you, but that would fall under premium support.

    https://luminfire.com/support/premium-plugin-support/

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Webhook or multiple post actions from Web2Lead form?’ is closed to new replies.