// livechat by www.mylivechat.com/ 2018-06-12 // first loading if (typeof (MyLiveChat) == "undefined") { MyLiveChat = {}; MyLiveChat.RawConfig ={InlineChatShowMailButton:"1",InPageBubbleTop:"1",InlineChatRoundOfflineUrl:"",WebConsoleRedirectTime:"638889058282088636",SupportMessage:"Please wait while we route your call to the next available agent who will help you with your question: {0}.",SmartUseEntryUrlFilter:"1",UIMobileMode:"Inline",InlineChatWaitingMessage:"Thank you for contacting us. To serve you better please provide the following information:",CustomDataDefinition:"[]",SmartPageCount:"5",WaitingFieldEmail:"1",SmartRejectTooltip:"Close",UIPopupMode:"Modern",InlineChatRoundPadding:"8",SmartMessage:"May I help you?",WidgetFixedMode:"",InlineChatRoundOfflineGray:"N",SmartReferUrlFilter:"",InvitePhoto:"upload",DialogHeight:"420",InviteHeadline:"Chat Invitation",SmartAcceptTooltip:"Chat Invitation",iosnotifylist:"",SmartMaxReject:"2",InlineChatSelectAgentUI:"",SmartUseShowTimeout:"1",InPageInputBoxLayout:"left",LinkOnlineCode:"www",InlineChatBubbleUIMode:"3",InlineChatSurveyUseEmail:"1",WidgetOpenNewWindow:"False",SmartSoundFile:"1",WaitingShowForClick:"1",SmartUseMaxIgnore:"1",SmartVisitUrlFilter:"",InlineChatShowEmotionButton:"1",UITopBarFGColor:"",InlineChatOfflineLogo:"a1",SmartPlaySound:"1",SmartMaxIgnore:"5",InPageTemplate:"5",HasPriorityList:"1",InlineChatSurveyVisible:"1",WaitingTitle:"Live Chat",BoxOnlinePhoto:"1",WidgetOnlineImage:"1",SmartEntryUrlFilter:"",WaitingDepartmentMode:"",InlineChatSurveyMessage:"To help us serve you better, please provide some information concerning your chat experience.",InlineChatOfflineMessage:"There are no agents available right now to take your call. Please leave a message and we will get back to you soon.",PrivateHeaderHTML:"",InlineChatShowSaveButton:"1",OperatingHoursCheckDay3:"0",SmartUsePageTime:"1",InlineChatSelectAgentOnlineOnly:"",RoutingNoWait:"",SmartKeywordsFilter:"",InlineChatOfflineHeadline:"Leave a message",RequiredStarShowTextBox:"0",InviteAcceptTooltip:"Chat Invitation",InlineChatRoundFontSize:"18px",InlineChatShowUploadButton:"1",InviteRejectTooltip:"Close",InPageImageOffline:"1",PrivatePoweredByHTML:"",InPageImageOnline:"1",InlineTriggers:"[{\x22name\x22:\x22test\x22,\x22desc\x22:\x22\x22,\x22disabled\x22:false,\x22nosound\x22:false,\x22matchnum\x22:0,\x22filters\x22:[{\x22name\x22:\x22waittime\x22,\x22op\x22:\x22\x3E\x22,\x22values\x22:[\x2210\x22]}],\x22actions\x22:[{\x22type\x22:\x22invite\x22,\x22value\x22:\x22\x22}]},{\x22name\x22:\x22trig2\x22,\x22desc\x22:\x22\x22,\x22disabled\x22:false,\x22nosound\x22:false,\x22matchnum\x22:0,\x22filters\x22:[{\x22name\x22:\x22ref\x22,\x22op\x22:\x22eq\x22,\x22values\x22:[\x22Equals\x22]},{\x22name\x22:\x22url\x22,\x22op\x22:\x22like\x22,\x22values\x22:[\x22Contains\x22]},{\x22name\x22:\x22url\x22,\x22op\x22:\x22like\x22,\x22values\x22:[\x22Contains\x22]}],\x22actions\x22:[{\x22type\x22:\x22department\x22,\x22value\x22:\x222\x22}]}]",SmartHeadline:"Chat Invitation",PrivateIconUrl:"",InlineChatWaitingToFeedback:"0",InlineChatOnlineLogo:"a1",WaitingFieldDepartment:"1",InlineChatRoundBackColor:"#007bff",WaitingShowForInvite:"1",maxWaitTime:"300",InlineTriggerCIPA:"20",WidgetHideInline:"",SmartStayTime:"120",InlineChatShowSoundButton:"1",InlineChatWaitingFieldEmail:"1",InlineChatWaitingFieldDepartment:"1",WidgetHideWidget:"",SmartUseKeywordsFilter:"1",InlineChatWaitingHeadline:"Live Chat",SmartShowTimeout:"60",InlineChatRoundMargin:"12",OperatingHoursCheckDay6:"0",DialogWidth:"580",OperatingHoursCheckDay4:"0",OperatingHoursCheckDay5:"0",OperatingHoursCheckDay2:"0",InPageUseBubbleTopOnlineOnly:"0",OperatingHoursCheckDay0:"0",OperatingHoursCheckDay1:"0",InviteHideTimeout:"1800",InlineChatWaitingShowForClick:"1",UITopBarBGColor:"",WaitingFieldQuestion:"1",InlineChatHideSubject:"1",InlineChatWaitingFieldQuestion:"1",LinkOnlineTooltip:"www",SupportTitle:"Live Chat",OperatingHoursCheckWeekend:"0",SmartUseStayTime:"1",SmartUseMaxReject:"1",InPageUseBubbleTop:"0",InlineChatSurveyUseComment:"1",WaitingHeadline:"Live Chat",BoxMessage:"Type your question here and click below...",InviteMessage:"Hello, my name is (AGENT). How can I help you today?",InlineChatTimestampVisible:"1",BoxOnlineCode:"Online",InlineChatOnholdWaitTime:"120",InviteTemplate:"3",OperatingHoursSchedule:"0",InlineChatRoundOnline:"12",InlineTriggerDefinition:"[]",SupportPhoto:"9",SmartHideIfChatting:"1",LocalDataDisabled:"1",RequiredStarShowLabel:"0",InlineChatSelectAgentByDept:"",SupportHeadline:"Live Chat",InlineChatSurveyUseRating:"1",SmartUsePageCount:"1",WaitingShowForSmart:"1",BoxTemplate:"2",InvitePlaySound:"1",UICollapsedBarMode:"",LinkOfflineCode:"wwww",UIDisableBarAnimation:"0",LinkOfflineTooltip:"ww",ButtonOpenNewWindow:"False",InPageTemplateMobile:"10",SmartUseHideTimeout:"1",InlineChatSurveyHeadline:"Live Chat Exit Survey",SmartHideTimeout:"10",MessageTimestampVisible:"1",SmartPageTime:"15",StyleCode:"",InlineChatRoundRadius:"99",SmartUseVisitUrlFilter:"1",OperatingHoursCheckWeekday:"0",WaitingMessage:"Thank you for contacting us. To serve you better please provide the following information:",RequiredStarShowPlaceHolder:"0",InviteShowTimeout:"60",InlineChatRoundSpace:"6",DialogChatBackgroundStyle:"",InlineChatRoundOffline:"18",CustomDataMode:"auto",InlineChatRoundSize:"32",InlineChatShowRatingButton:"1",MobileDisabled:"1",BoxOfflinePhoto:"1",SmartUseReferUrlFilter:"1",InlineChatRoundOnlineUrl:"",InlineChatmaxWaitTime:"300",BoxOfflineCode:"Leave a message",InviteSoundFile:"1",UIDialogMode:"Classic",UIDisableFormImage:"0"}; MyLiveChat.RawQuery ={hccid:"68268000",apimode:"chatlink"}; for (var mlcp in MyLiveChat.RawConfig) { MyLiveChat[mlcp] = MyLiveChat.RawConfig[mlcp]; } for (var mlcp in MyLiveChat.RawQuery) { MyLiveChat[mlcp] = MyLiveChat.RawQuery[mlcp]; } MyLiveChat.HCCID ='68268000'; MyLiveChat.PageBeginTime = new Date().getTime(); MyLiveChat.LoadingHandlers = []; // ,"Departments" MyLiveChat.CPRFIELDS = ["SyncType", "SyncStatus", "SyncResult", "HasReadyAgents", "VisitorUrls", "VisitorStatus", "VisitorDuration", "VisitorEntryUrl", "VisitorReferUrl"]; MyLiveChat.DefaultFont = "Poppins"; (function () { function loadfont(font) { var fonturl = "https://fonts.googleapis.com/css?family=" + encodeURIComponent(font) + ":300,400,500,600,700"; var div = document.createElement('div'); div.style.cssText = "position:fixed;left:-1000px;"; div.style.fontFamily = '"' + font + '"'; div.innerText = "a"; try { document.body.appendChild(div); } catch (x) { var head = document.getElementsByTagName("head")[0] try { head.appendChild(div); } catch (x) { head.insertBefore(div, head.firstChild); } } var link = MyLiveChat_ImportCss(fonturl); link.onload = function () { setTimeout(function () { document.body.removeChild(div); }, 100) } } var fonts = ["Poppins"]; try { for (var p in MyLiveChat.RawConfig) { var fontval; if (/Font$/.test(p)) { fontval = MyLiveChat.RawConfig[p]; } if (/TextStyle$/.test(p)) { var ts = MyLiveChat.RawConfig[p]; if (ts) { //ts = "test:123;" + ts + ";another:222"; var ms = /font-family:([^;]+)/.exec(ts); if (ms) fontval = ms[1]; } } if (!fontval || fonts.indexOf(fontval) != -1) continue; //console.log(fontval) switch (fontval) { case "Poppins": case "Open Sans": case "Noto Sans": case "Lato": case "Lora": case "Roboto": case "proxima-nova": fonts.push(fontval); break; } } } catch (x) { console.error(x); } for (var i = 0; i < fonts.length; i++) { loadfont(fonts[i]) } })(); } else { MyLiveChat.MultiLinked = true; } MyLiveChat.Version =3017; MyLiveChat.FirstRequestTimeout =21600; MyLiveChat.NextRequestTimeout =43200; MyLiveChat.SyncType =null; MyLiveChat.SyncStatus ="LOADING"; MyLiveChat.SyncUserName =null; MyLiveChat.SyncResult ="LOADING"; MyLiveChat.HasReadyAgents =false; MyLiveChat.SourceUrl =""; MyLiveChat.AgentTimeZone = parseInt("-4" || "-5"); MyLiveChat.VisitorStatus =""; MyLiveChat.UrlBase ="https://a2.mylivechat.com/livechat2/"; MyLiveChat.SiteUrl ="https://a2.mylivechat.com/"; if (!MyLiveChat.AgentId) MyLiveChat.AgentId = MyLiveChat.RawAgentId; MyLiveChat.Departments = []; MyLiveChat.Departments.push({ Name:"Support", Agents: [{ Id:'User:1', Name:"admin", Online:false },{ Id:'User:2', Name:"Kenneth", Online:false },{ Id:'User:5', Name:"Karen", Online:false },{ Id:'User:4', Name:"Jeff", Online:false },{ Id:'User:7', Name:"Adam", Online:false },{ Id:'User:9', Name:"TEST", Online:false },{ Id:'User:10', Name:"Rhonda", Online:false },{ Id:'User:3', Name:"Terry", Online:false }], Online:false }); MyLiveChat.Departments.push({ Name:"Sales", Agents: [{ Id:'User:1', Name:"admin", Online:false },{ Id:'User:2', Name:"Kenneth", Online:false },{ Id:'User:3', Name:"Terry", Online:false },{ Id:'User:9', Name:"TEST", Online:false },{ Id:'User:10', Name:"Rhonda", Online:false },{ Id:'User:7', Name:"Adam", Online:false },{ Id:'User:5', Name:"Karen", Online:false }], Online:false }); MyLiveChat.VisitorUrls = []; var mlciptscr = 'rbqhos'.replace(/./g, function (v) { return String.fromCharCode(v.charCodeAt(0) + 1) }); function MyLiveChat_AddScript(tag) { var func = MyLiveChat_AddScript; var arr = func._list; if (!arr) func._list = arr = []; if (func._loading) { arr.push(tag); return; } function ontagload() { func._loading = false; if (!arr.length) return; tag = arr.shift(); LoadTag(); } function LoadTag() { func._loading = true; if ('onload' in tag) { tag.onload = ontagload; } else { var iid = setInterval(function () { if (tag.readyState != 'complete' && tag.readyState != 'loaded') return; clearInterval(iid); ontagload(); }, 10); } var p = document.getElementsByTagName("head")[0] || document.body; p.insertBefore(tag, p.firstChild); } LoadTag(); } function MyLiveChat_GetLastScriptTag() { var coll = document.getElementsByTagName(mlciptscr); return coll[coll.length - 1]; } function MyLiveChat_ImportCss(url, tagid) { var p = document.head || document.getElementsByTagName("head")[0] || document.body; var tag = document.createElement("link"); if (tagid) tag.setAttribute("id", tagid); tag.setAttribute("rel", "stylesheet"); tag.setAttribute("href", url); p.insertBefore(tag, p.firstChild); return tag; } function MyLiveChat_DocWriteScr(src) { if (!MyLiveChat.LoadedScripts) MyLiveChat.LoadedScripts = {}; if (MyLiveChat.LoadedScripts[src]) return; MyLiveChat.LoadedScripts[src] = true; var tag = document.createElement(mlciptscr); tag.setAttribute("src", src); MyLiveChat_AddScript(tag); } function MyLiveChat_DocWrite(html, relativetag) { if (html.substr(1, 6) == mlciptscr) //Low IE interactive or defer { MyLiveChat_DocWriteScr(html.match(/src=["']?([^"'>]*)["']/)[1]); return; } if (!document.body || document.readyState == "loading") { var _ = document; _.write(html); return; } if (!relativetag) relativetag = MyLiveChat_GetLastScriptTag(); var div = document.createElement("DIV"); div.innerHTML = html; while (true) { var c = div.firstChild; if (!c) break; div.removeChild(c); relativetag.parentNode.insertBefore(c, relativetag); } } MyLiveChat.RandomID = 'd6b419e6-81fa-a400-4c15-5ac903f8dd08'; MyLiveChat.NewGuid = function () { var guid = ""; for (var i = 1; i <= 32; i++) { guid += Math.floor(Math.random() * 16.0).toString(16); if (i == 8 || i == 12 || i == 16 || i == 20) guid += "-"; } return guid; } MyLiveChat.RandomID = MyLiveChat.NewGuid().substring(0, 18) + MyLiveChat.RandomID.substring(18); MyLiveChat.VisitorDuration = 0; MyLiveChat.VisitorEntryUrl = ""; MyLiveChat.VisitorReferUrl = ""; MyLiveChat.ShowButton =true; MyLiveChat.ShowLink =true; MyLiveChat.ShowBox =true; MyLiveChat.ShowSmart =false; MyLiveChat.NoPrivateLabel =false; MyLiveChat.LoadingHandlers.push(function (funcself) { MyLiveChat_RunLoadingHandler('chatlink', funcself); }); MyLiveChat.ResourcesVary ="\x26culture=zh-CN\x26mlcv=3017\x26template=5"; MyLiveChat['chatlink' + "_script_tag"] = MyLiveChat_GetLastScriptTag(); if (typeof (MyLiveChat_Initialize) != "undefined") { MyLiveChat_Initialize() } else if (!MyLiveChat.MultiLinked) { MyLiveChat_ImportCss(MyLiveChat.UrlBase + "chatinline.css?" + MyLiveChat.ResourcesVary, "mlc_chatinlie_styletag"); MyLiveChat_DocWriteScr(MyLiveChat.UrlBase + "resources2.aspx?HCCID=" + MyLiveChat.HCCID + MyLiveChat.ResourcesVary); MyLiveChat_DocWriteScr(MyLiveChat.UrlBase + "script/livechatinit2.js"); }