Read Catalogue
The first rule of javascript: Put the script at the bottom.
The second law of javascript: Package scripts in groups.
Zatan
Try to use local variables to save global variables
As little as possible to change
HTML5 expands the HTMLDocument,A new feature has been added.
1.document.readstate = ' Loading ' | | The ' complete '//readystate-enabled browser has ie4+, Firefox 3.6+, Safari, Chrome and opera + +.
2.document.compatmode = ' Css1compat ' | |
1. Define an empty parent class constructor, and then define the properties and methods for the parent class by prototype2. Define a constructor for an empty subclass, then bind the prototype of the subclass to an instance of the parent class, and
/** * JavaScript Object methods of 3 ways to recommend the third operating efficiency is best */function P (name, age) {this.name = name; this.age = age;//First Method this.show = function () {alert (this.name);} This.doing = doing; }//Another
We know that JavaScript's date object does not provide a date format function. Converting a Date object to a format such as "2015-7-02 20:35:11" is another non-frequent requirement in the project. Recently in our project saw a piece of code, very
All the time, the concept of a callback function is very vague:The following is an introduction to the callback function in the JavaScript language pristine book, for example:1. Functions make it easier to handle discontinuous events. For example,
A Boolean judgment in the IF ()ifAn expression is forced to convert expression to a Boolean value through the ToBoolean method defined by ES5.
Data type
Conversion results
Undefined
False
Some concepts:Overload (Overload):What is: the same function name, a number of different parameter list functions, when called, according to the different parameters, automatically select the corresponding function call!Why: Lighten the burden of
Design PatternsDesign patterns are naming, abstracting, and identifying common design structures that are useful for reusable object-oriented design.Design patterns determine the classes and their entities, their roles and collaborations, and their
Window Event PropertiesEvents triggered for the Window object (applied to tags):
Properties
value
Description
Onafterprint
Script
A script that runs after the document is printed.
2. Common functions for Date objects2. Common functions for Date objects Date Object method
Method
Description
Date ()
Returns the date and time of day.
GetDate ()
Returns the day of the one
Objective
Oop
__proto__ and prototype/prototype chain/prototype properties and Prototyping methods/for-in loops in JavaScript's OOP
1 __proto__ and prototype/prototype chain
1. prototype (prototype of
What is CSS?
CSS is short for Cascading Style Sheet. Form. It is a markup language used to (enhance) control webpage styles and allow separation of style information from webpage content. Using CSS styles can control many attributes that cannot be
Implement card effects [DIV + CSS3] and card divcss3
I. Text card Effect
1 2 3 meta 4 text card effect 5 21 22 23 cards 24 the box-shadow attribute is used to create paper style cards: 25 26 27 1 28 29 30 January 1, 2016 31 32 3
Css uses display: inline-block for layout,
Display of css: inline-block Layout
1. Several commonly used display attribute values, inline, block, and inline-block
Inline:
Block:
Inline-block:
Figure 1:Figure 2:
The two figures show that the
In BS, we have learned both xml, html, css, and js. At first, we cannot tell the differences and connections between the four. With the increase of knowledge, we have some experiences, the following is a brief introduction to the differences between
This article mainly explains in detail the complex javascript window sharding, what is the relationship between window sharding and frame windows in JavaScript. For more information, see
What is window frame separation?
Window Frame separation
Jquery. timelinr. js is a very cool jQuery timeline plug-in. The following is an example of how jQueryTimelinr achieves a Vertical Horizontal timeline plug-in. For more information, see jquery. timelinr. js, which is a very cool jQuery timeline plug-
This article mainly introduces the JavaScript class and style operations. If you need more information, you can directly paste the js Code. The specific code is as follows:
Untitled documentP instance textChangeStyle ()Script function
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