This time because to do a website, and the space does not support ASP, so took up the JavaScript tutorial looked, see can be in the static space to achieve dynamic, of course, this dynamic is not the real sense of the, can be said to be just a
First, the introduction
In the C # and Java languages, object-oriented is implemented in a class manner, especially inheriting this feature, and the way inheritance of classes shows powerful features and is easy to learn. JavaScript is not a pure
Don't say much nonsense, the specific code is as follows:
line: column: get random colors
The above is a small set of JavaScript to introduce the implementation of random color input box, I hope to help everyone, if you have
You can use backslashes in JavaScript to add special characters to a text string.
inserting special characters
The backslash is used to insert ellipses, line breaks, quotes, and other special characters in a text string.
Take a look at
A loop in JavaScript is used to execute the same piece of code for a specified number of times (or when the specified condition is true).
JavaScript Switch Declaration
If you want to choose to execute one of several blocks of code, you can use the
1, expression:
Simplest expression: A direct amount or variable name. var a = 1;
The value of a direct-weight expression: itself.
Value of the variable expression: The value that the variable holds or refers to.
2, Operator:
Unary operators: for
How to pass parameters to SetTimeout, setintervallook at the following code:
var str = ' AAA ';
var num = 2;
function Auto (num) {
alert (num);
}
SetTimeout (' Auto (num) ', 4000);
This is a good way to write, but as it says
There are two kinds of event bindings: Traditional event binding (inline model, script model), and modern event binding (DOM2 level model). Modern event bindings provide more powerful and convenient functionality on traditional bindings.
A problem
Tools
Regexpal is an online JavaScript regular expression processor with the address: http://www.regexpal.com
Learning is important is the practice of operation, may wish to raise a chestnut:
Match number: 707-827-7019
Character Group match
[0-9
Let's look at an example first.
function foo () {
console.log (THIS.A);
}
var obj = {
a:2,
foo:foo
};
Obj.foo (); 2
This points to obj because the call-site at Foo execution (which can be understood as the scope of the call) is
What is Backbone.js?Backbone.js is the top ten JS framework, Backbone.js is a heavyweight JS MVC application framework, but also JS MVC framework of the originator. It provides a set of rich APIs for enumerating functions through the models data
Group
The following regular expressions can match kidkidkid:
/kidkidkid/
And another more elegant way to do this is:
/(Kid) {3}/
Here a small whole of the parentheses parcel is called grouping.
Candidate
In a group,
Learning causes:
In the previous JavaScript learning, this,call,apply always puzzled me, but their use is very extensive. It took a day to figure out the this,call,apply of JavaScript.
The book is also a lot of reference, "JavaScript design
What are the basic grammar requirements for JavaScript language? Here are a few answers:
One, case sensitiveThe JavaScript language is case-sensitive, with two strings different from the same case, and is considered a different string. the keywords
JavaScript variables can be converted to new variables or other data types:
By using JavaScript functions
Automatic conversion via JavaScript itself
Converts a number to a string
Global method String () converts a number to a
REGEXP: is shorthand for regular expressions (regular expression).What is REGEXP?A regular expression describes the pattern object of a character.When you retrieve a text, you can use a pattern to describe what you want to retrieve. REGEXP is the
The function of an array object is to store a series of values using a separate variable name.Create an array and assign it a value:Instance
var mycars = new Array ();
Mycars[0] = "Saab";
MYCARS[1] = "Volvo";
MYCARS[2] = "BMW";
What is
To make the timer loop work you need to write a function to implement the loop call. Here is an example:
var the_count = 0;var the_timeout;function Dotimer (){Window.document.timer_form.the_text.value = The_count;The_count + 2;The_timeout =
Now that you have mastered the advanced string processing and related array concepts, it's time for us to open the magic cookie jar. Cookies are the information that records the people who visit your site, it actually resides on the user's hard
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.