<?php
include("../include/FunctionDB.php");
$msg "&nbsp;";
$reload "";
    if ( !empty(
$Docom_name) )
        {
            
$Docom_name ereg_replace ("\"","&quot;" ,"$Docom_name");
            
ConnectDB();
            
InsertQadocument($Docom_name);
            
$msg "<font color=\"#FF0000\"><strong> เพิ่มข้อมูล '<font color=\#0000FF\">$Docom_name</font>' COMPLETE</Strong></font> ";
            
$reload "<script language=\"JavaScript\">\n";
            
$reload $reload."parent.frames.nav.location.reload();\n";
            
$reload $reload."</script>";
            echo
"<meta http-equiv=\"refresh\"content=\"2;URL=AddQadoument.php\">\n"
            
CloseDB();
        }
        else {
        
        
$msg "<font color=\"#FF0000\"><strong>ยังไม่ได้กรอกข้อมูลแหล่งเงิน </Strong></font> ";
        
        }
    
?>
<html>
<head> 
<title> เพิ่มข้อมูลแหล่งเงิน</title>
<meta http-equiv="Content-Type"content="text/html; charset=windows-874">
<link href="../css/style1.css" rel="stylesheet" type="text/css">
<head>
<body bgcolor="#FFFFFF">
<? $reload?>
<div align="center">
<b><? $msg ?></b>

  <table width="92%" border="0" cellspacing="1" cellpadding="0" align="center">
    <form action="<? echo  $PHP_SELF ?>" method="post" enctype="multipart/form-data">
      <tr align="center" bgcolor="#006699"> 
        <td colspan="3" class="Tahoma8"> <b><font color="#FFFFFF" size="4" face="Tahoma">เพิ่มหมวดข้อมูล</font></b>        </td>
      </tr>
      <tr>
        <td  align=\"right\" bgcolor="#dddddd"><font size="2" face="Tahoma">ชื่อรายการเอกสาร</font></td>
        <td    bgcolor="#dddddd"><font face="Tahoma">&nbsp;<font color="#FF0000" size="3"><strong>*</strong></font></font></td>
        <td     bgcolor="#dddddd"><font face="Tahoma">
          <input name="Docom_name" type="text" id="Docom_name" title="Docom_name" size="50">
        </font></td>
      </tr>
      <tr> 
        <td width="132"  align=\"right\" bgcolor="#dddddd"><font size="2" face="Tahoma">ไฟล์เอกสาร</font></td>
        <td width="23"    bgcolor="#dddddd"><font face="Tahoma">&nbsp;<font color="#FF0000" size="3"><strong>*</strong></font></font></td>
        <td width="455"     bgcolor="#dddddd"><label>
          <input name="file" type="file" size="30">
        </label></td>
      </tr>
      <tr bgcolor="#006699"> 
        <td colspan="3"    align="right"> 
          <div align="center"><font face="Tahoma"> 
            <input type="submit" name="Submit" value="  เพิ่มข้อมูล ">
            </font>
             <input type="button" name="close2" value="ปิดหน้าต่าง" onClick="window.close()" />
          </div></td>
      </tr>
    </form>
  </table>
</div>
    </body>
    </html>