Communication Channels

Get Involved. Join the Conversation.


    Mustafa Zubaidi
    Syndicated ConditionalChatLink custom_fields
    Topic posted June 7, 2019 by Mustafa ZubaidiRed Ribbon: 250+ Points, tagged Chat 
    63 Views, 2 Comments
    Syndicated ConditionalChatLink custom_fields
    How can I use the custom_fields that are passed to chat_launch page

    I found a lot of posts about this subject but never found how to use the custom_fields that are passed through the url to the chat_launch page.

    Is it a PHP value that I can pull using $_GET? Or JavaScript?

    Could you please post a code example?

    Thank you!

    CP 3.7, OSvC 19A
    Code Snippet:



    • Ajay Yadav
      i have done it by this code.
              RightNow.Client.Event.evt_widgetLoaded.subscribe(function (eventName, args, scope) {
                  onWidgetLoaded(eventName, args, scope);
              function onWidgetLoaded(eventName, args, scope) {
                  var eo = args[0]; //event object
                  if ( == 'ConditionalChatLink') {
                      var ccl = window[args[0].id];
                      var url = ccl.attrs.chat_login_page;
                      //console.log('orig url: ' + url);
                      //update URL with new params
                      url += '/Incident.Subject/Test 123/Contact.Name.First/John/Contact.Name.Last/Smith/Incident.CustomFields.c.member_id/T12345/p/1/c/2';
                      //p/1 = Default
                      //c/2 = General Question
                      //write new URL back into widget
                      ccl.attrs.chat_login_page = url;
                      //console.log('new url: ' + ccl.attrs.chat_login_page);
      • Mustafa Zubaidi

        Could you please share the documentation that you got this code from? I'm getting some errors and would like to figure it out.