var style = document.createElement('style'); document.getElementsByTagName('head')[0].appendChild(style); if (!window.createPopup) { style.appendChild(document.createTextNode('')); style.setAttribute("type", "text/css"); } var sheet = document.styleSheets[document.styleSheets.length - 1]; if (!window.createPopup) { var node = document.createTextNode(mibewInviteStyle); style.appendChild(node); } else { sheet.cssText = mibewInviteStyle; } function mibewInviteOnResponse(response) { var message = response.invitation.message; var operator = response.invitation.operator; var avatar = response.invitation.avatar; var popuptext = '
'; popuptext += '
×
'; if (operator) { popuptext += '

' + operator + '

'; } if (avatar) { popuptext += '' + operator + ''; } popuptext += '

' + message + '

'; popuptext += '
'; var invitationdiv = document.getElementById("mibewinvitation"); if (invitationdiv) { invitationdiv.innerHTML = popuptext; } } function mibewHideInvitation() { if (document.getElementById('mibewinvitationpopup')) { document.getElementById('mibewinvitationpopup').style.display='none'; } } function mibewOpenAgent() { if (document.getElementById('mibewAgentButton')) { document.getElementById('mibewAgentButton').onclick(); mibewHideInvitation(); } }