jQuery is a fast and concise JavaScript Library that simplifies HTML document traversing, event handling, animating, and Ajax interactions for rapid web development.
jQuery form submit error detection
20 Dec, 2017
Snippet shows you how to catch errors like 404 when you submit form using jQuery.
jQuery: Using selectionStart, selectionEnd, setSelectionRange
21 Jun, 2016
Using selectionStart, selectionEnd, setSelectionRange in jQuery example. You can't use DOM commands on jQuery objects directly, you have to get the first value of the object.
jQuery: Input - focus and select all
18 Apr, 2016
How to focus and select all using javascript. This snippet shows it in an example of "jQuery: Toggle input text using checkbox". For an example you can extend this to any event or action where you...
jQuery: Toggle input text using checkbox
18 Apr, 2016
Snippet shows how to toggle input text using checkbox. Sometimes you need to show text field only when a checkbox is checked, that can be called conditional text field. So you need a checkbox and a...
jQuery: Run something after $.each has completed
12 Apr, 2016
JavaScript runs asynchronously, that means when you initialize $.each every bit of code that comes after that will not be executed when $.each has finished. Sometimes you need your code to be...
Uncaught TypeError: Cannot read property 'msie' of undefined
29 Jan, 2015
I had an error in "jquery.ui.mouse.min.js" when using jQuery 1.9 (or newer) with jQuery UI 1.8 (or older). This jquery plugin is used to restore deprecated functionalities in jQuery and removed as of...
Embed PDF in HTML
24 Oct, 2014
In general we are going to embed pdf in html. For this tutorial I am going to use PDF.js. It is a web platform for parsing and rendering PDF files. Canvas support is one of the main things that is...
Check if variable is a jQuery object
2 Jan, 2014
Checking that variable is a jQuery object. We are going to use instanceof and it returns true if the statement is true.
jQuery Catch Form Submit
29 Oct, 2013
Form submitting is really simple with jQuery. You can use submit function to submit form or catch a form submission and do something else.
jQuery - Animate .prepend
2 Feb, 2013
Rather than simply dumping the HTML into the page you might want it to be animated. You can .hide() the content before doing a .prependTo(), then call .slideDown() on the element.
Get date on mouseover from cell in jQuery UI datepicker
14 May, 2012
This snippet shows you how to get date on mouseover from cell in jQuery UI datepicker.
Get current URL using jQuery
5 Apr, 2012
This shows you how to get the path of the current URL and assign it to a variable. This is achieved by taking url from location object. The location object also has other properties, like host, hash...
Checkboxes as radio buttons using jQuery
4 Dec, 2011
Make a group of checkboxes behave like radiobuttons.
jQuery send form via AJAX using post method
29 Jun, 2011
This snippet sends form with id contactform using ajax via post method. When it's send and result is returned. It writes result into #feedback-form.
Always have latest jQuery version
29 Jun, 2011
To always have latest jQuery version, you can use this fast loading jQuery library from Google.
Get and save jQuery window scroll position
24 May, 2011
Getting and save window scroll position with jQuery. You also need cookie plugin to store the position value in cookies, so it can be used after browser page changes.
Get text area value or text with jQuery
29 Apr, 2011
This snippet shows how to get html element textareas value or text with jQuery.
Searchbox Background Text with jQuery
24 Feb, 2011
This tutorial shows how to create background text to your search box that will dissapear on click/focus.
jQuery - Send Single Form Field via Post on Blur
19 Feb, 2011
This tutorial shows how to send a single form field/input of a form. We are going to use jQuerys ajax features to do that.
Get Values of Checkboxes Group with jQuery
9 Feb, 2011
This tutorial shows you how to get values of checkbox array using jQuery. You can use this to send selected checkboxes values with ajax or add those to url variable(like in this example). If you...
jQuery Change Image src Attribute
4 Feb, 2011
You can use these examples to change img tags src attribute or any attribute of any tag.
Add Form Fields With jQuery
26 Aug, 2010
This tutorial is about adding form fields, more precisely how to add textboxes dynamically with JavaScript. To make the code easier I use jQuery library.
Popup Contact Form With jQuery UI
25 Jul, 2010
Making beautiful pop-up contact form with jQuery and jQuery UI. If JavaScript is disabled the form is usual.
jQuery: Create a function
5 Jul, 2010
Tutorial about creating your own functions using jQuery JavaScript library.