Craig Paulsen
asked on
Set Website link to open in chrome
My client about to roll out a new cloud based Event Reporting system.
Unfortunately due to compatibility issues they are unable to access this via Internet Explorer, which is there default browser. Instead, users will be required to use either Chrome, Firefox or Edge.
We would like to investigate the below option of formatting a link in IE so that it opens up a Chrome browser. This would enable users to continue using our default browser whilst still being able to access this new system.
Any advise on how achive this?
https://social.msdn.microsoft.com/Forums/office/en-US/295f6ba0-82c8-4350-bb55-50ffed40530b/how-to-format-a-link-to-open-in-chrome-instead-of-ie?forum=sharepointdevelopmentprevious
Unfortunately due to compatibility issues they are unable to access this via Internet Explorer, which is there default browser. Instead, users will be required to use either Chrome, Firefox or Edge.
We would like to investigate the below option of formatting a link in IE so that it opens up a Chrome browser. This would enable users to continue using our default browser whilst still being able to access this new system.
Any advise on how achive this?
https://social.msdn.microsoft.com/Forums/office/en-US/295f6ba0-82c8-4350-bb55-50ffed40530b/how-to-format-a-link-to-open-in-chrome-instead-of-ie?forum=sharepointdevelopmentprevious
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Here is a JS script that you can use to detect IE. Instead of displaying information, you can either redirect to fill the screen with a message that IE is not supported, perhaps via a modal.
https://codepen.io/gapcode/pen/vEJNZN
https://codepen.io/gapcode/pen/vEJNZN
// Get IE or Edge browser version
var version = detectIE();
if (version === false) {
document.getElementById('result').innerHTML = '<s>IE/Edge</s>';
} else if (version >= 12) {
document.getElementById('result').innerHTML = 'Edge ' + version;
} else {
document.getElementById('result').innerHTML = 'IE ' + version;
}
// add details to debug result
document.getElementById('details').innerHTML = window.navigator.userAgent;
/**
* detect IE
* returns version of IE or false, if browser is not Internet Explorer
*/
function detectIE() {
var ua = window.navigator.userAgent;
// Test values; Uncomment to check result …
// IE 10
// ua = 'Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; Trident/6.0)';
// IE 11
// ua = 'Mozilla/5.0 (Windows NT 6.3; Trident/7.0; rv:11.0) like Gecko';
// Edge 12 (Spartan)
// ua = 'Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.71 Safari/537.36 Edge/12.0';
// Edge 13
// ua = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586';
var msie = ua.indexOf('MSIE ');
if (msie > 0) {
// IE 10 or older => return version number
return parseInt(ua.substring(msie + 5, ua.indexOf('.', msie)), 10);
}
var trident = ua.indexOf('Trident/');
if (trident > 0) {
// IE 11 => return version number
var rv = ua.indexOf('rv:');
return parseInt(ua.substring(rv + 3, ua.indexOf('.', rv)), 10);
}
var edge = ua.indexOf('Edge/');
if (edge > 0) {
// Edge (IE 12+) => return version number
return parseInt(ua.substring(edge + 5, ua.indexOf('.', edge)), 10);
}
// other browser
return false;
}
ASKER
thanks all.
You cannot (to the very best of my knowledge) make a Chrome tab open in IE. I have not seen such and some review now comes up empty.