以下是一个网站的js测试题,我挑了几道出来,都是单选题;在不查资料的情况下,来测测你都能拿下么?
这些题是我敲出来的,当时测试的时候无法拷贝,有敲错的地方,望指正!
Question 1 of 40
Which of the following is true?
a. If onKeyDown returns false,the key-press event is cancelled
b. If onKeyPress returns false,the key-down event is cancelled
c. If onKeyDown returns false,the key-up event is cancelled
d. If onKeyPress returns false,the key-up event is cancelled
Question 7 of 40
Consider the three variables:
someText = 'JavaScript1.2';
pattern = /(\w+)(\d)\.(\d)/i;
outCome = pattern.exec(someText);
What does pattern.ignoreCase contain?
a. true
b. false
c. undefined
d. null
e. 0
Question 8 of 40
Given the following window.open function:
window.open(url,name,"attributes")
How will you ensure the different urls are opened in the same window?
a. The second attribute,name should be the same
b. The name attribute should be null
c. The name attribute should be omitted
d. The name attribute should be different
e. None of the above
Question 12 of 40
You are setting cookies with JavaScript. What happends to cookies.txt data if the file exceeds the maximum size?
a. Your script automatically generates a run-time error
b. Your script automatically generates a load-time error
c. All processed using document.cookie are ignored
d. The file is truncated to the maximum length
Question 14 of 40
How would you invoke the browser's Add To Favorite Dialog?
a. Use the window.AddFavorite method
b. Use the document.AddFavorite method
c. Use the window.external.AddFavorite method
d. It is not possible using JavaScript
Question 18 of 40
Which of the following escape sequences represents form feed?
a. //f
b. 'f'
c. /f
d. \f
Question 21 of 40
You want to be able to manipulate the list of visited URLs.Which object would you use?
a. doucument
b. window
c. history
d. browser
e. form
Question 23 of 40
The statement navigator.platform indicates 'Win16',but you are running Windows NT.Which of the following is true?
a. navigator.platform is supposed to show 'Win16' on Windows NT
b. The userAgent property reflects the correct operating system
c. The property can be modified
d. navigator.platform shows the operating system for which the browser was compiled
e. The browser version is outdated
Question 36 of 40
You want to ascentain the page from which the user has navigated to the current page.How would you accomplish this?
a. It is not possible in javascript. This can be done only through server side scripting
b. Use document.referrer property
c. Use the window object
d. None of the above
Question 37 of 40
You've embedded the document.write() method to write some text within a pair of <TD></TD> table tags.
Upon loading the file,however,you get some garbled junk on the page where that text should be.
What could be the reason for this?
a. The browser does not support JavaScript
b. You are using an older version of the browser
c. The browser does not supprot cookies
分享到:
相关推荐
一份js基础测试题,包含选择题和程序题,含答案解析,选择题(50道),程序题(4道),可用于员工考核
HTML+Javascript+CSS测试题
javascript测试题.pdfjavascript测试题.pdfjavascript测试题.pdfjavascript测试题.pdfjavascript测试题.pdfjavascript测试题.pdf
用JS做测试题时显示所做测试题的进程的一段JS代码
javascript试题 附答案 适于初学者
JavaScript内部测试题1 喜欢的朋友可以下载额。
JAVASCRIPT 阶段检验测试题 机试部分
JavaScript测试题,对JavaScript感兴奋的可下载一下
js练习题
JavaScript上机实验题 涉及一些javascript的应用 试题也比较适中
北大青鸟5.0JavaScript内部测试题 里面包括题目和答案。。
100道Vue.js 面试题(含答案)
javaScript 基础测试题,适用于在校大学生复习以及考试
java面试题--橙红科技javascript新测试题
html+css+js测试题-副本.pdf
北大青鸟内部测试笔试题1北大青鸟内部测试笔试题1北大青鸟内部测试笔试题1
htmlcssjs测试题-副本讲解演示教学.pdf
JavaScript期末测试题.doc
js基础测试题.pdf