<!--
/*
* Fichier javascript pour le site VisioPlu
* @version 1.0
*
*/
$(function() {

	/*
	* Rollover d'images et préchargement
	* Insérer les images avec le code suivant : <img src="first.gif" data-hover="second.gif" />
	* Respecte les spécifications html5
	*/
  $('img[data-hover]').hover(function() {
      $(this).attr('tmp', $(this).attr('src')).attr('src', $(this).attr('data-hover')).attr('data-hover', $(this).attr('tmp')).removeAttr('tmp');
  }).each(function() {
      $('<img />').attr('src', $(this).attr('data-hover'));
  });
    
  /*
  * Transformer les <input type="submit"> en <button>
  * <input type="submit" value="Valider" name="submit" />
  * Est remplacé par
  * <button type="submit" value="Valider" name="submit"><span>Valider</span></button>
  */
	$(':input[type="submit"]').each(function () {
		$(this).after('<button type="submit" class="submitBtn" value="'+$(this).val()+'" name="'+$(this).attr('name')+'"><span>'+$(this).val()+'</span></button>').remove();
	});
	
	/*
	* Fancy submit buttons
	*
	*/
	$('.submitBtn').hover(
		// mouseover
		function(){ $(this).addClass('submitBtnHover'); },
		
		// mouseout
		function(){ $(this).removeClass('submitBtnHover'); }
	);
	
	/*
	* Fancy Scrollbars
	*/
	
	$('.scroll-pane').jScrollPane({
				verticalDragMinHeight: 61,
				verticalDragMaxHeight: 61
		});

	// Fancy Inputs
	$('input').customInput();

});

-->

