var agent = navigator.userAgent.toLowerCase();
var browser;
if (agent.indexOf('msie') > -1) {
	browser = 'ie' + agent.match(/msie (\d+)/)[1]
}else if(agent.indexOf('trident') > -1) {
	browser = 'ie11'
}else if(agent.indexOf('edge') > -1) {
	browser = 'edge'
}else if(agent.indexOf('firefox') > -1) {
	browser = 'firefox'
}else if(agent.indexOf('opr') > -1) {
	browser = 'opera'
}else if(agent.indexOf('chrome') > -1) {
	browser = 'chrome'
}else if(agent.indexOf('safari') > -1) {
	browser = 'safari'
}