Front.
Drag and Drop (DRAG-AND-DROP,DND) is actually two actions--drag and drop. So, it involves two elements. One is the dragged element, called the drag-and-drop source, and the other is the target to be placed, called the drag-and-drop target.
Basic Concepts
JavaScript is an interpreted language, and the browser acts as an interpreter. When JS executes, it is explained before execution in the same scope. The definitions of function and Var are compiled and then executed from the top down
Definitions and usage
The push method can add one or more elements to the end of the array and return a new length.
The Join method is used to add all elements of an array to a specified string, and the elements are split by the specified
Take an example, explain the Call,apply,bind method in JavaScript, for everyone's reference, the specific contents are as follows
Why What's call,apply,bind doing? Why do you want to learn this?
This is
First, global namespace pollution
Always wrap the code inside an immediate function expression to form a separate module.
Not recommended
var x = ten,
y = m;
Console.log (window.x + ' + window.y ');
Recommended
;(function
Years ago in the rewrite Taobao shopping card script, inadvertently found an interesting thing. The code is similar:
Copy Code code as follows:
var associative_array = new Array ();
associative_array["one"] = "1";
Here are some of the ways that the cloud-dwelling community has been using
Copy Code code as follows:
Here is the regular function
Parsing classes that implement URL links with JavaScript
Http://www.jb51.net/article/15000.htm
Modules are an integral part of any powerful application and often help us to clearly isolate and organize the code units in the project.
JS in the implementation of the module method:1. Object literal notation2.Module mode3.AMD Module4.CommonJS
Objective
There are a lot of ways to create objects using JavaScript, now to enumerate four of them, and to list the pros and cons of each, so you can choose to use them, and here's a look.
Factory mode
function Createperson (name, age) {
Method One: Use the browser internal converter to implement the conversion, the main point is to dynamically create a container tag elements, such as Div, the string to be converted is set to this element innertext (ie support) | | Textcontent
JavaScript parsing reads an XML file, essentially loading and parsing an XML file, and then it can test the contents of the parsed XML file and print out the output.
Online Demo: http://demo.jb51.net/js/2012/readxml/
Note: Test needs to be tested in
The example in this article describes how JavaScript simply gets the current time of the system. Share to everyone for your reference, specific as follows:
The screenshot of the running effect is as follows:
The specific code is as follows:
JavaScript is the scope of the front-end development has been more difficult to understand the point of knowledge, the scope of JavaScript mainly remember a few words, all over the world are not afraid ...
One, "no block-level scope in JavaScript"
Here are some of the syntax highlighting plug-ins for pure JavaScript implementations.
English Original:
http://www.webdesignbooth.com/9-useful-javascript-syntax-highlighting-scripts/
1.SyntaxhighlighterI believe this plugin is more than we use,
SetTimeout (Script,millisecond); Run the code (once only once) from how many microseconds it is now
SetInterval (Script,millisecond); Is running code every few microseconds
Example:
1. Implementation of a
sec
[Ctrl + A All
First, with JS calculation
12.32 * 7 How much is the result?Answer: 86.24000000000001Why is there such a problem? How to solve?JS in processing decimal multiplication and division of the time there is a bug, the solution can be: The decimal into an
The array type in JavaScript is often used, and the array type provides a number of ways to achieve our needs, and here's a summary
First, the way to create an array
var colors=new Array ();
var colors=new array (3);//Create an array of length 3
The title in the head is displayed in the body, and the headtitle is displayed in the body.
One problem today is that the content in the title will be displayed in the body.
1 2 324234 3
I searched the internet to find out that this problem
How to customize the blog garden style and the blog garden styleDistress
Every time I see other people's blog styles, I feel very comfortable and nice.
After I activate my blog, I cannot use the preset style to achieve the desired page effect.
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