Javascript to obtain the current date and time and other operation functions

MyDate. getYear (); // obtain the current year (2 digits)MyDate. getFullYear (); // obtain the complete year (4 bits, 1970 -????)MyDate. getMonth (); // obtain the current month (0-11, 0 represents January)MyDate. getDate (); // obtain the current

Code for Asynchronously loading scripts

Asynchronously load scripts using iframeThe script that requests another page asynchronously is not executed. Only the original html file is returned because the returned text is not parsed by the browser.View codeA1.htmlCopy codeThe Code is as

JavaScript agrees to wait for code implementation

The correct source code is as follows:Copy codeThe Code is as follows: I define var btnReg = document. getElementById ("btnReg") in the fourth line as the global variable btnReg = document. getElementById ("btnReg ");Besides the function abc (), the

The message box is displayed in the lower right corner of the message plug-in based on jQuery.

1. $. messager. lays (width, height ); This method is mainly used to define the width and height of the pop-up window. 2. $. messager. anim (type, speed ); This method mainly defines the mode and speed at which the window is displayed. $. Messager.

Jcarousellite. js Jquery-Based Seamless image scrolling plug-in

1. Introduce the JS library, jquery. js script, and plug-in script jcarousellite. js.Copy codeThe Code is as follows: 2. HTML structure div> ul> li> img to be displayed, with clear structureCopy codeThe Code is as follows: 3. Execute the

Three common methods for creating objects in javascript

Three methods for creating an objectMethod 1:Copy codeThe Code is as follows:Var obj = new Object ();Obj. Property = value;// Continue adding other attributesObj. method = function (parameter ){// Function Code}// Continue adding other methods

Learning notes written by someone while learning javascript

Copy codeThe Code is as follows:/** JavaScript objects are a set of attributes (methods ).* If the variable or method name does not comply with the Declaration Rules in this language,* You must reference it with square brackets [].**//*** This

JQuery Study Notes [1] DOM operations in jQuery

DOM is divided into three aspects, namely DOM Core, HTML-DOM, CSS-DOM.1. DOM Core is not specialized in JavaScript. It can be used by any programming language that supports DOM.GetElementById (), getElementsByTagName ()... and other methods in

Js Code that counts the maximum number of characters

Apply the global match of the regular expression to match the number of occurrences of the character. Compare these occurrences to save the maximum number and return it. The Code is as follows:Copy codeThe Code is as follows:Var countMost = function

Jquery implements the mental computing exercise code

Online demonstration:Http://demo.jb51.net/js/jquery_xinsuan/index.htmThe Code is as follows:Copy codeThe Code is as follows: mental computing exercise, Do Your Best timing: 00 : 00 : 00 Score: During code implementation, there are two

Color Picker, IE, Firefox, Opera, Safar

From: color selector colorpickerHttp://jscolor.com/Http://dematte.at/colorPicker/Http://www.free-color-picker.com/color-picker-samples.phpHttp://www.nogray.com/color_picker.phpHttp://www.mattkruse.com/javascript/colorpicker/ColorPicker2.js

Javascript table left and right shrinking

left and right tables col1 col2 col3 col4 col5 col6 col7 col8 col9 col10 [Ctrl + A select all Note: If you need to introduce external Js, You need to refresh it to execute]

Javascript to get content in Table td

1 2 3 > 4 5 6 7 8 9 10 11 12 [Ctrl + A select all Note: If you need to introduce external Js, You need to refresh it to execute]

Javascript character Escape, encodeURI, encodeURIComponent

Escape () method: The specified string is encoded using the ISO Latin character set. All space characters, punctuation marks, special characters, and other non-ASCII characters will be converted into character encoding in % xx format (xx equals to

Javascript Verification Code Generation Code Recommendation Learning

javascript verification code implementation _ script home test [Ctrl + A select all Note: If you need to introduce external Js, You need to refresh it to execute]

Javascript code for scrolling between the left and right sides of the screen

Copy codeThe Code is as follows: code for scrolling between the left and right sides of the screen Package download

Use WebBrowser to completely solve Web printing problems (including background printing)

With the idea of "serving the public and serving the public", I summarized it and shared it with you online, hoping to help friends who encounter similar problems.I mainly use the WebBrowser control built in IE, which does not need to be downloaded

Size of the image file read by javascript

As follows:Copy codeThe Code is as follows:Function checkAttachment (){Alert ("here ");Var attachmentArray = document. getElementsByTagName ("input ");Var attachmentSizeArray = document. getElementsByName ("fileMaxSize ");Var index = 0;For (var I = 0

JavaScript code for css operations

When we need a rule, we cannot perform this operation every time the dom changes. Otherwise, it is too inefficient.Fortunately, css rules in dom can also be modified. However, different browsers have different descriptions of css rules interfaces.

JQuery Jcrop plugin for image Cropping

Results:Please "run the code" first and refresh it once. Feel the following: script home [Ctrl + A select all Note: If you need to introduce external Js, You need to refresh it to execute]Currently, the user avatar function is used in this

Total Pages: 5378 1 .... 4274 4275 4276 4277 4278 .... 5378 Go to: GO

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.