1 / 16
文档名称:

javascript ,java真谛(javascript, java真谛).doc

格式:doc   大小:24KB   页数:16页
下载后只包含 1 个 DOC 格式的文档,没有任何的图纸或源代码,查看文件列表

如果您已付费下载过本站文档,您可以点这里二次下载

分享

预览

javascript ,java真谛(javascript, java真谛).doc

上传人:rjmy2261 2017/11/18 文件大小:24 KB

下载得到文件列表

javascript ,java真谛(javascript, java真谛).doc

文档介绍

文档介绍:javascript ,java真谛(javascript, java真谛)
Location of JS:
Header: make sure the script is loaded when it is called
Body: when the page is loaded, it is called
External JS file: does not contain <script> Tags
Usage: <script SRC = "" >.....</sceipt>
3, notes
Single: / /
Multi line:..*/ / *...
4, = = = symbol type and value congruence are equal
5, three kinds of prompt box
Warning: Alert ("alert");
Confirmation: confirm ("confirm");
Hint: prompt ("prompt", "default");
6, for in statement
For (variable in object)
{
Execute code here
}
7, regular expressions
Test () method: retrieves the specified value in the string, if there is a return True, otherwise False
Var patt1=new RegExp ("e");
( ("The best things in life free are");
Exec () method: retrieves the specified value in the character, if there is a value returned, otherwise returns null
Var patt1=new RegExp ("e");
( ("The best things in life free are");
Compile () method: used to change the retrieval mode and add and delete the second parameters
Detailed reference: icle/
(")"; output statement
notes / /
3. the traditional order of HTML documents is document->html-> (head, body)
4. the order of DOM in a browser window is window-> (navigator, screen, history, location, document)
5. get the name and value of the element in the form: (the ID number of the element in the form).Name (or value)
6. a lowercase to uppercase JS: ("output").Value = ("input"). ();
The value types in : String, Number, Boolean, Null, Object, Function
The character type in is converted into numeric type: parseInt (), parseFloat ()
The numbers in are converted into character types: ("+" variables)
The length of the fetch string in is: (length)
The characters in are connected to characters using the + number
Compari