jquery(document).ready(function($) {
if($("meta[name=totop]").attr("content")=="true"){
$("
").appendto('body');
$("#totop").css({
width: '50px',
height: '50px',
bottom:'10px',
right:'15px',
position:'fixed',
cursor:'pointer',
zindex:'999999',
});
if($(this).scrolltop()==0){
$("#totop").hide();
}
$(window).scroll(function(event) {
/* act on the event */
if($(this).scrolltop()==0){
$("#totop").hide();
}
if($(this).scrolltop()!=0){
$("#totop").show();
}
});
$("#totop").click(function(event) {
/* act on the event */
$("html,body").animate({
scrolltop:"0px"},
666
)
});
}
});