This article is mainly to share the use of pure JavaScript to achieve the control of four directional text seamless scrolling code, the effect is very good, the need for small partners can refer to.
To achieve a seamless text scrolling effect: ?
The Math object method in javascript is rounded up, with a decimal number plus 1 for the integer part, rounding, down, and so on, and so on, here's a detailed description of 1. Discard the fractional part and keep the integer part parseint (5/2)
JavaScript has scope (scope), scope chain (scope chain), execute context (execution contexts), active object (active objects), dynamic scope (animated scope), Closure ( Closure) These concepts, to understand these concepts, we from the static and
This article mainly introduces the regular expression in JavaScript, summarizes the grammatical meaning and RegExp object in regular, and the friend who needs it can refer to the following I. Methods for defining regular expressions There are
This article is mainly on the JavaScript (JS) decimal Point Multiplication Division problem is introduced in detail, the need for friends can come to the reference, hope to help everyone else First, with JS calculation 12.32 * 7 The result is
Definitions and usage
The random () method can return a random number between 0 ~ 1.
Grammar
Math.random ()
return value
A pseudo random number between 0.0 ~ 1.0.
Open node, enter terminal command line mode, enter Math.random ():
EXEC () retrieves the specified value in the string, returns a value that is found, and returns null if no match is found: The main regexp pattern matching method is exec (), similar to the match method for the string object described in the
There are many operators in JavaScript, which are mainly arithmetic operators, equivalent to all the same operators, comparison operators, string operators, logical operators, assignment operators, and so on. These operators have some of their own
1.NaNIn JavaScript, Nan represents "not a number". This value is returned primarily when parsing a string error:
Copy Code code as follows:
> Number ("xyz")
Nannan
The name is "not a number", but it can also be said not to
Most languages provide bitwise operators, which are widely used in languages such as c,c++, while there are not many application examples in scripting languages such as Js,as, and the appropriate use of bitwise operators can be a good result.Below
Kitjs, (Http://xueduany.github.com/KitJs), is my end of 2011, after leaving Taobao ued, my own set of HTML5 front-end widget library, the original use of Spiker machine-side HTML page interaction components used, As the literal meaning of kit, the
1. Math Object
1.1 Introduction
The Math object, which is a mathematical object, provides a mathematical calculation of the data, such as acquiring absolute value, rounding up, and so on. No constructors, cannot be initialized, provides only
JavaScript has two very powerful and developer-favorite functions: Split and join two opposing functions. These functions allow string to be interchanged with array two types, that is, arrays can be serialized as strings, and vice versa. We can take
Module Creation Constructor (Modules that create constructors)
In the previous example, a MYAPP.utilities.array object was created, but sometimes it is more convenient to create your object using the constructor, and you can implement it using the
javascript| Functions | tutorials | strings
String functions that use JavaScript
String objects provide many methods, but few programmers make the most of them, which, for a programmer, cannot be said to be a flaw. Strings provide methods that can
javascript| encryption
is compared with Delphi implementation of MD5 encryption, English numerals are the same as the results of the encryption, Chinese is not the same, may be different from the processing of Chinese characters. The copyright
Web page Production WEBJX article introduction: for engineers who are familiar with C + + or the Java language, JavaScript is flexible, easy to understand, and relatively loosely formatted for code. It's easy to learn and apply to your own code.
Javascript| array JavaScript is inefficient in the cycle of large-capacity arrays, I've done a comparison, compared to the VBS array, the VBS's array cycle speed is roughly one order of magnitude faster than JS. JS arrays in general programming, we
JavaScript Learning Summary1.JavaScript is a programming language for Web and HTML.2.JavaScript code must be placed between tags, javascript is now the HTML default scripting language, so in There is no need to declare the scripting language as
PS: I first look at the discussion of the Masters, we have to read a lot of ~ others said: "I did not think the commentary on where to go, only the sense of fault." For example, synchronous asynchronous introduction, there is no big mistake, such
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.