增加产品
<?php require_once 'base.php';?>
<?php
// 連接數據庫
require_once 'dbconfig.php';
// 訪問基本情況
$query = "select * from basicsituation";
$result = @mysql_query($query);$aquery = "select * from appearanceparameter";
$aresult = @mysql_query($aquery);$cquery = "select * from cellparameters";
$cresult = @mysql_query($cquery);$lquery = "select * from circuitparameters";
$lresult = @mysql_query($lquery);$oquery = "select * from otherfeatures";
$oresult = @mysql_query($oquery);$bbquery = "select * from bproductcategory";
$bbresult = @mysql_query($bbquery);$ffquery = "select * from fappearancematerial";
$ffresult = @mysql_query($ffquery);$xtquery = "select * from xcelltype";
$xtresult = @mysql_query($xtquery);$xmquery = "select * from xcellmaterial";
$xmresult = @mysql_query($xmquery);$xiquery = "select * from xcycleindex";
$xiresult = @mysql_query($xiquery);$xlquery = "select * from xcellmodel";
$xlresult = @mysql_query($xlquery);$liquery = "select * from linputcircuitscheme";
$liresult = @mysql_query($liquery);$loquery = "select * from loutputcircuitscheme";
$loresult = @mysql_query($loquery);
//輸入
$lfquery = "select * from linterfacetype";
$lfresult = @mysql_query($lfquery);$lpquery = "select * from lparameter";
$lpresult = @mysql_query($lpquery);$lfbquery = "select * from linterfacetype";
$lfbresult = @mysql_query($lfbquery);$lpbquery = "select * from lparameter";
$lpbresult = @mysql_query($lpbquery);$lfcquery = "select * from linterfacetype";
$lfcresult = @mysql_query($lfcquery);$lpcquery = "select * from lparameter";
$lpcresult = @mysql_query($lpcquery);$lfdquery = "select * from linterfacetype";
$lfdresult = @mysql_query($lfdquery);$lpdquery = "select * from lparameter";
$lpdresult = @mysql_query($lpdquery);
// 輸出
$lofquery = "select * from linterfacetype";
$lofresult = @mysql_query($lofquery);$lopquery = "select * from lparameter";
$lopresult = @mysql_query($lopquery);
//
$lofbquery = "select * from linterfacetype";
$lofbresult = @mysql_query($lofbquery);$lopbquery = "select * from lparameter";
$lopbresult = @mysql_query($lopbquery);
//
$lofcquery = "select * from linterfacetype";
$lofcresult = @mysql_query($lofcquery);$lopcquery = "select * from lparameter";
$lopcresult = @mysql_query($lopcquery);
//
$lofdquery = "select * from linterfacetype";
$lofdresult = @mysql_query($lofdquery);$lopdquery = "select * from lparameter";
$lopdresult = @mysql_query($lopdquery);
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>增加產品</title><link href="diyUpload/css/webuploader.css" rel="stylesheet" />
<link href="diyUpload/css/diyUpload.css" rel="stylesheet" /></head>
<style>*{margin: 0;padding: 0;}#box{margin: 50px auto;width: 540px;min-height: 400px;background: #FF9;}#demo{margin: 50px auto;width: 540px;min-height: 800px;background: #CF9;}
</style>
<body><div id="page-wrapper"><div id="page-inner"><div class="row"><div class="col-md-12"><h2>增加產品</h2></div></div><hr /><nav class="navbar navbar-default" role="navigation"><div class="container-fluid"><ul class="nav navbar-nav"><li><a href="#BasicSituation">基本情況</a></li><li><a href="#AppearanceParameter">外觀參數</a></li><li><a href="#CellParameters">電芯參數</a></li><li><a href="#CircuitParameters">電路參數</a></li><li><a href="#OtherFeatures">其他功能</a></li></ul></div></nav><form role="form" action="increaseproductdo.php" method="post" enctype="multipart/form-data"><!-- <div class="form-group"><label for="inputfile">產品圖片</label> <input type="file" name="myfile[]" id="inputfile" multiple></div> --><div id="box"><div id="test"></div></div><div id="BasicSituation"><h3>基本情況</h3></div>
<?php
while ($row = mysql_fetch_array($result)) {if($row['BName'] == "產品類別"){echo "<p>".$row['BName']."</p>";?>
<?php
while ($bbrow = mysql_fetch_array($bbresult)) {
?><label><input name='' type='checkbox'' value=''/><?php echo $bbrow['BName']?></label>
<?php
}
?><?php continue;}
?>
<p><?php echo $row['BName'];?></p><input type="text" name="<?php $row['BName']?>" />
<?php
}
?><div id="AppearanceParameter"><h3>外觀參數</h3></div>
<?php
while ($row = mysql_fetch_array($aresult)) {if ($row['FName'] == "外殼材料"){echo "<p>".$row['FName']."</p>";?><select><option value=""></option><?phpwhile ($ffrow = mysql_fetch_array($ffresult)) {?><option value ="<?php $ffrow['FName']?>"><?php echo $ffrow['FName']?></option><?php }?></select><?php continue;}
?>
<p><?php echo $row['FName'];?></p><input type="text" name="<?php $row['FName']?>" />
<?php
}
?><div id="CellParameters"><h3>電芯參數</h3></div>
<?php
while ($row = mysql_fetch_array($cresult)) {if ($row['XName'] == "電芯類型"){echo "<p>".$row['XName']."</p>";?><select><option value=""></option><?phpwhile ($xtrow = mysql_fetch_array($xtresult)) {?><option value ="<?php $xtrow['XName']?>"><?php echo $xtrow['XName']?></option><?php }?></select><?php continue;}if ($row['XName'] == "電芯材料"){echo "<p>".$row['XName']."</p>";?><select><option value=""></option><?phpwhile ($xmrow = mysql_fetch_array($xmresult)) {?><option value ="<?php $xmrow['XName']?>"><?php echo $xmrow['XName']?></option><?php }?></select><?php continue;}if ($row['XName'] == "循環次數"){echo "<p>".$row['XName']."</p>";?><select><option value=""></option><?phpwhile ($xirow = mysql_fetch_array($xiresult)) {?><option value ="<?php $xirow['XName']?>"><?php echo $xirow['XName']?></option><?php }?></select><?php continue;}if ($row['XName'] == "電芯型號"){echo "<p>".$row['XName']."</p>";?><select><option value=""></option><?phpwhile ($xlrow = mysql_fetch_array($xlresult)) {?><option value ="<?php $xlrow['XId']?>"><?php echo $xlrow['Xstyle']."-".$xlrow['Xbox']."-".$xlrow['Xsize']."-".$xlrow['Xm']?></option><?php }?></select><?php continue;}?>
<p><?php echo $row['XName'];?></p><input type="text" name="<?php $row['XName']?>" />
<?php
}
?><div id="CircuitParameters"><h3>電路參數</h3></div>
<?php
while ($row = mysql_fetch_array($lresult)) {if ($row['LName'] == "輸入電路方案"){echo "<p>".$row['LName']."</p>";?><select><option value=""></option><?phpwhile ($lirow = mysql_fetch_array($liresult)) {?><option value ="<?php $lirow['LName']?>"><?php echo $lirow['LName']?></option><?php }?></select><?php continue;}if ($row['LName'] == "輸入A"){echo "<p>".$row['LName']."</p>";?><select><option value=""></option><?phpwhile ($lfrow = mysql_fetch_array($lfresult)) {?><option value ="<?php $lfrow['LName']?>"><?php echo $lfrow['LName']?></option><?php }?></select><select><option value=""></option><?phpwhile ($lprow = mysql_fetch_array($lpresult)) {?><option value ="<?php $lprow['LName']?>"><?php echo $lprow['LName']?></option><?php }?></select><?php continue;}if ($row['LName'] == "輸入B"){echo "<p>".$row['LName']."</p>";?><select><option value=""></option><?phpwhile ($lfbrow = mysql_fetch_array($lfbresult)) {?><option value ="<?php $lfbrow['LName']?>"><?php echo $lfbrow['LName']?></option><?php }?></select><select><option value=""></option><?phpwhile ($lpbrow = mysql_fetch_array($lpbresult)) {?><option value ="<?php $lpbrow['LName']?>"><?php echo $lpbrow['LName']?></option><?php }?></select><?php continue;}if ($row['LName'] == "輸入C"){echo "<p>".$row['LName']."</p>";?><select><option value=""></option><?phpwhile ($lfcrow = mysql_fetch_array($lfcresult)) {?><option value ="<?php $lfcrow['LName']?>"><?php echo $lfcrow['LName']?></option><?php }?></select><select><option value=""></option><?phpwhile ($lpcrow = mysql_fetch_array($lpcresult)) {?><option value ="<?php $lpcrow['LName']?>"><?php echo $lpcrow['LName']?></option><?php }?></select><?php continue;}if ($row['LName'] == "輸入D"){echo "<p>".$row['LName']."</p>";?><select><option value=""></option><?phpwhile ($lfdrow = mysql_fetch_array($lfdresult)) {?><option value ="<?php $lfdrow['LName']?>"><?php echo $lfdrow['LName']?></option><?php }?></select><select><option value=""></option><?phpwhile ($lpdrow = mysql_fetch_array($lpdresult)) {?><option value ="<?php $lpdrow['LName']?>"><?php echo $lpdrow['LName']?></option><?php }?></select><?php continue;}if ($row['LName'] == "輸出電路方案"){echo "<p>".$row['LName']."</p>";?><select><option value=""></option><?phpwhile ($lorow = mysql_fetch_array($loresult)) {?><option value ="<?php $lorow['LName']?>"><?php echo $lorow['LName']?></option><?php }?></select><?php continue;}if ($row['LName'] == "輸出A"){echo "<p>".$row['LName']."</p>";?><select><option value=""></option><?phpwhile ($lofrow = mysql_fetch_array($lofresult)) {?><option value ="<?php $lofrow['LName']?>"><?php echo $lofrow['LName']?></option><?php }?></select><select><option value=""></option><?phpwhile ($loprow = mysql_fetch_array($lopresult)) {?><option value ="<?php $loprow['LName']?>"><?php echo $loprow['LName']?></option><?php }?></select><?php continue;}if ($row['LName'] == "輸出B"){echo "<p>".$row['LName']."</p>";?><select><option value=""></option><?phpwhile ($lofbrow = mysql_fetch_array($lofbresult)) {?><option value ="<?php $lofbrow['LName']?>"><?php echo $lofbrow['LName']?></option><?php }?></select><select><option value=""></option><?phpwhile ($lopbrow = mysql_fetch_array($lopbresult)) {?><option value ="<?php $lopbrow['LName']?>"><?php echo $lopbrow['LName']?></option><?php }?></select><?php continue;}if ($row['LName'] == "輸出C"){echo "<p>".$row['LName']."</p>";?><select><option value=""></option><?phpwhile ($lofcrow = mysql_fetch_array($lofcresult)) {?><option value ="<?php $lofcrow['LName']?>"><?php echo $lofcrow['LName']?></option><?php }?></select><select><option value=""></option><?phpwhile ($lopcrow = mysql_fetch_array($lopcresult)) {?><option value ="<?php $lopcrow['LName']?>"><?php echo $lopcrow['LName']?></option><?php }?></select><?php continue;}if ($row['LName'] == "輸出D"){echo "<p>".$row['LName']."</p>";?><select><option value=""></option><?phpwhile ($lofdrow = mysql_fetch_array($lofdresult)) {?><option value ="<?php $lofdrow['LName']?>"><?php echo $lofdrow['LName']?></option><?php }?></select><select><option value=""></option><?phpwhile ($lopdrow = mysql_fetch_array($lopdresult)) {?><option value ="<?php $lopdrow['LName']?>"><?php echo $lopdrow['LName']?></option><?php }?></select><?php continue;}?>
<p><?php echo $row['LName'];?></p><input type="text" name="<?php $row['LName']?>" />
<?php
}
?><div id="OtherFeatures"><h3>其他功能</h3></div>
<?php
while ($row = mysql_fetch_array($oresult)) {
?>
<p><?php echo $row['OName'];?></p><input type="text" name="<?php $row['OName']?>" />
<?php
}
?><button style="float: right;" type="submit" class="btn btn-primary">提交</button></form></div></div><script src="assets/js/jquery-1.10.2.js"></script><script src="assets/js/bootstrap.min.js"></script><script src="assets/js/jquery.metisMenu.js"></script><script src="assets/js/custom.js"></script><script src="diyUpload/js/webuploader.html5only.min.js"></script><script src="diyUpload/js/diyUpload.js"></script>
<script type="text/javascript">/*
* 服務器地址,成功返回,失敗返回參數格式依照jquery.ajax習慣;
* 其他參數同WebUploader
*/$('#test').diyUpload({url:'server/fileupload.php',success:function( data ) {console.info( data );},error:function( err ) {console.info( err ); }
});</script></body>
</html>
總結
- 上一篇: 【老生谈算法】基于主成分分析PCA的ma
- 下一篇: Atitit Data Matrix d