<?php
include("CheckSession.php");
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="description" content="馬戲團" />
<title>馬戲團</title>
<link href="css/style.css" rel="stylesheet" type="text/css" />
</head>
<?php

require_once("class/DBConfig.php");
require_once("class/DBOperation.php");

$db = new DBOperation();

$db->connect_db($_DB['host'], $_DB['username'], $_DB['password'], $_DB['dbname']);
$db->query("select AId,AName from AdminUser where AId <> 1");
?>
<SCRIPT language="JavaScript">

</SCRIPT>
<body>
<form name="CustomerMoveForm" method="post" action="CustomerMoveUpdateDeal.php" id="CustomerMoveForm"
 onSubmit="return validateForm(this);">
<table border="0" cellspacing="0" cellspadding="0" width="90%">
<!--
<tr>
<td align="center" colspan="2">
<span class="title"><b>客戶轉移管理</b></span>
</td>
</tr>
-->
<tr>
<td align="left" colspan="2">
&nbsp;
</td>
</tr>
<tr>
<td align="left" colspan="2">
<span class="t14b"><b>客戶轉移</b></span>
</td>
</tr>
<tr>
<td align="left" colspan="2">

<table border="3" cellspacing="2" cellspadding="2" width="70%">
<tr>
<td align="left">
<span class="t12">
從
<Select name="AFromId">
<?php
 $i = 0;
 while($myrow = $db->fetch_array()){   
    $i++;
    echo $myrow['AId'];
?>
<Option Value="<?php echo $myrow['AId'] ?>" <?php if($i == 1) echo "selected";?>><?php echo $myrow['AName'] ?></Option>
<?php 
	}
	$db->close_db();
?>
</Select>
轉移至
<Select name="AToId">
<?php
 $db->query("select AId,AName from AdminUser where AId <> 1");
 $i = 0;
 while($myrow = $db->fetch_array()){   
    $i++;
    echo $myrow['AId'];
?>
<Option Value="<?php echo $myrow['AId'] ?>" <?php if($i == 2) echo "selected";?>><?php echo $myrow['AName'] ?></Option>
<?php 
	}
	$db->close_db();
?>
</Select>
</span>
</td>
</tr>
<tr>
<td  align="center" colspan="2">
<input type="submit" name="btnSub" id="btnSub" value="確認轉移" class="t12" />
</td>
</tr>
</table>
</td>
</tr>
</table>
</form>
</body>
</html>
