Regular Expressions are often used, but they are basically used to verify the rationality of a string. For example:
VaR M = "12345 ";
VaR n =/^/d + $ /;
If (N. Test (M) Alert ('OK ');
Today I have read an example about using regular expressions
// Basic data type, number, Boolean var I = 10; var B = true; function ischange_basic (Num, bool) {num = 15; bool = false; document. write (" Inner: I =" + num + "B =" + bool);} document. write ("basic type test "); document. write ("before: I =" +
Regular Expression
In JavaScript, there are two ways to use regular expressions. One is to create an instance of a regular expression, but to use the regular expression related methods in the string object.[Edit Regular Expression object] Regular
Common JS creation objects: var OBJ = new object; obj. name = "Goul"; obj. age = 22; obj. sex = "male"; obj. say = function () { alert ("My name is" + this. name) }; the following uses the Program as an example: 1. factory method:
Function resolvugcchar (STR ){For (I = 0; I VaR c = Str. charat (I );If (C = '? '| C = '? '| C =' & '| C =' | C = '>' | C = '\ ''| C = ''' | C =' \" '| C =' '| C = '"'| C = '@' | C = '#' | C = '\\'| C = '\/' | C = '$' | C = '\ ^'| C = ';' | C = ':' |
Keywords: Javascript
This is my first article. It is only used for testing. I just played with blog, so many things won't. So I picked the following article from csdn. Sorry for the offense.
---------------------------------------------
Data
[Note: The element name attribute on the page and the name referenced by JavaScript must be case-sensitive. Otherwise, an error message "the referenced element is null or not an object" is displayed.]==================================================
The following code is my test code, which is important:
/*global window,jQuery,validate_email,masterUI,$,rest*//** Enable ECMAScript "strict" operation for this function. See more:
Modular JavaScript writing is a good refactoring technology when Web Front-end programs are constantly expanding.
The following example has two modules,
The artdialog module relies on the jquery and jquery. artdialog libraries to provide the pop-up
2. function object)
@ Wu Qiong Adam (Sina Weibo)
Note: Before reading 2, read 1. Object: http://blog.csdn.net/adwu73/article/details/7219044
Function objects are first an object. Therefore, they also have _ PROTO _ links and delegation.
Javascript language essence and programming practices have been commercially available in online stores. For more information, see:
Rebuild the Green Book! Ecmascript 5th lecture!
Http://blog.csdn.net/aimingoo/article/details/7362552
Here are
4.9In programming languages, scopes control the visibility and lifecycle of variables and parameters. This is an important help for programmers because it reduces name conflicts and provides automatic memory management. Most languages that use the C
script 6.1 striped tables product Cost inventory status weight (in lbs.) ultra-glow hair spray $20.00 in stock . 5 anodyne 3000 $495.00 back order 350 Big Foot hair dryer $55.00 in stock 2 cat out of the hat $15.00 back
Someone has asked me if I can obtain the information of the function caller in Javascript, that is, I need to know the function that calls a function. At that time, I thought that since there is arguments. callee in the function, is there arguments.
Http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd> JS News Text tumble effect [recommended] jquery does not need to change the style of the CSS style sheet. algorithms used by VC ++ to generate random numbers and quickly sort them jquery-based
Weak variables: when defining a variable in JS, you do not need to specify the type of the variable. You only need to define a variable. But when defining variables, the programmer must be aware of the larger data type. And do not change the
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