zhangjingyu
完整代码帖下,都是自己试验,修改来的哦。
/***查询对应选手的最后投票时间2018.8.7***/
$already_vote = $db->get_one("SELECT * FROM pw_ext_picvote_log WHERE item_id =".S::sqlEscape($item_id)." AND uid =".S::sqlEscape($winduid)."ORDER BY vote_time DESC LIMIT 1");
/***通过item_id查询选手名字2018.8.7***/
$xuanshou = $db->get_one("SELECT * FROM pw_ext_picvote_item WHERE id=".S::sqlEscape($item_id));
if($already_vote['vote_time']>=$tdtime){
Showmsg("{$already_vote['username']}:今天已投票,请明天继续支持该选手{$xuanshou['contestant']}!");
}