jquery essentials miles 2016 01 30 Lập trình Java

320 18 0
jquery essentials miles 2016 01 30  Lập trình Java

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

Thông tin tài liệu

CuuDuongThanCong.com https://fb.com/tailieudientucntt CuuDuongThanCong.com https://fb.com/tailieudientucntt jQuery Essentials CuuDuongThanCong.com https://fb.com/tailieudientucntt Table of Contents jQuery Essentials Credits About the Author About the Reviewers www.PacktPub.com Support files, eBooks, discount offers, and more Why subscribe? Free access for Packt account holders Preface What this book covers What you need for this book Who this book is for Conventions Reader feedback Customer support Downloading the example code Errata Piracy Questions jQuery Part by Part Life before jQuery Why was jQuery created? The major components of jQuery The DOM selection DOM manipulation Events Form CSS and animation Ajax CuuDuongThanCong.com https://fb.com/tailieudientucntt Helpers Why are there two maintained versions of jQuery? The difference between minified and un-minified versions What is a content delivery network? Summary jQuery Selectors and Filters jQuery selectors The chapter code Protocol-relative URLs The jQuery object Creating selectors ID selectors Class selectors Tag selectors Combining selectors Descendent selectors Attribute selectors Creating basic filter selectors Content filters Using chaining to quickly and neatly continue queries Summary Manipulating the DOM Dimensions and positions Examples Developer tools Reading the size of the screen and elements Classes and styles The JSON object Behavior classes Attributes and properties Keeping images proportional CuuDuongThanCong.com https://fb.com/tailieudientucntt Removing attributes and properties Summary Events The ready event Hooking events Unhooking events Namespacing events The event handler The event object event.target event.relatedTarget event.type event.which event.metaKey event.pageX and event.pageY event.originalEvent Passing data to an event Event shorthand methods Creating your own events Triggering events The death of the live() and die() methods Looking deeper at on() Summary Making Your Site Snazzy with jQuery The importance of animations Hiding and showing elements fadeOut() fadeIn() fadeToggle() Sliding elements around slideUp() CuuDuongThanCong.com https://fb.com/tailieudientucntt .slideDown() slideToggle() Creating custom effects animate() delay() queue(), dequeue(), and clearQueue() stop() and finish() jQuery.fx.interval and jQuery.fx.off Using effects correctly Summary Better Forms with jQuery Employing form methods submit() focus() blur() focusin() and focusout() change() select() Tooltips Placeholder Enabling and disabling elements Validation Filtering out unwanted characters Summary Talking to Your Server Before jQuery How jQuery helps us Loading HTML – load() Loading JSON Data – getJSON() Loading and executing JavaScript – getScript() Reading and writing data: jQuery.get() and jQuery.post() CuuDuongThanCong.com https://fb.com/tailieudientucntt Helper methods Creating query data – $.param() Creating query data from a form – serialize() Creating an object from form data – serializeArray() Ajax events When an Ajax request begins – ajaxStart() When an Ajax request completes – ajaxStop() When an Ajax request sends data – ajaxSend() When an Ajax request fails – ajaxError() When an Ajax request succeeds – ajaxSuccess() When an Ajax request finishes – ajaxComplete() Summary Writing Code that You can Read Later Separation of concerns Breaking code into logical units Using events to decouple code Using unit tests Why write unit tests at all? Summary Faster jQuery Writing performance tests Measuring jQuery jQuery selectors Using IDs over other selectors Caching your selectors Optimizing selectors Right to left Reducing overly specific selectors Narrowing your search Other jQuery optimizations Updating to the latest version CuuDuongThanCong.com https://fb.com/tailieudientucntt Using the correct version of jQuery Don’t use deprecated methods Using preventDefault() when appropriate Never modify the DOM in a loop jQuery isn’t always the answer Using document.getElementById Using CSS Summary 10 Benefiting from the Work of Others with Plugins Finding plugins Installing plugins Updating a plugin Uninstalling plugins Adding a plugin jQuery UI jQuery UI Interactions jQuery UI widgets The jQuery UI widget factory Writing your own plugin Prep work The plugin Best practices Preserve chaining Use an IIFE Add only one function to jQuery Let the user theme it Test, test, test Document it Minify it Summary Index CuuDuongThanCong.com https://fb.com/tailieudientucntt CuuDuongThanCong.com https://fb.com/tailieudientucntt I ID selectors about / ID selectors CuuDuongThanCong.com https://fb.com/tailieudientucntt J jQuery.post() method / Reading and writing data: jQuery.get() and jQuery.post() Jasmine URL / Using unit tests JavaScript loading / Loading and executing JavaScript – getScript() executing / Loading and executing JavaScript – getScript() data, reading / Reading and writing data: jQuery.get() and jQuery.post() data, writing / Reading and writing data: jQuery.get() and jQuery.post() jQuery history / Life before jQuery purpose / Why was jQuery created? components / The major components of jQuery versions / Why are there two maintained versions of jQuery? uses / How jQuery helps us HTML, loading / Loading HTML – load() JSON data, loading / Loading JSON Data – getJSON() measuring / Measuring jQuery jQuery.fx.interval method / jQuery.fx.interval and jQuery.fx.off jQuery.fx.off method / jQuery.fx.interval and jQuery.fx.off jQuery.get() method / Reading and writing data: jQuery.get() and jQuery.post() jQuery API page URL / The major components of jQuery jQuery optimizations about / Other jQuery optimizations latest version, updating / Updating to the latest version correct version, using / Using the correct version of jQuery deprecated methods, avoiding / Don’t use deprecated methods preventDefault(), using / Using preventDefault() when appropriate DOM modification in loop, avoiding / Never modify the DOM in a loop jQuery selectors about / jQuery selectors, jQuery selectors chapter code / The chapter code protocol-relative URLs / Protocol-relative URLs jQuery object / The jQuery object creating / Creating selectors ID selectors / ID selectors class selectors / Class selectors tag selectors / Tag selectors combining / Combining selectors descendent selectors / Descendent selectors attribute selectors / Attribute selectors IDs, using over other selectors / Using IDs over other selectors CuuDuongThanCong.com https://fb.com/tailieudientucntt caching / Caching your selectors optimizing / Optimizing selectors reading, from right to left / Right to left overly specific selectors, reducing / Reducing overly specific selectors search, narrowing / Narrowing your search jQuery UI about / jQuery UI URL / jQuery UI interactions / jQuery UI Interactions widgets / jQuery UI widgets widget factory / The jQuery UI widget factory CuuDuongThanCong.com https://fb.com/tailieudientucntt L live() method / The death of the live() and die() methods load() method / Loading HTML – load() lorem pixel URL / Hiding and showing elements CuuDuongThanCong.com https://fb.com/tailieudientucntt M minified version, jQuery versus un-minified version / The difference between minified and un-minified versions Model-View-Controller (MVC) / Separation of concerns CuuDuongThanCong.com https://fb.com/tailieudientucntt N Node.js URL / Installing plugins CuuDuongThanCong.com https://fb.com/tailieudientucntt O on() method / Looking deeper at on() of-type selectors about / Content filters $first-of-type selector / Content filters $last-of-type selector / Content filters $only-of-type selector / Content filters CuuDuongThanCong.com https://fb.com/tailieudientucntt P $.param() method about / Creating query data – $.param() performance.mark() / Writing performance tests performance.measure() / Writing performance tests performance.now() / Writing performance tests performance tests writing / Writing performance tests jQuery, measuring / Measuring jQuery placeholder about / Placeholder plugins finding / Finding plugins installing / Installing plugins updating / Updating a plugin uninstalling / Uninstalling plugins adding / Adding a plugin CuuDuongThanCong.com https://fb.com/tailieudientucntt Q queue() method / queue(), dequeue(), and clearQueue() queries chaining / Using chaining to quickly and neatly continue queries CuuDuongThanCong.com https://fb.com/tailieudientucntt R ready event about / The ready event CuuDuongThanCong.com https://fb.com/tailieudientucntt S select() method / select() serialize() method about / Creating query data from a form – serialize() serializeArray() method about / Creating an object from form data – serializeArray() slideDown() method / slideDown() slideToggle() method / slideToggle() slideUp() method / slideUp() stop() method / stop() and finish() submit() method about / submit() separation of concerns (SoC) about / Separation of concerns showMeasurements() method / Writing performance tests CuuDuongThanCong.com https://fb.com/tailieudientucntt T tag selectors about / Tag selectors Test Driven Development (TDD) / Why write unit tests at all? tooltips about / Tooltips CuuDuongThanCong.com https://fb.com/tailieudientucntt U unit tests about / Using unit tests using / Using unit tests writing / Why write unit tests at all? unwanted characters filtering / Filtering out unwanted characters CuuDuongThanCong.com https://fb.com/tailieudientucntt V validation about / Validation CuuDuongThanCong.com https://fb.com/tailieudientucntt W W3C (World Wide Web Consortium) specification about / ID selectors W3C (World Wide Web Consortium) standards / Life before jQuery CuuDuongThanCong.com https://fb.com/tailieudientucntt ... Published by Packt Publishing Ltd Livery Place 35 Livery Street Birmingham B3 2PB, UK ISBN 97 8-1 -7 852 8-6 3 5-3 www.packtpub.com CuuDuongThanCong.com https://fb.com/tailieudientucntt CuuDuongThanCong.com... The difference between minified and un-minified versions What is a content delivery network? Summary jQuery Selectors and Filters jQuery selectors The chapter code Protocol-relative URLs The jQuery object... Joydip has authored more than 300 articles for some of the most reputable sites, such as www.msdn.microsoft.com, www.code-magazine.com, www.asptoday.com, www.devx.com, www.ddj.com, www.aspalliance.com, www.aspnetpro.com, www.sqlserver-performance.com, www.sswug.com, among others

Ngày đăng: 29/08/2020, 11:29

Mục lục

  • jQuery Essentials

  • Credits

  • About the Author

  • About the Reviewers

  • www.PacktPub.com

  • Support files, eBooks, discount offers, and more

  • Why subscribe?

  • Free access for Packt account holders

  • Preface

  • What this book covers

  • What you need for this book

  • Who this book is for

  • Conventions

  • Reader feedback

  • Customer support

  • Downloading the example code

  • Errata

  • Piracy

  • Questions

  • 1. jQuery Part by Part

Tài liệu cùng người dùng

Tài liệu liên quan