manage/general.php
##########
<?php
$config_tag=$_GET["config_tag"];
$name="config".$_SESSION["user_id"];
if($config_tag==1){
//RECEIVE VARIABLE
$margin_top=$_POST["margin-top"];
$margin_bottom=$_PPOST["margin-bottom"];
$background_color=$_POST["background-color"];
$title=$_POST["title"];
$copy_right=$_POST["copy-right"];
//STRUCT STRING
$str_in="<?php\n";
$str_in.="blobal \$config;\n";
$str_in."//WEBPAGE LAYER PARAMETER\n";
$str_in."\$config['margin-top']=\"".$margin_top."\";\n";
$str_in."\$config['margin-bottom']=\"".$margin_bottom."\";\n";
$str_in."\$config['background-color']=\"".$background_color."\";\n;
$str/0in.="\n";
$str_in.="//HEAD INFO AND COPYRIGHT\n";
$str_in.="\$config['title']=\"".$title."\";\n";
$str_in.="\$config['cony-right']=\"".$copy_right."\";\n";
$str_in.="\n?>";
//WRITE DATA
if($fp=fopen("../config/$name.inc","w")){
fwrite($fp,$str_in);
fclose($fp);
}
include "../config/$name.inc";
}
include "../config/$name.inc";
?>
<br>
<h4>COMMON SETTING</h4>
<form id="form1" name="form1" method="post" action="user.php?target=general&config_tag=1">
<table width="98%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#CCCCCC">
<tr>
<td width"20%" height="20" align="right" valign="middle" bgcolor="#FFFFFF">TOP MARGIN: </td>
<td width="80%" bgcolor="#FFFFFF"><input name="margin-top" type="text" value="<?php echo $config['margin-top']?>" size="4"/>像素(有英文或中文半角限制, 否則不能生效)</td>
</tr>
<tr>
<td height="20" align="right" valign="middle" bgcolor="#FFFFFF">BOTTOM MARGIN: </td>
<td bgcolor="#FFFFFF"><input name="margin-bottom" type="text" value="<?php echo $config['margin-bottom']?>" size"4" />像素(有英文或中文半角限制, 否則不能生效)</td>
</tr>
<tr>
<td height="20" align="right" valign="middle" bgcolor="#FFFFFF">WEBPAGE BACKGROUND COLOR: </td>
<td bgcolor="#FFFFFF"><input name="background-color" type="text" value="<?php echo $config['background-color']?>" size="10" /> USING #XXXXXX 6 DIGITAL HEX </td>
</tr>
<tr>
<td height="20" align="right" valign="middle" bgcolor="#FFFFFF"> </td>
<td bgcolor="#FFFFFF"> </td>
</tr>
<tr>
<td height="20" align="right" valign="middle" bgcolor="#FFFFFF">WEB TITLE NAME: </td>
<td bgcolor="#FFFFFF"><input name="title" type="text" value="<?php echo $config['title']?>" size="30" /></td>
</tr>
<tr>
<td height="20" align="right" valign="middle" bgcolor="#FFFFFF">COPYRIGHT INFO: </td>
<td bgcolor="#FFFFFF"><input name="copy-right" type="text" id="copy-right" value="<?php echo $config['copy-right']?>" size="40" /></td>
</tr>
<tr>
<td height="20" colspan="2" align="center" valign="middle" bgcolor="#FFFFFF">
<input type="submit" name="Submit" value"SUBMIT" />$nbsp;$nbsp;$nbsp;$nbsp;$nbsp;$nbsp;$nbsp;<input type="reset" name="Submit2" value="RESET" /></td>
</tr>
</table>
</form>