BVB Source Codes

che Show browserNotSupported.js Source code

Return Download che: download browserNotSupported.js Source code - Download che Source code - Type:.js
  1. /*
  2.  * Copyright (c) 2012-2017 Codenvy, S.A.
  3.  * All rights reserved. This program and the accompanying materials
  4.  * are made available under the terms of the Eclipse Public License v1.0
  5.  * which accompanies this distribution, and is available at
  6.  * http://www.eclipse.org/legal/epl-v10.html
  7.  *
  8.  * Contributors:
  9.  *   Codenvy, S.A. - initial API and implementation
  10.  */
  11. var USER_AGENT = navigator.userAgent.toLowerCase();
  12. var IS_WS_SUPPORTED = ("WebSocket" in window);
  13. if (!IS_WS_SUPPORTED || (USER_AGENT.indexOf("chrome") == -1 && USER_AGENT.indexOf("firefox") == -1 && USER_AGENT.indexOf("safari") == -1)) {
  14.     if (document.body != null) {
  15.         document.body.appendChild(createDivContainer());
  16.     }
  17.  
  18.     function createDivContainer() {
  19.         if (USER_AGENT.indexOf("msie 7") != -1 || USER_AGENT.indexOf("msie 8") != -1 || USER_AGENT.indexOf("msie 9") != -1) {
  20.             var container = document.createElement('<div style="position:relative; height: 290px; margin: 20px auto 0; padding-top: 10px; width: 600px; text-align:center; font-family: Verdana, Bitstream Vera Sans, sans-serif; font-size:16px; border-top: 1px solid #DBDFE5; border-bottom: 1px solid #DBDFE5"></div>');
  21.         }
  22.         else {
  23.             var container = document.createElement('div');
  24.             container.setAttribute('style', 'position:relative; height: 290px; margin: 20px auto 0; padding-top: 10px; width: 600px; text-align:center; font-family: Verdana, Bitstream Vera Sans, sans-serif; font-size:16px; border-top: 1px solid #DBDFE5; border-bottom: 1px solid #DBDFE5');
  25.         }
  26.         container.innerHTML = '<div style="height: 50px; margin:0 auto; font-size:18px; color: #2C578A; font-weight: bold">It looks like you&#39;re using a browser that isn&#39;t supported.</div><div style="height: 50px; margin:0 auto; font-size:16px; color: #707070">To use Codenvy, upgrade to the latest one of these supported browsers.</div><div style="position: relative; height: 175px; background-color: #EFEFF5;"><div style="position: absolute; left: 65px; font-weight: bold;"><a href="http://www.google.com/chrome/" target="_blank" style="text-decoration: none; cursor: pointer;"><div style="width: 120px; height: 25px; padding-top: 130px; background: url(chrome.png) no-repeat; color: #2C578A;">Google</br>Chrome</div></a></div><div style="position: absolute; left: 234px; font-family: Verdana, Bitstream Vera Sans, sans-serif; font-weight: bold;"><a href="http://www.firefox.com" target="_blank" style="text-decoration: none; cursor: pointer;"><div style="width: 120px; height: 25px; padding-top: 130px; background: url(firefox.png) no-repeat; color: #2C578A;">Mozilla</br>Firefox</div></a></div><div style="position: absolute; left: 396px; font-weight: bold;"><a href="http://support.apple.com/downloads/#safari" target="_blank" style="text-decoration: none; cursor: pointer;"><div style="width: 120px; height: 25px; padding-top: 130px; background: url(safari.png) no-repeat; color: #2C578A;">Apple</br>Safari</div></a></div></div>';
  27.         return container;
  28.     }
  29. }
  30.  
downloadbrowserNotSupported.js Source code - Download che Source code
Related Source Codes/Software:
Gource - oftware version control visualization ... 2017-01-10
FDFullscreenPopGesture - A UINavigationController's category to enable full... 2017-01-10
node-style-guide - A guide for styling your node.js / JavaScript code... 2017-01-09
ImageOptim - GUI image optimizer for Mac htt... 2017-01-09
falcon - Falcon is a low-level, high-performance Python fra... 2017-01-09
notepad-plus-plus - Notepad++ official repository h... 2017-01-10
waterline - An adapter-based ORM for Node.js with support for ... 2017-01-10
Workerman - An asynchronous event driven PHP framework for eas... 2017-01-10
structor - An advanced visual editor for React components ... 2017-01-10
golearn - Machine Learning for Go 2017-01-10
CRYENGINE - CRYENGINE is a powerful real-time game development... 2017-06-11
postal - 2017-06-11
reactide - Reactide is the first dedicated IDE for React web ... 2017-06-11
rkt - rkt is a pod-native container engine for Linux. It... 2017-06-11
uWebSockets - Tiny WebSockets https://for... 2017-06-11
realworld - TodoMVC for the RealWorld - Exemplary fullstack Me... 2017-06-11
goreplay - GoReplay is an open-source tool for capturing and ... 2017-06-10
pyenv - Simple Python version management 2017-06-10
redux-saga - An alternative side effect model for Redux apps ... 2017-06-10
angular-starter - 2017-06-10

 Back to top