﻿/*
 * jQuery Form Example Plugin 1.4.1
 * Populate form inputs with example text that disappears on focus.
 *
 * e.g.
 *  $('input#name').example('Bob Smith');
 *  $('input[@title]').example(function() {
 *    return $(this).attr('title');
 *  });
 *  $('textarea#message').example('Type your message here', {
 *    className: 'example_text'
 *  });
 *
 * Copyright (c) Paul Mucur (http://mucur.name), 2007-2008.
 * Dual-licensed under the BSD (BSD-LICENSE.txt) and GPL (GPL-LICENSE.txt)
 * licenses.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 */


(function($) {

    $.fn.dynamicImage = function(options) {
            options = $.extend({
            mouseoverImg: '',
            mouseoutImg: ''
            }, options);

            $(this).mouseover(function() {
                $(this).attr('src', options.mouseoverImg);
            }).mouseout(function() {
                $(this).attr('src', options.mouseoutImg);
            });
        }
    
})(jQuery);


//$('IMG.classname').dynamicImage({ mouseoverImg: 'over.gif', mouseoutImg: 'out.gif' });
