/* 
 * Petals Forms JS
 */

$(function(){

   // Watermark fields
   $('.watermark').each(function(){
	title = $(this).attr('title');
	$(this)
	.attr('rel',title)
	.val(title)
	.addClass('faded')
	.attr('title','');

   });

   $('.watermark')
      .focus(function(){
	 title	  = $(this).attr('rel');
	 val	  = $(this).val();

	 if (val == title) {
	    $(this).val('').removeClass('faded');
	 }
      })
      .blur(function(){
	 title	  = $(this).attr('rel');
	 val	  = $(this).val();

	 if (val == '') {
	    $(this).val(title).addClass('faded');
	 }
   });

});


