background preloader

JS / JS LIB / JQuery

Facebook Twitter

Slick - the last carousel you'll ever need. Set up your HTML markup.

slick - the last carousel you'll ever need

<div class="your-class"><div>your content</div><div>your content</div><div>your content</div></div> Move the /slick folder into your project Add slick.css in your <head> <link rel="stylesheet" type="text/css" href="slick/slick.css"/> // Add the new slick-theme.css if you want the default styling <link rel="stylesheet" type="text/css" href="slick/slick-theme.css"/>

JavaScript toFixed() Method. jQuery API Documentation. jQuery Learning Center. Javascript Cheat Sheet. Basic Objects Math Methods DOM Events Event Object Constant Event Object Methods initEvent() preventDefault() stopPropagation() EventTarget Object addEventListener() dispatchEvent() removeEventListener() EventListener Object handleEvent() MouseEvent/KeyboardEvent Methods initMouseEvent() initKeyboardEvent() DOM Node Node Types Element1 Attr2 Text3 CDATASection4 EntityReference5 Entity6 ProcessingInstruction7 Comment8 Document9 DocumentType10 DocumentFragment11 Notation12 nodeName Returns Element element name Attr attribute name Text #text CDATASection #cdata-section EntityReference entity reference name Entity entity name ProcessingInstruction target Comment #comment Document #document DocumentType doctype name DocumentFragment #document fragment Notation notation name nodeValue Returns RegExp Modifiers i Perform case-insensitive matching g Perform a global match (find all matches rather than stopping after the first match) m Perform multiline matching Brackets Metacharacters .

Javascript Cheat Sheet

Quantifiers Core DOM length Ad. jQuery, remplir une liste déroulante selon une autre liste – chez Syl. Dynamic Dependent Select Box using Jquery and Ajax. How to do dynamic dependent select box using Jquery, Ajax, PHP and Mysql.

Dynamic Dependent Select Box using Jquery and Ajax

Dependent select box when a selection is made in a "Parent" box it allow to refresh a "child" box list data. In this post I had given a database relationship example betweent "catergory" and "subcategory". It's very simple jquery code hope you like this. Download Script Live Demo Database Sample database tables.

CREATE TABLE 'data' ( 'id' int primary keyauto_increment, 'data' varchar(50), 'weight' int(2), ); CREATE TABLE `data_parent` ( `pid` int(11) primary key auto_increment, `did` int(11) unique, `parent` int(11),Foreign key(did) references data(id) ) Data storing like this.data data_parent sections_demo.php Contains javascipt and PHP code. $(".country").change(function(){}- country is the class name of select box. <script type="text/javascript" src=" type="text/javascript"> $(document).ready(function() { $(".country").change(function() {var id=$(this).val();var dataString = 'id='+ id; <? EncodeURIComponent() Examples - Select2. Single select boxes Select2 can take a regular select box like this... and turn it into this...

Examples - Select2

Alaska Multiple select boxes Select2 also supports multi-value select boxes. Select boxes with labels You can, and should, use a <label> with Select2, just like any other <select> element. A placeholder value can be defined and will be displayed until a selection is made. Select a state In addition to handling options from a standard <select>, Select2 can also retrieve the results from other data sources. Loading array data Select2 provides a way to load the data from a local array. Enhancement duplicate Loading remote data Select2 comes with AJAX support built in, using jQuery's AJAX methods. Select2/select2 When using Select2 with remote data, the HTML required for the select is the same as any other Select2. You can configure how Select2 searches for remote data using the ajax option. Select2 will pass any options in the ajax object to jQuery's $.ajax function, or the transport function you specify. AngularJS — Superheroic JavaScript MVW Framework.