prototype.js对象属性
大家好,我是新手,刚学prototype.js,请问:var Prototype = {
Version: '1.5.1',
Browser: {
IE: !!(window.attachEvent && !window.opera),
Opera: !!window.opera,
WebKit: navigator.userAgent.indexOf('AppleWebKit/') > -1,
Gecko: navigator.userAgent.indexOf('Gecko') > -1 && navigator.userAgent.indexOf('KHTML') == -1
},
BrowserFeatures: {
XPath: !!document.evaluate,
ElementExtensions: !!window.HTMLElement,
SpecificElementExtensions:
(document.createElement('div').__proto__ !==
document.createElement('form').__proto__)
},
ScriptFragment: '<script[^>]*>([\u0001-\uFFFF]*?)</script>',
JSONFilter: /^\/\*-secure-\s*(.*)\s*\*\/\s*$/,
emptyFunction: function() { },
K: function(x) { return x }
}请问,<script src="prototype.js" type="text/javascript">
alert(Prototype.Version);
</script>
为什么无法显示:Version属性值。
请大侠指点小弟,谢谢。