/* Copyright (c) 2007 Yves ASTIER (yves.astier@hotmail.fr)
 * Licensed under GPL (http://www.opensource.org/licenses/gpl-license.php)
 * Use only for non-commercial usage.
 * Usage autorisé uniquement dans un cadre non-commercial.
 *
 * Version : 1.0
 *
 * Requires: jQuery 1.2+
 */
(function($){$.fn.CheckImg=function(i0,i1){var ia=new Array(i0,i1);$(this).attr('style','display:none;visibility:hidden;').each(function(){this.c=$(this).attr('checked')==true?1:0;}).after('<img />').next().each(function(){$(this).attr('src',ia[this.c=$(this).prev()[0]['c']]);d($(this),'title');d($(this),'alt');d($(this),'class');}).bind('click',function(){this.c=this.c?0:1;$(this).attr('src',ia[this.c]);$(this).prev()[0].checked = Boolean(this.c);});},d=function(o,b){var a=o.prev().attr(b);o.attr(b,a==null?'':a);}})(jQuery);