Project

General

Profile

« Previous | Next » 

Revision 3102

Added by perry almost 18 years ago

safari/opera detection for interactive map. Users of non xslt-compliant browsers will be redirected to an error page.

View differences:

lib/spatial/mapbuilder/lib/Mapbuilder.js
116 116
        break;
117 117
      case MB_LOADED:
118 118
        clearInterval(this.scriptsTimer);
119
          
120
        /*
121
         *  Test for XSLT support
122
         *  if not, redirect to an appropriate message.
123
         */
124
        if (typeof XSLTProcessor != "undefined") {
125
           var UA = navigator.userAgent;
126
           var AV = navigator.appVersion;
127
           opera = UA.indexOf("Opera") == -1 ? false : true;
128
           //khtml = ((AV.indexOf("Konqueror") >= 0)||(AV.indexOf("Safari") >= 0)) ? true : false;
129
           if (opera || khtml) {
130
               window.location = baseDir+"/util/noxslt.html";
131
           }
132
        } else {
133
           window.location = baseDir+"/util/noxslt.html";
134
        }
135

  
119 136
        break;
120 137
    }
121 138
  }
lib/spatial/mapbuilder/lib/util/noxslt.html
1
<html>
2
<head>
3
 <title> Your browser doesn't support this feature </title>
4
<body>
5
  <h3> Your browser does not support this feature </h3>
6
  The interactive map requires a browser with client-side XSLT support such as Mozilla Firefox or Microsoft Internet Explorer. It will <em> not </em> work with current versions of Safari or Opera, sorry. 
7
</body>
8
</html>
0 9

  

Also available in: Unified diff