<?php
    include('../loginsession.php');
    error_reporting(E_ALL);
    $filename = basename(__FILE__);
    $save = mysqli_query($conn, "INSERT INTO novia_abc_user_logs (userid,filename) VALUES ('$userini_id','$filename')");

$id = $_GET['id'];
if(isset($_GET['aero'])){
    $aerom = $_GET['aero'];
}

$tgl=  $_POST['tgl']; 
$jumlah =  $_POST['jumlah'];

if ($aerom == 'aero_main.php'){
    $save=mysqli_query($conn, "UPDATE novia_abc_user_aero SET tanggal='$tgl', aero='$jumlah' where id='$id'");
    if($save){
        header("Location:". $aerom);
    }
}
if ($aerom == 'meditation.php'){
    $save=mysqli_query($conn, "UPDATE novia_abc_user_aero SET tanggal='$tgl', meditation='$jumlah' where id='$id'");
    if($save){
        header("Location:". $aerom);
    }    
}    

?>