Skip to content
Permalink
Browse files

Added checks for the box model.

  • Loading branch information
jeresig committed Jun 16, 2006
1 parent 34dd8af commit a70ab6564bb469af0a64d43bb0b5c20bc27d83fb
Showing with 7 additions and 1 deletion.
  1. +7 −1 jquery/jquery.js
@@ -320,12 +320,18 @@ function $(a,c) {

(function(){
var b = navigator.userAgent.toLowerCase();

// Figure out what browser is being used
$.browser =
( /safari/.test(b) && "safari" ) ||
( /webkit/.test(b) && "safari" ) ||
( /opera/.test(b) && "opera" ) ||
( /msie/.test(b) && "msie" ) ||
( !/compatible/.test(b) && "mozilla" ) ||
"other";

// Check to see if the W3C box model is being used
$.boxModel = ( $.browser != "msie" ||
document.compatMode == "CSS1Compat" );
})();

$.apply = function(o,f,a) {

0 comments on commit a70ab65

Please sign in to comment.
You can’t perform that action at this time.