first commit
This commit is contained in:
12
app/kirim/upload_dok.php
Normal file
12
app/kirim/upload_dok.php
Normal file
@@ -0,0 +1,12 @@
|
||||
<?php
|
||||
include("../koneksi.php");
|
||||
$surat_id=$_POST['surat_id'];
|
||||
$folder = "dok";
|
||||
$tmp_name = $_FILES["file_dok"]["tmp_name"];
|
||||
$name = $folder."/".$surat_id."_".$_FILES["file_dok"]["name"];
|
||||
$name_ins = $surat_id."_".$_FILES["file_dok"]["name"];
|
||||
move_uploaded_file($tmp_name, $name);
|
||||
$input = pg_query("INSERT INTO scan (file,surat_id) VALUES ('$name_ins','$surat_id')");
|
||||
echo $surat_id;
|
||||
?>
|
||||
|
||||
Reference in New Issue
Block a user