Category : jquery

HTML5 Using FileReader to Preview Front-end Pictures How to get all checkbox in the page? (No Third Party Framework) JavaScript Template Engine Instances Javascript Implement JS function overload JS Cross Browser Binding Event Function JS monomer mode Object method defined using prototype property Closure Implements Result Caching Closures Implement Encapsulation Closures Implement Classes and Inheritance ..

Read more

JQuery learning notes Most of jQuery’s functions need to work according to the DOM model of the document. First, it needs to correctly parse the DOM model structure of the entire document. Using jQuery requires the entire document to be fully loaded by the browser before it can be started. $(document).ready(function () { alert(“Hello World!”); ..

Read more

Links:JQuery selector Basic selector Basics *Select all elements .classchooseclassFor example:$(‘.mybox’) elementchooseelementFor example:$(‘p’) #idchooseidFor example:$(‘#box’) selector1,selectorNYou can select multiple elements at the same time, such as:$(‘div, p.box, #phone’) Hierarchy selector parent > childSelect the specified child element under the specified element, such as:$(‘ul.tonav > li’) ancestor descendantSelect all descendant elements in an element, such as:$(‘form input’) ..

Read more

Original link:Front-end plug-in librarySites:Front-end development documentBlog:Front-end plug-in library Front-end plug-in library DataTables Official website:https://www.datatables.net/ DataTables is a JavaScript function library of jQuery. Its purpose is to strengthen table operations (such as searching and sorting) and automatically add components into tables. It is very flexible and easy to use. LazyLoad Official website:Lazy LoadExtension:Vanilla JavaScript Lazy Load ..

Read more

Js and css introduced <link href=”css/prettyPhoto.css” rel=”stylesheet”/> <script src=”js/jquery.prettyPhoto.js”></script> Events <a href=”#” rel=”prettyPhoto” title=”bpm image” style=”display:none”></a> Set up <script type=”text/javascript”> $(document).ready(function(){ $(“a[rel^=’prettyPhoto’]”).prettyPhoto({ theme:’light_square’, //’dark_rounded’ show_title: false, social_tools: false, keyboard_shortcuts: true }); }); </script> Trigger You can bind yourself to a button’s click event. <script type=”text/javascript”> function viewPng(){ var png = ‘xxx.png’; $.prettyPhoto.open(png); } </script> References ..

Read more

Quote <link href=”css/jBootstrapPage.css” rel=”stylesheet”/> <script src=”js/jBootstrapPage.js”></script> Configuration <div> <ul class=”pagination”></ul> </div> <script type=”text/javascript”> var totalCount = 1; $(function(){ renderPage(1,1,totalCount); }); function renderPage(pageSize,selectedPageNo,total) { $(“.pagination”).jBootstrapPage({ pageSize : pageSize, total : total, maxPageButton:total/pageSize+1, lastSelectedIndex : selectedPageNo, onPageClicked: function(obj, pageIndex) { //ajax get page data getData(page,size); } }); } </script> Use function getData(page,size) { var data = {“keyword”: ..

Read more

What I think is to use the perspective attribute of css3 to tilt the Y axis, but this does not have the effect of moving left and right. I don’t know if there is a better method or plug-in.Original address:http://sucai.epweike.com/js/texiao/tupian/1003.html I wrote one myself, and I don’t know if it is the effect you want.IE10加 ..

Read more

Is there any other implementation method besides activex provided by ie? I am developing a question bank. Only include judgment, single selection and multiple selection. Stand-alone operation, no networking required, cross-browser capability) Since I am not a computer major, I plan to use a simple jquery and html to complete it. Now I want to ..

Read more

The following code, click once to the left, and then click again after the completion of no problem, if the point has been, faster, can run after the end, how to deal with this, whether should let the click after the execution can click again, how to write http://jsfiddle.net/N72mP/1/ <div class=”cover no-select”> <ul style=”left:226px;” class=”cover-imgs”> ..

Read more