The common left navigation effect _javascript skill of JS implementation

The common left navigation effect, JS simple, in order to improve the performance of navigation, you can refer to the application. Effect Display: Html: Copy Code code as follows: Apparel bags Women's Men's Children's

The example code _javascript skill of JS operation database

First, create a SQL Server databaseBuilding a library: testBuild table: Copy Code code as follows: /* Navicat MySQL Data Transfer Source Server:localhost Source Server version:50520 Source host:localhost:3306 Source Database:mo

jquery implements the tab effect to specify the default display page _javascript tips

You can specify the default display page in the code Copy Code code as follows: One Two Three jquery Focus map Slideshow JS and other kinds of code Copy Code code as follows:

_javascript tips for restricting the length of a TextBox or textarea input characters to a JS code

Copy Code code as follows: Then set the multiple-line textbox or textarea 2 properties. Onkeypress= "Javascript:setmaxlength (this,100);" Onpaste= "limitpaste (this, 100)" Now, you can automatically distinguish between Chinese and English,

The concrete realization _javascript skill of the parent element and the child IFRAME acquiring variables and element objects mutually

The parent: Copy Code code as follows: ------------------------------------------------------------- In the sub iframe: Copy Code code as follows: --------------------------------------------------

JS Implementation Click a label when the background to replace _javascript tips

Copy Code code as follows: 1 In the Alabel.js: Copy Code code as follows: Window.onload = function () { var Aspan = document.getElementsByTagName ("span"); var i = 0;

JS Operation Cookies Small Example _javascript skill

Copy code code as follows: Cookie = {     setcookie:function (name, Val) {   ;       var exp = new Date ();         exp.setdate (exp.getdate () + 600 * 1000);         document.cookie = name + "=" + Escape (val) + ";

Get the Background-image attribute _javascript skill of div through JS

Didn't notice the background-image of Div before this attribute, just set its URL, today encountered a problem to do a record. Copy Code code as follows: In JS to get the Image property Copy Code code as follows:

Simple solution for browser-compatible console objects sharing _javascript tips

The browser report cannot find the console object, so we manually construct a console object with exactly the same interface in the window. Empty methods and empty objects are used here. So even in the very old browser, the code containing

Native JS implement code _javascript techniques for adding favorites

Copy Code code as follows: js Add Favorites Join collection!

Change the style of the file field to realize the same time compatible with IE, firefox_javascript skills

Copy Code code as follows: Ideas: 1, the stubborn file domain is Transparency: style= "-moz-opacity:0;filter:alpha (opacity=0); opacity:0;" 2, with a text box and buttons in place of the file and the appearance 3. Put

Two div side by side to display and achieve click on the title toggle content _javascript Tips

Copy Code code as follows: Tab Home Hey, ignore div original class value. Test continues to disregard H3 original class values. Boredom Silly egg div can be ~ without a value. Home hehe, ignoring

Simple and beautiful JS window can be freely dragged and compatible with most browser _javascript tips

Simple and beautiful JS window-free Drag Copy Code code as follows: Simple and beautiful JS window-free Drag Hint information Tips Today seconds Kill sold out Confirmation Cancel

ie in JS create a CheckBox default selection problem Explore _javascript tips

Test Browser: IE8 (compatible and incompatible mode), Ff6. Copy Code code as follows: var chk = document.createelement ("input"); Chk.setattribute ("Type", "checkbox"); Container.appendchild (CHK); Chk.setattribute ("Checked", true);

JS Dynamic Add event and can pass parameter sample code _javascript tips

Copy Code code as follows: var tt=function (obj) { return function () { alert (obj.tagname); An execution function that can be defined externally; } } function AddFunction () { var Bigobj=document.getelementbyid ("MyTable")

JS operation Cookie Write and read instance code _javascript tips

Write Cookie instance! Copy Code code as follows: var u = "value=123"; Document.cookie = u; Read the cookie instance to read the value! Copy Code code as follows: var c_name= "value"; Variable name if

JS to achieve click on the picture on the current page to enlarge and can be turned off beautiful effect _javascript skills

Lightbox JS is a simple and humble script for overwriting a picture on the current page. It can be quickly installed and works in all popular browsers. Click here to view example demo How to use: Step 1-Install 1, Lightbox v2.0 use Prototype

JS page Jump Common methods of finishing _javascript skills

Copy Code code as follows: Button type: Copy Code code as follows: LINK Type: Copy Code code as follows: Back to the previous step " > Back to Previous step Direct Jump

Total Pages: 64722 1 .... 44716 44717 44718 44719 44720 .... 64722 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.