<?php 
include('config.php');

$conn->query("update setupautoid SET jurnal = jurnal + 1 WHERE id = 1");

$sql_autoid = "SELECT * FROM setupautoid";
$dcon = $conn->query($sql_autoid) or die($sql_autoid);
$rs = $dcon->fetch_array();

$autoid = $rs['jurnal'];
$type 	= $_GET['type'];
header('Location:new?id='.$autoid."&type=".$type);
?>