<?
	$seq = $_POST['seq'];
	$mId = $_POST['mId'];
	
	require_once('link.php');
	mysql_select_db($database,$connect);
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>台灣樂團資料庫-文章修改</title>
<style>
<!--
.style1 {font-size: 13px; color: #FFFFFF; }
BODY {
	SCROLLBAR-FACE-COLOR: #D4D0C8;
	SCROLLBAR-HIGHLIGHT-COLOR: #D4D0C8;
	SCROLLBAR-SHADOW-COLOR: #999999;
	SCROLLBAR-3DLIGHT-COLOR: #FFFFFF;
	SCROLLBAR-ARROW-COLOR:  #000000;
	SCROLLBAR-TRACK-COLOR: #E3E3E3;
	SCROLLBAR-DARKSHADOW-COLOR: #666666;
	background-color: #000000;
	background-image: url(img/bg4.png);
	background-attachment: fixed;
}
a:link {
	color: white;
	text-decoration: none;
}
a:visited {
	color: white;
	text-decoration: none;
}
a:hover {
	text-decoration: underline;
}
a:active {
	text-decoration: none;
}
body,td,th {
	font-family: Arial, Helvetica, sans-serif;
	color: #FFFFFF;
}
.style5 {
	font-size: 16px;
	font-weight: bold;
}
--></style>

</head>
<script  language="JavaScript">
function check()
{
	var r=confirm("是否修改此文章?");
	if(r==true)
		return true;
	if(r==false);
		return false;
	
}
</script>
<body leftmargin=0 topmargin=0 bgproperties="fixed" rightmargin=0  bottommargin=0 marginwidth=0 marginheight=0>
<center>
<?
	$query = "SELECT * FROM `Article` WHERE `mId` = '$mId' AND `seq` = '$seq'";
	mysql_query('SET NAMES utf8');
	$result = mysql_query($query,$connect);
	$row = mysql_fetch_object($result);
?>
<form action = "modarticle_act.php" method = "post" name = "modify" onSubmit = "return check()">
<p>&nbsp;</p>
<p><a href = "member_link.php" class="style5">會員功能列表</a> </p>
<table width="357" border = "0" cellpadding="1" cellspacing="0" align="center" class="style1">
		<td bgcolor="#2B1A0E"><div align = "center">推薦</div></td><td width="0"></td>
		<td bgcolor="#2B1A0E"><? 
				if($row->bLevel=='1'||$row->aLevel=='1')
				{
					echo "正推";
				}
				else
				{
					echo "反推";
				}

		?>
		  <div align="left"></div></td>
	</tr><tr><td colspan = "2" height = "1"></td>
	<tr>
		<td bgcolor="#413009"><div align = "center">樂團</div></td><td width="0"></td>
		<td bgcolor="#413009"><? 
				if($row->rcBand1!='')
				{
					echo $row->rcBand1;
				}
				if($row->rcBand2!='')
				{
					echo "".$row->rcBand2."-".$row->rcAlbum."";
				}

		?>
	    <div align="left"></div></td>
	</tr><tr><td colspan = "2" height = "1"></td>
	<tr>
		<td bgcolor="#6D5C19"><div align = "center">發表日期</div></td><td width="0"></td>
		<td bgcolor="#6D5C19"><? echo $row->arDateTime;?>
	    <div align="left"></div></td>
	</tr><tr><td colspan = "2" height = "1"></td>
	<tr>
		<td bgcolor="#958E41"><div align = "center">標題</div></td><td width="0"></td>
		<td bgcolor="#958E41">
	      <div align="left">
	        <input type = "text" name = "title" value = "<? echo $row->title;?>" size = "40">
        </div></td>
	</tr><tr><td colspan = "2" height = "1"></td>
	<tr bgcolor="#C2C178">
		<td colspan = "3"><div align = "center"><textarea cols = "40" name = "content" rows = "12"><? echo $row->content;?></textarea></div></td>
	</tr>
</table>
<input type = "hidden" value="<? echo $row->mId;?>" name="mId">
<input type = "hidden" value="<? echo $row->seq;?>" name="seq">
<input type = "submit" value = "修改" name="msgmodify"> 
</form>
</center>
</body>
</html>
