Some Useful JavaScript & jQuery Snippets - Part 2

Development

Check if cookies are enabled $(document).ready(function() { var dt = new Date(); dt.setSeconds(dt.getSeconds() + 60); document.cookie = "cookietest=1; expires=" + dt.toGMTString(); var cookiesEnabled = docu... read more

January 7, 2010 by cody 33 Comments »

Pause and Play Effect with jQuery

Development

Here's an effect based on the one used in fml to stop and pause an event. The idea is that when we click on the play/pause button or press the space button, an image (play or pause) appears and fade... read more

January 7, 2010 by cody 3 Comments »

Some Useful JavaScript & jQuery Snippets

Development

How to refresh the src of an image with jQuery? $(imageobj).attr('src', $(imageobj) .attr('src') + '?' + Math.random() ); How to see if an image is loaded or not with jquery var imgsrc = 'img/image1.png'; $('&l... read more

January 5, 2010 by cody 18 Comments »

Scrolling to the Top and Bottom with jQuery

Development

Here's a way to scroll to the top or bottom of your website with a simple click. I have used the jQuery special scroll events from James Padolsey, and some few extra lines of jQuery. There are two buttons with fixed position o... read more

January 3, 2010 by cody 12 Comments »

PrettyNumber - A jQuery Plugin for Formatting Numbers

Development

Here's a jQuery plugin that transforms a number into a human readable format. This plugin formats a number like 23454321234 into 23.454.321.234 . You can use different delimiters like the comma, dot, space or anything you spec... read more

January 3, 2010 by cody 1 Comment »

Clothesline Social Bookmarks – A CSS-only Social Bookmarking Tutorial

Tutorials

Today we will create a fancy social bookmarking solution which will not require any JavaScript - it is only CSS based. We will hang up some rotated social bookmark icons on a clothesline and put a cute Tweetie sitting on to... read more

January 2, 2010 by Mary Lou 17 Comments »

Easy PHP Site Translation

Development

Here's an easy way to translate your web site using PHP. The idea is to have several files for each language you want to provide. Each one of these files have the name of the ISO code and the txt extension. For this demo I onl... read more

December 30, 2009 by chadking 9 Comments »

Creating a Rotating Billboard System with jQuery and CSS

Tutorials

Currently we are in the "hey, let's do that flash thing in jQuery"-mood and so we came up with another idea: a rotating billboard system. In this tutorial we will use some images, CSS and jQuery ... read more

December 16, 2009 by Mary Lou 43 Comments »