First Type:With the flag identification, the following code sets the CHECKSUBMITFLG flag:
Copy Code code as follows:
Because the program source code with the WIN2000 registry conflict, Post issued will appear invalid page,
Let me briefly explain the process and principle.
First step: Implement an anonymous function and execute it yourself.
Copy Code code as follows:
(function () {}) ()
This function is often met in the same good JS code as the
On many websites we find that when the mouse is over a picture, the picture is switched to another one. Here is a small story about how this is achieved.
We have to have the experimental HTML code before writing the JavaScript code.
Copy
Copy Code code as follows:
#topmenu {position:absolute;top:100px;background: #4b4a4a; width:100%;margin:0 Auto;clear:both;overflow:hidden; z-index:998;left:0}
The effect chart is as follows:
This approach can be common, and often used in project development:
Copy Code code as follows:
W: Wide, H: High, url: address, Tag: tag
function Showwin (w, h, URL, tag) {
var t = (screen.height-h)/2; From the top of the distance
var
method One: Regular Analysis method
Copy Code code as follows:
function getquerystring (name) {
var reg = new RegExp ("(^|&)" + name + "= ([^&]*) (&|$)", "I");
var r = window.location.search.substr (1). Match (REG);
if (r!=
For example:
Copy Code code as follows:
var date1 = new Date ("2013-11-29");
var date2 = new Date ("2013-11-29");
Console.log (date1 = = Date2); False
Here, Date1 and Date2 look the same, but running date1 = = Date2 returns
First type:
Copy Code code as follows:
The second type:
Copy Code code as follows:
The third type:
Copy Code code as follows:
The fourth kind:
Copy Code code as follows:
Copy code code as follows:
/**
* Insert a string into the input field (cursor location)
* @param $t document.getElementById (' FieldID ')
* @param myvalue the value to insert
* *
Function Addsplittofield ($t, Myva
Collect a function: Get random color values
Copy Code code as follows:
function Getrandomcolor () {
Return "#" + ("00000" + (Math.random () *16777215+0.5) >>0). ToString (()). Slice (-6);
}
Description
1, 16777215 for 1
Copy Code code as follows:
Eval is the value that computes the string "can put any JS code"
1,
var str1= ' 12+3 ';
eval (str1);//15
2,var str2= ' [1,2,3] ';Eval (str2[0]);//1
3,Eval (' Alert (' abc ') ');/eject ABC
4,var
Copy Code code as follows:
Please select
Taiwan
Malaysia
Beijing
Shanghai
Tianjin
Chongqing
Hebei province
Shanxi Province
Liaoning Province
Jilin Province
Heilongjiang Province
When choosing "female", show "beauty, talented Woman"; hide the aspx page content when you select "Male":
Copy Code code as follows:
use Radiobutten (or checkbox) to realize the display and hiding of Div
Man
Female--%
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