Selecting a group of DOM elements is super duper easy these days using CSS selectors, or a particular element via their ID. But what about picking up a random element from these group of elements? In this article I am going to show you how to do it by extending jQuery Let’s consider that we … Continue reading Picking up random elements from DOM using jQuery
When it comes to attaching event listeners, be it a particular element in the DOM, or a group of elements via CSS selectors, most of us bind the event listener directly to the elements. Direct binding is fine when you’re doing for a PARTICULAR element, but it may create problems for a group of elements … Continue reading Delegating Events Instead of Direct Binding in DOM
Our goal is simple today, we want to add interactivity to our boring metaboxes. Instead of showing lots and lots of irrelevant input boxes at once, we will properly group them into different metaboxe containers and then display the required one based on the action of another one. We will create a custom post called … Continue reading Improving UX in the WordPress Admin Panel with Interactive Meta Boxes
Check it out here: http://hasinhayder.github.io/essential-jquery-plugins/ I have started curating this list for last couple of weeks and the purpose is to create an one stop place where you can look for the essential jQuery plugin for your project and look no where else. Honestly, sometime it’s really hard to find the perfect plugin in this … Continue reading The Badass List of Essential jQuery Plugins
Webkit browsers, specially in Mac osx hides the scrollbar intelligently when not in use. This feature improves the look-n-feel. But for the designers, sometime this can be a pain because they may need to alter the designs based on the visibility of scrollbar. Here goes two simple jQuery plugin which can detect the visibility of … Continue reading Detecting if a DOM element has visible scrollbar.
Before jumping into the details, let me hear you asking “WHY?”. To be honest, not all of you will need to detect the mouse inactivity in your web applications. But sometime, it’s useful to do something different after a certain period of inactivity either to grab attention of the viewer, or to help him by … Continue reading LazyMouse jQuery Plugin – detect mouse inactivity easily 🙂