Advertisement
Guest User

Untitled

a guest
Jun 19th, 2019
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <style type='text/css'>
  2.     .embeddedServiceHelpButton .helpButton .uiButton {
  3.         background-color: #005290;
  4.         font-family: "Salesforce Sans", sans-serif;
  5.     }
  6.     .embeddedServiceHelpButton .helpButton .uiButton:focus {
  7.         outline: 1px solid #005290;
  8.     }
  9.     @font-face {
  10.         font-family: 'Salesforce Sans';
  11.         src: url('https://www.sfdcstatic.com/system/shared/common/assets/fonts/SalesforceSans/SalesforceSans-Regular.woff') format('woff'),
  12.         url('https://www.sfdcstatic.com/system/shared/common/assets/fonts/SalesforceSans/SalesforceSans-Regular.ttf') format('truetype');
  13.     }
  14. </style>
  15.  
  16. <script type='text/javascript' src='https://service.force.com/embeddedservice/5.0/esw.min.js'></script>
  17. <script type='text/javascript'>
  18.     var initESW = function(gslbBaseURL) {
  19.         embedded_svc.settings.displayHelpButton = true; //Or false
  20.         embedded_svc.settings.language = ''; //For example, enter 'en' or 'en-US'
  21.  
  22.         //embedded_svc.settings.defaultMinimizedText = '...'; //(Defaults to Chat with an Expert)
  23.         //embedded_svc.settings.disabledMinimizedText = '...'; //(Defaults to Agent Offline)
  24.  
  25.         //embedded_svc.settings.loadingText = ''; //(Defaults to Loading)
  26.         //embedded_svc.settings.storageDomain = 'yourdomain.com'; //(Sets the domain for your deployment so that visitors can navigate subdomains during a chat session)
  27.  
  28.         // Settings for Chat
  29.         //embedded_svc.settings.directToButtonRouting = function(prechatFormData) {
  30.             // Dynamically changes the button ID based on what the visitor enters in the pre-chat form.
  31.             // Returns a valid button ID.
  32.         //};
  33.         //embedded_svc.settings.prepopulatedPrechatFields = {}; //Sets the auto-population of pre-chat form fields
  34.         //embedded_svc.settings.fallbackRouting = []; //An array of button IDs, user IDs, or userId_buttonId
  35.         //embedded_svc.settings.offlineSupportMinimizedText = '...'; //(Defaults to Contact Us)
  36.  
  37.         embedded_svc.settings.enabledFeatures = ['LiveAgent'];
  38.         embedded_svc.settings.entryFeature = 'LiveAgent';
  39.  
  40.         embedded_svc.init(
  41.             'https://carrierenterprise.my.salesforce.com',
  42.             'https://carrierenterprise.secure.force.com',
  43.             gslbBaseURL,
  44.             '00D6A000001V55N',
  45.             'Live_Agent_STX',
  46.             {
  47.                 baseLiveAgentContentURL: 'https://c.la2-c2-ia2.salesforceliveagent.com/content',
  48.                 deploymentId: '5726A0000005Fn3',
  49.                 buttonId: '5736A000000cfmD',
  50.                 baseLiveAgentURL: 'https://d.la2-c2-ia2.salesforceliveagent.com/chat',
  51.                 eswLiveAgentDevName: 'EmbeddedServiceLiveAgent_Parent04I2G000000PAsDUAW_16a66f9097b',
  52.                 isOfflineSupportEnabled: true
  53.             }
  54.         );
  55.     };
  56.  
  57.     if (!window.embedded_svc) {
  58.         var s = document.createElement('script');
  59.         s.setAttribute('src', 'https://carrierenterprise.my.salesforce.com/embeddedservice/5.0/esw.min.js');
  60.         s.onload = function() {
  61.             initESW(null);
  62.         };
  63.         document.body.appendChild(s);
  64.     } else {
  65.         initESW('https://service.force.com');
  66.     }
  67. </script>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement