1.
Using the properties of a variable
2.
Converts all letters in a string to uppercase letters.
3.
JS in a variable to add a hyperlink
4.
The IndexOf method, where the first occurrence of a specified character in a string is positioned. If
The JavaScript date.getday () method returns the day of the week by local time to the specified date. The value returned by Getday is the integer corresponding to the day of the week: 0 for Sunday, 1 for Monday, 2 for Tuesday, and so on.Grammar
In writing a program, there may be a situation when you need to take a path out of a given two paths. Therefore, you need to use conditional statements to let programs make the right decisions and perform the right actions.
JavaScript supports its
JavaScript Learning-Improving articles
A. An object in JavaScript.
The object in JavaScript is a collection of key-value of a set of data, somewhat similar to the HashMap in Java, all of which are property in object. In general, creating an object
The DOM (Document Object model), which is an API for HTML and XML documents (the application interface);
The DOM depicts a hierarchical node tree in which developers can add/remove and modify portions of the page;
Introduction to a DOM
D
1. Define
Property: Properties, all HTML elements are represented by the HtmlElement type, the HtmlElement type directly inherits from the element and adds some attributes, which correspond to the following 5 standard attributes for each HTML
First of all, what's the regular expression? In fact, the introduction of concepts often does not help us understand what it is, so I would like to briefly describe the regular expression, in fact, is a string of records string rules, and so we read
Before writing a piece of nonsense: because the older version some browsers do not support JavaScript script, encountered script node, as the normal content output, so sometimes in order to make version compatible, will be in the script node content
This article examples for you to share a JS form verification of the specific code for your reference, the specific content as follows
Online demo:http://www.hui12.com/nbin/csdn/jsinput/demo.html
Effect Chart:
/* Authentication type
First, the constructor
Number (value)
New Number (value)
Second, number attribute
1. Number.MAX_VALUE returns the maximum number that can be represented.
2, Number.min_value can represent the smallest number.
3, Number.NaN non-numeric value.
4
Work needs to go through JS to get the name of the browser currently in use and version number, on the internet a lot of data have a key word is Navigator.appname, but this method gets the name of the browser is only two, ie or netscap, it can be
argument is a special parameter of a function in JavaScript, such as the following, using argument access function parameters to determine whether the function executes
Copy Code code as follows:
The length property of the
A. String
Copy Code code as follows:
var language = "JavaScript";
var language = ' JavaScript ';
Strings can be used in double quotes and single quotes, depending on your personal preference.
The string has a length
To see the implementation of the effect diagram
rules of the game: double-click the color of the stars, double-click the same part of the Disappeared
Instance Code
& Lt;link rel= "icon" href= "type=" Image/x-icon ">
Screen the right mouse button, CTRL + N, SHIFT+F10, F5 refresh, backspace key
function KeyDown () {
if ((Window.event.altKey) &&
((window.event.keycode==37) | |//Shielding ALT + Direction key ←
(window.event.keycode==39))) {//Shielding ALT +
JavaScript has a number of tips to make programming easier. One of these is the eval () function, which can execute a string as a JavaScript expression. Here is a description of it
Eval function
Function: First explain the JavaScript code, and then
The specific code and comparison are as follows:
Copy Code code as follows:
JavaScript version of the common sort algorithm
Random number of Maximum random number Regenerate
Time consuming
How do we iterate through the elements in the array? 20 years ago when JavaScript was first born, you could implement array traversal like this:1 var arr=["One", "one", "three"; 2 for (var i=0;i) {3 document.write (Arr[i]); 4 } Since ES5 is
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service