DEDECMS 5.7滑动星星评分插件安装说明:在最终页面article_article.htm的合适位置插入以下代码:
分为两种安装模式(任选其一) 插件下载:(仅提供UTF-8版本,GBK请自行转码) 在最终页面article_article.htm的合适位置插入以下代码:
<LINK rel=stylesheet type=text/css href="{dede:global.cfg_phpurl/}/star/css/jRating.jquery.css" media=screen>
<s cript language=javas cript type=text/javas cript src="{dede:global.cfg_cmsurl/}/include/dedeajax2.js"></s cript>
<s cript type=text/javas cript src="{ded>
e:global.cfg_phpurl/}/star/js/jquery.js"></s cript>
<s cript type=text/javas cript src="{dede:global.cfg_phpurl/}/star/js/jRating.jquery.js"></s cript>
<s cript type=text/javas cript src="{dede:global.cfg_phpurl/}/star/js/jNotify.jquery.js"></s cript>
<s cript type=text/javas cript>
$(document).ready(function(){
$('.star').jRating({
step:true,
length :5, //星星数
canRateAgain : true,
nbRates : 3,
showRateInffalse, //鼠标悬停提示开关
onSuccess : function(){
jSuccess('感谢您的评价',{
HorizontalPosition:'center',
VerticalPosition:'top'
});
}, //自定义发布提示
});
});
var options = {
bigStarsPath : '{dede:global.cfg_phpurl/}/star/css/icons/stars.png', //星星图片路径
phpPath : '{dede:global.cfg_phpurl/}/jRating.php', //接收脚本
type : 'big',
};
function getstar(aid)
{
var taget_obj = document.getElementById('star');
var aid = '{dede:field.id/}';
myajax = new DedeAjax(taget_obj,false,false,'','','');
myajax.SendGet2("{dede:global.cfg_phpurl/}/star_ajax.php?id="+aid); //调取评分部分
}
</s cript>
<DIV class=show_star>
<DIV class=star data-id="{dede:field.id/}" data-average="10"></DIV>
<DIV id=star></DIV>
<s cript language=javas cript type=text/javas cript>getstar();</s cript>
</DIV>>
0 (0%) 好评 | 0 (0%) 中评 | 0 (0%) 差评 |