日期:2014-05-17 浏览次数:20972 次
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Digg</title> <script type="text/javascript" src="jquery-1.3.2.min.js"></script> <script type="text/javascript"> $(function(){ getdigshtml();}) function isdigs(digtype)//顶一下,踩一下操作 { $.ajax({ type:'POST', url:'digg.asp', data:'action=digs&digtype='+digtype, /* beforeSend:function(){ $("#vote").hide(); $("#loadings").show(); }, ajax请求显示loading效果*/ success:function(msg){ switch (msg) { /* 后台用来判断 case '1': $("#loadings").hide(); $("#vote").show(); alert("请先登录!"); break; case '2': $("#loadings").hide(); $("#vote").show(); alert("请先下载,再操作!"); break; case '4': $("#loadings").hide(); $("#vote").show(); alert("您已经参与过评价!"); break;*/ case '3': getdigshtml();//重新绑定html //$("#loadings").hide(); //$("#vote").show(); alert("谢谢你的参与!"); break; default: } } }) } function getdigshtml()//获取顶一下,踩一下html { $.ajax({ type:'POST', url:'digg.asp', data:'action=getdigshtml', success:function(msg){ $("#digg").html(msg); } }) } </script> <style type="text/css"> * { padding:0; margin:0; } .digg { height: auto; width: 190px; font-size:12px; font-weight:normal; } .digg a { display: block; height: 48px; width: 189px; background-image: url(images/mark.gif); background-repeat: no-repeat; position: relative; color: #000; text-decoration: none; } .digg .good { margin-bottom:10px; margin-top:5px; } .digg .good a { background-position: -189px 0px; } .digg .good a:hover { background-position: 0px 0px; } .digg .bad a { background-position: -378px 0px; } .digg .bad a:hover { background-position: -567px 0px; } .digg a p { padding-left:30px; line-height:25px; } .digg .bar { background-color: white; height: 5px; left: 20px; overflow: hidden; position: absolute; text-align: left; top: 30px; width: 55px; } .bar #g_img { background-image: url(images/sprites.gif); background-repeat: repeat-x; height: 5px; width: auto; } .bar #b_img { background-image: url(images/sprites.gif); background-repeat: repeat-x; height: 5px; width: auto; background-position: 0px -5px; } .num { color: #333; font: normal normal 100 10px/12px Tahoma; left: 80px; position: absolute; top: 26px; } .digg .good