include("connect.inc") ?>
$query = "select cid from dream_customer where username='$cname' and password='$password'";
$result = ora_parse($cursor, $query);
$result = ora_exec($cursor);
if(!ora_fetch($cursor)) {
$message="Login Fail. Please click back to check you username and password";
}
else {
$cid = ora_getcolumn($cursor, 0);
if(!$bidprice) {
$message="Please enter your bidding. You can click back button.";
}
else {
$message = "Thank you for bidding product at dreamland.";
$today = getdate();
if ($today[month]=='January') {
$month = "JAN";
}
if ($today[month]=='February') {
$month = "FEB";
}
if ($today[month]=='March') {
$month = "MAR";
}
if ($today[month]=='April') {
$month = "APR";
}
if ($today[month]=='May') {
$month = "MAY";
}
if ($today[month]=='June') {
$month = "JUN";
}
if ($today[month]=='July') {
$month = "JUL";
}
if ($today[month]=='August') {
$month = "AUG";
}
if ($today[month]=='September') {
$month = "SEP";
}
if ($today[month]=='October') {
$month = "OCT";
}
if ($today[month]=='November') {
$month = "NOV";
}
if ($today[month]=='December') {
$month = "DEC";
}
$todaydate = $today[mday]."-".$month."-00";
$query = "select count(*) from dream_bidding";
$result = ora_parse($cursor, $query);
$result = ora_exec($cursor);
ora_fetch($cursor);
$bid = 10000001 + ora_getcolumn($cursor,0);
$query = "insert into dream_bidding values('$bid','$cid','$pid','$bidprice','$todaydate')";
$result = ora_parse($cursor, $query);
$result = ora_exec($cursor);
ora_close($cursor);
ora_logoff($connHandle);
}
}
?>
echo $message; ?>
Click Dream