Snippets v2

Languages
My Snippets

jQuery: Attaching Functions to Dom Nodes Login or Register to Bookmark this snippet

Description Javascript

Attaching Functions to Dom Nodes

The Code Download
  1. $('p').data('lert', function () {
  2.     alert('I\'m attached to a node!');
  3. });
  4.  
  5. $('p').data('lert')();
Credits Contact JC

Added by JC on 20th October, 2009

Comments

There are no comments about this snippet.

Post Comment HTML is allowed

You must be registered and logged in to post a comment.

Login here to post a comment