If an element in the document is redundant, delete it. JQuery provides two methods to delete nodes: The remove () method and the empty () method.1. remove ():Copy codeThe Code is as follows: Insert title here What is your favorite fruit? apple
The first method is to use the native js Code as follows:Copy codeThe Code is as follows: simple tab
Technology tourism entertainment Acer R7 Dual Axis deformation evaluation: the touchpad design is too alternative (figure) Sony Xperia Tablet
It mainly uses the timer principle, bind, trigger application, etc.Copy codeThe Code is as follows: Implementation of banner switching 1 2 3 4 5 The effect is as follows:
Generally, when jQuery and other libraries are used on the same page, the definition of global name $ is the biggest debate and conflict. As we all know, jQuery uses $ as the alias of jQuery name and applies it to every function exposed by jQuery.
Recently, I want to present a product. Because there are many products that cannot be displayed on a single screen, it is not easy to find a few items on the Internet, in the end, you can only write it by yourself.
The effect is as follows:Simple
We often use the ParseInt function to convert the string to an int value. The ParseInt function has two parameters that can be set. The second parameter can be set by default.
ParseInt ("string", in hexadecimal format)
Var num1 = ParseInt ("10", 2)
Sometimes when we do dynamic growth div, we usually append the content to the bottom of the div, but this will bring a problem that is quite painful, that is, the newly added content will be hidden at the bottom, for exampleHow can we make scrollbar
Requirement: complete adding, deleting, modifying, and copying nodes.Methods and attributes used:1. Obtain the parent node of a nodeParentNode attributes2. Obtain the subnode set of a nodeChildNodes attributes3. Create a New NodeThe createTextNode
Copy codeThe Code is as follows: Use javascript.Copy codeThe Code is as follows: select all 2:Copy codeThe Code is as follows: 1 2 allselect 3:Copy codeThe Code is as follows:
For any website, the logon interface is one of the most important pages. The design of this page is constantly evolving, and designers will make full use of the latest technology and popular design advantages to apply it to the login interface
Let's consolidate the content in the previous section.
We hope to change the font and width of the article when reading the article.
For example, the following article
Html code:
A Christmas Carol
A
Preface first, I declare that the method is based on some information on the Internet, such as the leap year, such as the day of the week on the first day of each month. If you don't talk too much about it, you can split the functions and try to
JQuery is a good Javascript framework after Prototype, because of its compatibility, it is much better than using JS directly (it is a lightweight js library, which is not suitable for other js libraries, and it is compatible with CSS3 and various
First, JS delayed Loading The Code is as follows:Copy codeThe Code is as follows: Second, the final loading of JS Insert the following code where Javascript is to be inserted: LOADING... Of course, the LOADING... You can switch to your favorite
Copy codeThe Code is as follows: Get DIV relative coordinates in JS I am a DIV. After testing, there is a 2PX error...The current mouse coordinates are:X: Y: If not, tryDocument.doc umentElement. scrollLeftReplaceDocument. body. scrollLeft
The sample code in IE6 is as follows:Window. opener = null;Window. close ();
The sample code in IE7 is as follows:
Window. opener = null;Window. open ("", "_ self ");Window. close ();
To display in full screen (remove IE Toolbar, address bar, 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.