最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

What version of JavaScript does ASP Classic use? - Stack Overflow

programmeradmin3浏览0评论

The hacks I've seen for identifying a JavaScript version are all tailored to the browser, not an ASP Classic server running JavaScript.

(And no, I'm not running ASP Classic/JavaScript by choice.)

The hacks I've seen for identifying a JavaScript version are all tailored to the browser, not an ASP Classic server running JavaScript.

(And no, I'm not running ASP Classic/JavaScript by choice.)

Share Improve this question asked Feb 4, 2015 at 21:10 Shay GuyShay Guy 1,0601 gold badge11 silver badges22 bronze badges 7
  • Out of curiosity, how is server-side JavaScript involved with ASP Classic? – Pointy Commented Feb 4, 2015 at 21:13
  • 1 @Pointy — JScript is one of the more mon languages used for Classic ASP. I think only VBScript is more mon. (The only other language I've heard of being used is PerlScript via a plugin that ActiveState used to make) – Quentin Commented Feb 4, 2015 at 21:23
  • @Quentin so it used JScript on the server? Huh. I did a tiny bit of ASP work back around 1999 or so but it was all VB. So server-side JScript had some sort of COM integration I guess. Weird. – Pointy Commented Feb 4, 2015 at 21:36
  • 1 No @Pointy JScript (Microsoft implementation of ECMAScript) is an ActiveX Scripting language and available in Classic ASP by using the <%@ Language = "JScript" %> processing directive. Do not confuse JScript with JavaScript there are differences (as @Dai point's out in their answer below). – user692942 Commented Feb 4, 2015 at 22:06
  • @Lankymart <%@ language=JavaScript %> also works, at least sometimes. It's what the system I'm using starts its ASP files with. – Shay Guy Commented Feb 4, 2015 at 22:12
 |  Show 2 more ments

1 Answer 1

Reset to default 19

Disclaimer: I'm an engineer on Microsoft's JavaScript team (specifically, Chakra).

The IActiveScript JavaScript engine used by "Classic ASP" is also used by the Windows Script Host (cscript and wscript) and was also used by IE for a while (IE9 and later, certainly does not).

Anyway, the JScript engine generally coincides with the ECMAScript 3.0 specification with some proprietary extensions (such as ActiveXObject). The specification is available here: http://www.ecma-international/publications/files/ECMA-ST-ARCH/ECMA-262,%203rd%20edition,%20December%201999.pdf - this specification was written in 1999.

This version of JScript has not been updated much since the days of Windows 2000 (i.e. no new features have been added, the only changes have been for the benefit of security).

As such, it does not include features introduced in ECMAScript 5, like strict mode, or Array.isArray.

发布评论

评论列表(0)

  1. 暂无评论