This article lists 21 Javascript tips worth adding to your favorites. In actual work, if you can use them properly, it will greatly improve your work efficiency.
1. Convert Javascript array to CSV format
First, consider the following application
This article describes how to pass special characters (+, & amp;) in Javascript. If you need it, refer to the background:
When I was doing a task today, when I passed a long string of characters using Jquery Ajax, the verification in the background
This article mainly introduces the javascript client traversal control and the sample code for getting the parent container object. If you need it, you can refer to it for help.
1. traverse all the controlsFunction findControlAll ()
{
Var inputs =
Use js to verify whether the input is a mobile phone number or phone number. The following is a good example. If you are interested, refer to the following code:
The Code is as follows:
This article mainly introduces the sample code for converting JavaScript integer strings to amount data. For more information, see.
The Code is as follows:
Function zhen (str ){Var arr_1 = ["", "\ u62fe", "\ u4f70", "\ u4edf", "\ u4e07", "\ u4ebf"]
This article mainly introduces how to use jquery to obtain the selector in css. If you need it, you can refer to it and hope to help you.
Before writing, review the differences between elements and nodes:
Element is one of the most widely used
This article provides a detailed summary of Javascript Object attribute methods. For more information, see.
Array: an ordered set of series Elements
Attribute:
Length: used to obtain the number of array elements, that is, the maximum subscript plus
Use js to declare an array. The object is in the jsp page (obtain json data from ajax ). For more information, see.
1. jsp labels can be used in jsp page js
Var patientInfoList = {patientId: "$ {session. patientId }"};VarDocDepList = [], NoTypeMap =
JS functions are often used in many ways, such as getting page address parameters, address redirection, and determining whether a number is required. I have sorted out some information in this article. If you are interested, refer to Js to get page
The first note is that window. navigate and window. location. href both implement Page Link jump. The following describes their differences. For more information, see window. navigate and window. location. href.
Window. navigate ("http://jb51.net/
To convert a able to json, You Can serialize dt to json and put it into the hidden control hidBoundary at the front end. The specific implementation is as follows, if you have similar requirements, refer to section 1. serialize dt into json and put
WEB development is often used to solve the problems related to this Article. Here, we will summarize the usage and solve the problem of jQuery's object height, next, let's take a look at some of the issues related to document processing in WEB
Modularization is a way to separate the system into independent functional parts, which can be divided into independent functional parts, strict definition of module interfaces and transparency between modules are now under attack by MVC frameworks
Window. opener, via window. open the reference of the parent form of the child form. The following describes how to use it in detail. If you are interested, refer to window. opener, via window. open refers to the parent form of the child form.
For
This article provides a detailed analysis of the use of regular expressions in Javascript. For more information, see
The Regular Expression in js is much weaker than the regular expression in C #, but it is basically enough.1. Define a regular
This article is translated from ScottAllenPrototypesandInheritanceinJavaScript, a Microsoft cool-man. This article gives a detailed analysis and explanation of Prototype and Prototype inheritance. It is one of the best works to understand JSOO.
I.
Introduction to javascript event processing programs. For details about js learning, refer
1. DOM0-level event handlerReturns a function value to an event handler property.
For example:
The Code is as follows:
Var btn = document. getElementById ("
JQuery is the most popular and widely used JavaScript framework. It simplifies HTML document traversal, event processing, animation, and Ajax interaction, it helps Web developers to quickly implement a variety of exquisite Interface Effects jQuery's
The custom DateDiff function in JavaScript is compatible with all browsers. DateDiff is used to return the time interval between two dates.
The Code is as follows:
Recently I used javascript to write a simple calculator. It seems okay to test it myself. The Code has been commented out. It is very good. I suggest you learn it. Recently I wrote a simple calculator in javascript, and it feels okay to test it on
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