原帖由 errain 于 2006-5-11 11:05 发表
lulu老大 因为灌水回复不给分了,能不能把采纳的改成设每个给多少奖励积分,就给多少,而不是给两倍积分.
要是发主题提问者点"采纳"时能弹出个框, ...
插件管理->悬赏/提问->[详情]->插件钩子设置->in_viewthread1(钩子名称)->[编辑]-> PHP 代码->
用下面的替换原来的
- if($thread['authorid'] == $discuz_uid && $thread['dpt_iknow_question'] && $post['authorid'] != $discuz_uid && !in_array($post['number'],explode('、',$thread['dpt_iknow_accept']))){
- echo "<a href='###' onclick='javascript:creditval=window.prompt("请输入要奖励的积分数",""); if(creditval>0) window.location="post.php?action=accept&fid=$fid&tid=$tid&number=$post[number]&touid=$post[authorid]&pid=$post[pid]&page=$page&creditval="+creditval;' > $ik_lang[accept1] </a>";
- }elseif(in_array($post['number'],explode('、',$thread['dpt_iknow_accept']))){
- echo $ik_lang[accept7];
- }
- if($forum['ismoderator'] && $post['number'] !=1 && $thread['dpt_iknow_question'] && !in_array($post['number'],explode('、',$thread['dpt_iknow_accept']))){
- echo "<a href="post.php?action=admin&fid=$fid&tid=$tid&touid=$post[authorid]&pid=$post[pid]&page=$page&extraction=punish">$ik_lang[punish]</a>";
- }
复制代码
->提交
就可以了
修改
plugins/iknow/accept.inc.php
在- $acceptnums = $thread['dpt_iknow_accept'] ? $thread['dpt_iknow_accept'] .'、'.$number : $number;
复制代码
上面加上:
- $creditval = intval($creditval);
- $thread[dpt_iknow_answer] = $creditval > 0 && $creditval <= $thread['dpt_iknow_question'] ? $creditval : 2*$thread[dpt_iknow_answer];
复制代码
我晕晕了 |