在上一篇文章中,我们提到如何解决DedeCMS 投票出现Request Error的问题,不知道你的问题有没有成功解决呢?现在再来说一下如何彻底的杜绝此类错误的出现——修改DEDE默认生成的投票代码。请按下面的步骤操作:
$_UF9l0 #>V;ZV5" 打开DEDECMS安装目录的Include目录,找到dedevote.class.php文件,大约100行左右,找到:
/L
4WWQ5 btE+.V Copy to ClipboardLiehuo.Net Codes引用的内容:[
www.veryhuo.com]
"869n37 $items = "<table width='$tablewidth' border='0' cellspacing='1' cellpadding='1' bgcolor='$tablebg'>\r\n";
L$Q+R' $items .= "<form name='voteform' method='post' action='".$GLOBALS['cfg_phpurl']."/vote.php' target='_blank'>\r\n";
_V?Q4}7d/ $items .= "<input type='hidden' name='dopost' value='send' />\r\n";
$b$D[4 $items .= "<input type='hidden' name='aid' value='".$this->VoteID."' />\r\n";
z=U!D `]v $items .= "<input type='hidden' name='ismore' value='".$this->VoteInfos['ismore']."' />\r\n";
H6eGLg={ 修改为:
$9~1s/(' SOL=3hfb^ Copy to ClipboardLiehuo.Net Codes引用的内容:[
www.veryhuo.com]
yN.D(ZwF: $items .= "<form name='voteform' method='post' action='".$GLOBALS['cfg_phpurl']."/vote.php' target='_blank'>\r\n";
e{,/ $items .= "<input type='hidden' name='dopost' value='send' />\r\n";
96avgyc $items .= "<input type='hidden' name='aid' value='".$this->VoteID."' />\r\n";
c"ztrKQQ $items .= "<input type='hidden' name='ismore' value='".$this->VoteInfos['ismore']."' />\r\n";
M)7enp) F. $items .= "<table width='$tablewidth' border='0' cellspacing='1' cellpadding='1' bgcolor='$tablebg'>\r\n";
jlBCu(.,_ 再将:
(Nahtx!/9 wrU[#g,uvr Copy to ClipboardLiehuo.Net Codes引用的内容:[
www.dede58.com]
'r%oOZk)z $items.="</form>\r\n</table>\r\n";
z<>_*Lfj 修改为:
b*KZe[#M1 KoJG!Rm Copy to ClipboardLiehuo.Net Codes引用的内容:[
www.dede58.com]
*
U4:K@y $items.="</table>\r\n</form>\r\n";
<*(R+to^d 用同样的方法,再修改dedevote.inc.php文件,保存。然后再到后台生成一下代码看看吧!
9,CC1f