All Levels

Accessible Showing and Hiding

Editor’s Note: When I started this blog nearly three years ago, one of the first things I did was write a series on showing and hiding elements on a page. The posts were very basic, as was my knowledge at the time. At best, they demonstrated an incomplete answer to the question of how to […]

Flip your Tip: Keeping the Event-delegation Tooltip in View

Before we begin, please accept my apologies for not posting this tutorial sooner. I know at least two or three people were beginning to wonder if I’d ever finish what I started with this tooltip series. Please also forgive me if the phrase “flip your tip” has a double meaning in some ultra-hip corner of […]

Detecting Ajax Events on the Server

When working with an Ajax-enhanced website, it’s generally a good idea to provide a regular request fallback for any core functionality of the site. When you work to ensure that a fallback is in place, you will be faced with determining when a particular request is an Ajax request or just a normal page request. […]

Using Delegate and Undelegate in jQuery 1.4.2

As some of you have heard, there have been two new methods added in jQuery 1.4.2, .delegate() and .undelegate(). These methods achieve the same thing as the .live() and .die() methods, they just use a different syntax. For those new to .live(), it’s a method in jQuery that allows you to attach events to elements […]

Using setTimeout to Delay Showing Event-Delegation Tooltips

In my last two tutorials, I explained how to use event delegation for showing and hiding tooltips. In a comment on the first one, Jan Aagaard asked how we might go about enhancing the script by adding a small delay before showing a tooltip. The answer lies with two JavaScript functions, setTimeout() and clearTimeout().

Binding Multiple Events to Reduce Redundancy with Event-Delegation Tooltips

Last time I showed how to use event delegation to create a simple tooltip for a huge number of elements without running into the problem of binding an event handler to all of those elements. In this tutorial, I’m going to refine that tooltip script a bit, avoiding some code repetition and fixing a bug […]

Responsive Menu
Add more content here...