In fact, there are many descriptions about querySelector and querySelectorAll. Here we mainly make a record. At the beginning, many people will use the jquery selector to compare the two APIs (I am also ), the similarities and differences are
Recently I encountered a problem. When using jquery to write a timer, there will always be an error indicating that fn does not exist. When I write a timer, I am always used to direct
SetInterval ("fn ()", 2000 );
Recently encountered a problem.
Many articles about the differences between the substr, substring, and slice methods have been found online, and the content is basically the same. Then, I moved the code in one of the articles to a local machine for testing and found that the test
A closure is an expression (usually a function) that has many variables and is bound to these variables. Therefore, these variables are part of the expression, this article will give you a deep understanding of the concept of Javascript closures in
When you use JavaScript scripts to obtain the size of an element, you need to understand several attributes. Otherwise, it will be tricky. In the past, I have memorized these attributes and seldom really understood them. If I forget it, I will check
Use constructors to define class attributes (fields) and use prototype to define class methods. There is a third method. This method seems to be widely used by many people. Take the advantages of the first two methods:
A. Use constructors to define
I am constantly using the astinus development process. Some JS Code has been pasted in, so an error is displayed on the page. Apparently, I put the source code directly into the html text-Well, after I switched from 05 years to online games, I have
Shells (the author of this article) also belong to the type that will just use JQuery. There are also many problems encountered during the learning process, especially when getting started. I have been preparing to write some articles about JQuery,
In the demand for "loading on demand", we often judge how to judge the completion of Script Loading by returning a callback function when the script is loaded? We can use onload to determine the loaded JS object (js. onload), this method is
The fastest selector in jQuery is the ID selector because it comes directly from the getElementById () method of JavaScript.
1. always inherit from the ID Selector
The fastest selector in jQuery is the ID selector because it comes directly from the
The ctl00_MainContent_grvDevelopKit is in the background code & lt; table & gt. /*
Select All */
Function SB002SelectAll ()
{
Var table = document. getElementById ("ctl00_MainContent_grvDevelopKit ");
For (var I = 1; I
{
Var input = table.
The JS class is automatically completed, and the user experience is better. Encapsulated into a class for ease of use. Site 1. encapsulated JS files
//************************************** ******************
// Creation date:
// OPERATOR: oloen
//
Some attributes are different in different browsers. The following is a summary of ie and firefox.
Png transparentAlphaImageLoader
Filter: progid: DXImageTransform. Microsoft. AlphaImageLoader (enabled = bEnabled, sizingMethod = sSize, src = sURL)
Statements about object-oriented programming now have the strength to learn the following about object-oriented programming, but they actually belong to the content of the previous chapter. The with statement specifies the default object for one or
Chapter 4 Case Study: childNodes attribute of the javascript Art Museum: An array containing all the child elements of the given element node is returned.
ChildType attribute: The returned array contains all types of nodes.
NodeValue attribute:
Js operation Xml (send Xml to the server to process the Xml returned by the server) (currently only valid under IE) Foreground:
The Code is as follows:
Js operation Xml (send Xml to the server and process the Xml returned by the server) (valid
Array is used in js. For example, if multiple inputs with the same name are dynamically generated, You need to determine whether the input is an array. if (document. mylist. length! = "Undefined") {} This usage is incorrect.
Correct is if (typeof
Today, I encountered an interesting problem when I was working on the enterprise level function of Jingdezhen. On a jsp page, I need to convert a java string into a boolean type of js. Originally, I thought that the boolean type conversion of js is
Today, a friend asked me about how to use JAVASCRIPT to transfer data between various forms on the page. I wrote it before, but I never paid attention to it. Today I have summarized it, I hope to give you some help and summarize the previous and
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