• Resolved bristolking

    (@bristolking)


    For the tracking of the registered member, we used this datalayer trigger and it should trigger after successful 
    registration so we have written in ‘um_registration_complete’ hook, but its not working however php code is working properly

    add_action( ‘um_registration_complete’, ‘my_registration_complete’, 10, 2 );
    function my_registration_complete( $user_id, $args ) {
        echo “<script type=\”text/javascript\”> 
                window.dataLayer = window.dataLayer || [];
                window.dataLayer.push({
                    ‘event’: ‘sign_up’,
                    ‘status’: ‘success’,
                });
    </script>”;
    }

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Mykyta Synelnikov

    (@nsinelnikov)

    Hi @bristolking

    It looks that you want to make a scripts echo before the headers loading and redirect. We use internally this hook for successful registration redirect. (100 priority).

    I guess you need to review the logic when you try to echo this script. Try the page loading hooks after redirect from registration.

    Best Regards!

    Plugin Support andrewshu

    (@andrewshu)

    Hi @bristolking

    This thread has been inactive for a while so we’re going to go ahead and mark it Resolved.

    Please feel free to re-open this thread if any other questions come up and we’d be happy to help. ??

    Regards

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Web Hook Not working’ is closed to new replies.