sc ript>
var loctionname;
function getLocation() {
if (navigator.geolocation)
{
navigator.geolocation.getCurrentPosition(function success(position) {
loctionname = "Lat: " + position.coords.latitude + "#Long: " + position.coords.longitude;
// for when getting location is a success
CallOrai();
}, function error(error_message) {
// for when getting location results in an error
loctionname = "";
CallOrai();
}
)};
}
function CallOrai()
{
!function (e, t, a) {
var c = e.head || e.getElementsByTagName("head")[0], n = e.createElement("script"); n.async = !0,
n.defer = !0, n.type = "text/javascript", n.src = t + "/static/js/chat_widget.js?config=" + JSON.stringify(a), c.appendChild(n)
}
(document, "https://xbotic.cbots.live", {
bot_key: "b586a52b29d34d77",
welcome_msg: true, branding_key: "xbotic", server: "https://xbotic.cbots.live",
e: "p", user_attributes: [
{ "name": "Location", "value": loctionname },
{ "name": "URL", "value": window.location.href },
{ "name": "Source", "value": "Web" }
]
});
}
getLocation();