function set_style()
{
global $HTTP_POST_VARS;//函数set_style_index()提交上来的变量$filecontent = "<?\$bodyimg = '$HTTP_POST_VARS[\'setstyle[0]\']';//第158行
\$trbgcolor = '$HTTP_POST_VARS[\'setstyle[1]\']';//第159行......}
{
global $HTTP_POST_VARS;//函数set_style_index()提交上来的变量$filecontent = "<?\$bodyimg = '$HTTP_POST_VARS[\'setstyle[0]\']';//第158行
\$trbgcolor = '$HTTP_POST_VARS[\'setstyle[1]\']';//第159行......}
$HTTP_POST_VARS[setstyle][1]
\$bodyimg = $HTTP_POST_VARS[setstyle][0];//第158行\$trbgcolor = $HTTP_POST_VARS[setstyle][1];//第159行
是在生成脚本的程序里出错,还是生成的脚本里出错?
如果在生成者里出错,估计是语法错。
可能一行字符太长了,检查的时候没看出来。建议改成
$filecontent.="....";
$filecontent.="....";
这种形式,比较好确定出错位置。
此外一行代码尽量不要太长,容易出错。
解决问题后在加200分来感谢主要解答得网友
function style_index()
{
require("style.php");
global $worktabwidth,$trbgcolor,$intabwidth,$onmouseover;
print <<<EOT
<form action="$thisprog" method=post>
<table border=0 cellpadding=4 cellspacing=1 width=$intabwidth>
<tr bgcolor=$trbgcolor>
<td>
<b>页面的背景图片: (默认:images/bg.gif)</b>
</td>
<td>
<input type=text name="setstyle[0]" size=30 maxlength=30 value="$bodyimg" class="stedit">
</td>
</tr>
<tr bgcolor=$trbgcolor>
<td>
<b>工作区TR的背景色: (默认:FFFFFF)</b>
</td>
<td>
<input type=text name="setstyle[1]" maxlength=30 size=30 value="$trbgcolor" class="stedit">
</td>
</tr>
<tr bgcolor=$trbgcolor>
<td><b>消息表格标题栏的颜色:(默认:eeeeee)</b>
</td>
<td>
<input type=text name="setstyle[2]" size=30 maxlength=30 value="$titlecolor" class="stedit">
</td>
</tr>.......
EOT;
}函数set_style()具体如下
function set_style()
{
global $HTTP_POST_VARS;//函数set_style_index()提交上来的变量$filecontent = "<?\$bodyimg = '$HTTP_POST_VARS['setstyle[0]']';//第158行
\$trbgcolor = '$HTTP_POST_VARS['setstyle[1]']';//第159行......}请大家帮忙呀!!!
感谢各位网友。
特别感谢 vivanboy(被迫早起的鸟儿)(★★★★★)