User : 1man
![]() |
Title | User | Language | Tags | Description | Date |
|---|---|---|---|---|---|---|
|
Simple button fade transition | 1man | CSS | buttonfadetransition | On hover the button will have a smooth transition to the hover colour, then fade out on mouse out. |
May 23 |
|
Switch using an Object | 1man | JavaScript | flow | Using an object as a simple switch. |
April 27, 2011 |
|
Store the relationship between elements using .data() | 1man | jQuery | relationship | Very useful snippet to link elements together. |
April 27, 2011 |
|
Check to see if function triggered by an event | 1man | jQuery | trigger | Rather that using $(element).trigger('click'), check to see if execute has come from an element rather than directly. |
April 27, 2011 |
|
Vertically centre a menu without setting an explicit width | 1man | CSS | centre | Useful bit of CSS to vertically centre a navigation. Good for Pagination. |
February 3, 2011 |
|
Validate an age using jQuery Validator plug-in | 1man | jQuery | AGE | Useful snippet i found on a forum, use it to check to see if a user is old enough to submit a form. |
October 28, 2010 |
|
Module layout in JavaScript | 1man | JavaScript | global | Simple illustration of structuring your JavaScript and minimising your use of global vars. |
August 24, 2010 |
|
Exceptions in JavaScript | 1man | JavaScript | exception | An example taken from JavaScript: The good parts showing how to catch an exception. |
August 23, 2010 |
|
Simple jQuery plugin layout + how 'this' works | 1man | jQuery | sample | Simple plugin to demonstrate how the 'this' keyword is used. Plugin also allows chaining via the 'return' |
January 13, 2010 |
|
Cache files with jQuery and ajax method | 1man | jQuery | cache | Handy little snippet i found in 'jquery enlightenment' for caching certain selected files. Could be useful for larger files later on in a site. |
January 13, 2010 |
|
Simple jQuery page scroller | 1man | jQuery | jquery | Example in 'jQuery enlightenment' Simple way to jump smoothly down the page without the use of a plugin. |
January 12, 2010 |
|
Custom jQuery selector | 1man | jQuery | expr | Example given in the book jQuery Enlightenment. Create your own custom selectors in jQuery and manipulate as usual. |
January 11, 2010 |
|
jQuery and Yahoo pipes simple ajax call | 1man | jQuery | pipes | Very simple example of pulling in a JSON feed from Yahoo pipes using jQuery. |
November 13, 2009 |
|
Function Timing Example (includes jQuery) | 1man | jQuery | timing | A way to time how long it takes to get through a certain block of code. Good way to measure performance on the page. You could also use the built in logging functions in firebug. Not sure how they would tally up in a test. |
July 3, 2009 |
|
Add class of 'last' to every 3rd image | 1man | jQuery | columns | Quick little clientside script to pick out every 3rd image and add a class of last to it. I needed this because the images were layed out in 3 columns, adding a margin to the right hand side would leave a large gap on the right hand side which i didn't want. This now allows me to remove the margin for the last image. |
June 14, 2009 |

