﻿/*
 * FATBURGER
 * http://FATBURGER.COM
 * 
 * Copyright (c) 2009 FATBURGER INC.
 *
 * Date: 2009-02-01 
 * Revision: 001
 *
 */


//Image Rollovers
function setRolloverImages(){
	$("img.rollover").hover(
	    function(){
		    this.src = this.src.replace(".jpg","_over.jpg");
		 },
		 function(){
		    this.src = this.src.replace("_over.jpg",".jpg");
		 }
	);
}

//Scroll to top of page
function wt_scrollTop(){
    $('html').animate({scrollTop:0},'fast');
}


//INIT
$(document).ready(function() {
	setRolloverImages();
});				 



$(document).ready(function(){

 //Attach scroll event handler
 $(window).scroll(function (){ 
		var scrollTop = $(window).scrollTop();
		var winWdth = $(window).width();
		var height = $(window).height();

	    winWdth = parseInt(winWdth);
		
		/*
		if(scrollTop>height){
		    var setLeft =  winWdth - (140);		
			$("#apDiv_BackToTop").fadeIn("fast").css("left",(setLeft + "px")).css("top",((scrollTop + 40) + "px"));
		}
		else{
			$("#apDiv_BackToTop").fadeOut("fast");
		}
		*/
	
    });
});


