$dnum = date(Ymd)*4;
$from = $_GET['fr'];
if($from == ""){
$from = $_POST['fr'];
}
if($from != $dnum){
echo("<<<<Restricted Area>>>>" .
"
Sorry, you must Log In to view this Page
");
exit();
}
$usrn = $_GET['usrn'];
if($usrn == ""){
$usrn = $_POST['usrn'];
}
if($usrn == ""){
echo("<<<<Restricted Area>>>>" .
"
Problem with your username. Please Log In again.
");
exit();
}
$today = date("F j, Y");
$dtnum = date(Ymd);
$up_date = $_POST['up_date'];
$productnamea = $_POST[productnamea];
if($productnamea[0] == ""){
echo("Missing Category Code in Item Number
Please go back and correct. ");
exit();
}elseif($productnamea[1] == ""){
echo("
Missing Product Code in Item Number
Please go back and correct. ");
exit();
}elseif($productnamea[2] == ""){
echo("
Missing Detail Code in Item Number
Please go back and correct.
");
exit();
}else{
$productname = implode("-", $productnamea);
}
$dbcnx = @mysql_connect('mysql.plainhost.com', 'ecosmar_ecosmart', 'ecoman1');
mysql_select_db('ecosmar_products', $dbcnx);
$checkit = mysql_query("SELECT id FROM prices WHERE productname='$productname'");
if(!$checkit){
echo("Problem checking for duplicate Item Number
".mysql_error()."
");
}else{
$itemcount = mysql_num_rows($checkit);
if($itemcount > 0){
echo("Duplicate Item Number
Please go back and correct.
");
exit();
}
}
$descript = $_POST['description'];
$out = array("\"","\'");
$in = array(""","’");
$description = str_replace($out, $in, $descript);
$list = $_POST['list'];
$retail = $_POST['retail'];
$wholesale = $_POST['wholesale'];
$dealer = $_POST['dealer'];
$distributor = $_POST['distributor'];
$cost = $_POST['cost'];
$unit = $_POST['unit'];
if($unit == ""){
echo("No Units Described
Please go back and correct.
");
exit();
}elseif($unit == "EA"){
$case = 1;
}elseif($unit == "CS"){
$case = $_POST['t1'];
}else{
$case = 0;
}
$minimum = $_POST['minimum'];
?>
|
Description:
|
Units:
if($unit == "CS"){
echo("Case Amount: $case");
}else{
echo("Case Amount: $case ");
}
?>
Minimum Units:
|
Prices:
|
List
| Retail
| Wholesale
| Dealer
| Distributor
| Cost
|
|
|
|
|
|
|
Update: echo $today;?>
|
©2006 - Data Base Interface - Custom Built at:
|