/**\r
* Set a single property to a value, on all matched elements.\r
*\r
+ * Note that you can't set the name property of input elements in IE.\r
+ * Use $(html) or $().append(html) or $().html(html) to create elements\r
+ * on the fly including the name property.\r
+ *\r
* @example $("img").attr("src","test.jpg");\r
* @before <img/>\r
* @result <img src="test.jpg"/>\r
ret = 'none';\r
else\r
jQuery.swap(elem, { display: 'block' }, function() {\r
- ret = document.defaultView.getComputedStyle(this,null).getPropertyValue(prop);\r
+ var c = document.defaultView.getComputedStyle(this, '');\r
+ ret = c && c.getPropertyValue(prop) || '';\r
});\r
\r
}\r