tpxh.php 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. <?php
  2. include("../config/conn.php");
  3. include("../config/function.php");
  4. AdminSes_audit();
  5. $bh=$_GET[bh];
  6. if($_GET[control]=="xh"){
  7. zwzr();
  8. $xhall=intval($_POST["xhall"]);
  9. for($i=1;$i<$xhall;$i++){
  10. $xh=intval($_POST["xht".$i]);
  11. $xhid=intval($_POST["xhid".$i]);
  12. updatetable("yjcode_tp","xh=".$xh." where id=".$xhid);
  13. }
  14. php_toheader("tpxh.php?t=suc&bh=".$bh);
  15. }
  16. ?>
  17. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  18. <html xmlns="http://www.w3.org/1999/xhtml">
  19. <head>
  20. <meta http-equiv="x-ua-compatible" content="ie=7" />
  21. <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
  22. <title><?=webname?>管理系统</title>
  23. <link rel="stylesheet" href="layui/css/layui.css">
  24. <link href="css/basic.css" rel="stylesheet" type="text/css" />
  25. <script type="text/javascript" src="js/jquery.min.js"></script>
  26. <script language="javascript" src="js/basic.js"></script>
  27. <script language="javascript" src="js/layer.js"></script>
  28. <style type="text/css">
  29. .tplist{float:left;width:610px;}
  30. .tplist .d1{float:left;width:90px;margin:10px 0 0 10px;}
  31. .tplist .d1 img{width:90px;height:90px;}
  32. .tplist .d1 a{float:left;width:100%;}
  33. .tplist .d1 input{float:left;width:88px;text-align:center;margin:5px 0 0 0;}
  34. .tplist .xhbtn{float:left;width:100%;}
  35. .tplist .xhbtn input{float:left;width:200px;height:30px;margin:10px 0 10px 205px;cursor:pointer;border:0;color:#fff;background-color:#ff6600;}
  36. </style>
  37. <script language="javascript">
  38. function tj(){
  39. layer.msg('正在保存', {icon: 16 ,time: 0,shade :0.25});
  40. f1.action="tpxh.php?control=xh&bh=<?=$bh?>";
  41. }
  42. <? if($_GET[t]=="suc"){?>
  43. parent.xgtread("<?=$bh?>");
  44. parent.layer.closeAll();
  45. <? }?>
  46. </script>
  47. </head>
  48. <body>
  49. <div class="tplist">
  50. <form name="f1" method="post" onsubmit="return tj()">
  51. <?
  52. $i=1;
  53. while1("*","yjcode_tp where bh='".$bh."' order by xh asc");while($row1=mysql_fetch_array($res1)){
  54. if(empty($row1[upty])){
  55. $tp1="../".$row1[tp];
  56. $tp2="../".str_replace(".","-1.",$row1[tp]);
  57. }else{
  58. $tp1=$row1[tp];
  59. $tp2=returnnotp($row1[tp],"-1");
  60. }
  61. ?>
  62. <div class="d1">
  63. <a href="<?=$tp1?>" class="a1" target="_blank"><img class="img" border="0" src="<?=$tp2?>" /></a>
  64. <input type="text" value="<?=$row1[xh]?>" name="xht<?=$i?>" />
  65. <input type="hidden" value="<?=$row1[id]?>" name="xhid<?=$i?>" />
  66. </div>
  67. <? $i++;}?>
  68. <input type="hidden" value="<?=$i?>" name="xhall" />
  69. <div class="xhbtn">
  70. <input type="submit" value="保存序号" />
  71. </div>
  72. </form>
  73. </div>
  74. </body>
  75. </html>