Follow

Display User Name on Booking Link confirmation page

Display User Name on Booking Link confirmation page

Depending on how you schedule appointments for you and your team, you may like to display the name of the User that had the appointment scheduled on the confirmation page when a prospect books with you. To do this, paste this script into the Booking Link header:

 

<div id="custom_header_div"></div>
<script>
$(document).on('eventScheduled', function(event, createdEvents, attendees){
    $.each(attendees, function(idx, attendee){
        if ((attendee.type || '') == 'user') {
            // this is how email can be found
            var email = '', seq = -1;
            $.each(attendee.methods, function(i, m){
                if (m.type == 'email' && m.seq > seq) {
                    email = m.v;
                    seq = m.seq;
                }
            });
            // show message
            $('#appt_time_info').after("<div class='clearfix'></div><div class='left no-control'>Coach:</div><div class='right no-control'>" + attendee.fname + " " + attendee.lname + "</div>");
            return false;
        }
    });
});
</script>

 

 

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments

Powered by Zendesk