2018-12-27 07:27:47 +00:00
|
|
|
<?php
|
|
|
|
/**
|
|
|
|
* Created by PhpStorm.
|
|
|
|
* User: jedi
|
|
|
|
* Date: 12/27/18
|
|
|
|
* Time: 4:46 AM
|
|
|
|
*/
|
|
|
|
?>
|
2018-12-27 20:56:30 +00:00
|
|
|
|
2018-12-27 07:27:47 +00:00
|
|
|
|
|
|
|
<div class="container-fluid">
|
|
|
|
|
|
|
|
<!-- Breadcrumbs-->
|
|
|
|
<ol class="breadcrumb">
|
|
|
|
<li class="breadcrumb-item">
|
|
|
|
<a href="#">Dashboard</a>
|
|
|
|
</li>
|
2018-12-27 18:51:29 +00:00
|
|
|
<li class="breadcrumb-item">Found</li>
|
|
|
|
<li class="breadcrumb-item active">Add</li>
|
2018-12-27 07:27:47 +00:00
|
|
|
</ol>
|
|
|
|
|
2018-12-30 12:26:45 +00:00
|
|
|
<div id="alertmessage" class="collapse alert alert-danger" role="alert">
|
|
|
|
This is a danger alert—check it out!
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<div id="successmessage" class="collapse alert alert-success" role="alert">
|
|
|
|
A simple success alert—check it out!
|
|
|
|
</div>
|
|
|
|
|
2018-12-27 07:27:47 +00:00
|
|
|
<!-- Area Chart Example-->
|
|
|
|
<div class="card mb-3">
|
|
|
|
<div class="card-header">
|
|
|
|
<i class="fas fa-plus"></i>
|
|
|
|
Insert Item into DB
|
|
|
|
</div>
|
|
|
|
<div class="card-body">
|
2018-12-30 12:26:45 +00:00
|
|
|
<form method="POST" action="/action.php?action=add_found" id="found_form">
|
2018-12-27 18:51:29 +00:00
|
|
|
<p><input type="text" class="form-control" placeholder="WANN" name="wann" value="<?php echo date("Y-m-d H:i:s");?>"></p>
|
2018-12-27 07:27:47 +00:00
|
|
|
<p><input type="text" class="form-control" placeholder="WO" name="wo"></p>
|
|
|
|
<p><input type="text" class="form-control" placeholder="WAS" name="was"></p>
|
2018-12-30 12:26:45 +00:00
|
|
|
<p><button type="submit" class="form-control" onclick="testajax(); return false;">Submit</button></p>
|
2018-12-27 07:27:47 +00:00
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
<div class="card-footer small text-muted">Updated yesterday at 11:59 PM</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
<!-- /.container-fluid -->
|
|
|
|
|
|
|
|
|
2018-12-30 12:26:45 +00:00
|
|
|
<script>
|
|
|
|
|
|
|
|
function testajax(){
|
|
|
|
$.post( "/ajax.php?action=add_found", $( "#found_form" ).serialize() ).done(function( data ) {;
|
|
|
|
reply = JSON.parse(data);
|
|
|
|
if(reply.status == "ok"){
|
|
|
|
$( "#lost_form" ).trigger("reset");
|
|
|
|
$("#alertmessage").collapse('hide');
|
|
|
|
$("#successmessage").html(reply.message).collapse('show');
|
|
|
|
}else{
|
|
|
|
$("#successmessage").collapse('hide');
|
|
|
|
$("#alertmessage").html(reply.message).collapse('show');
|
|
|
|
}
|
|
|
|
}).fail(function() {
|
|
|
|
$("#successmessage").collapse('hide');
|
|
|
|
$("#alertmessage").html("error").collapse('show');
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
2018-12-27 07:27:47 +00:00
|
|
|
|
|
|
|
|
|
|
|
<!-- Bootstrap core JavaScript-->
|
2018-12-30 05:38:05 +00:00
|
|
|
<script src="/vendor/jquery/jquery.min.js"></script>
|
|
|
|
<script src="/vendor/bootstrap/js/bootstrap.bundle.min.js"></script>
|
2018-12-27 07:27:47 +00:00
|
|
|
|
|
|
|
<!-- Core plugin JavaScript-->
|
2018-12-30 05:38:05 +00:00
|
|
|
<script src="/vendor/jquery-easing/jquery.easing.min.js"></script>
|
2018-12-27 07:27:47 +00:00
|
|
|
|
|
|
|
<!-- Page level plugin JavaScript-->
|
2018-12-30 05:38:05 +00:00
|
|
|
<script src="/vendor/chart.js/Chart.min.js"></script>
|
2018-12-27 07:27:47 +00:00
|
|
|
|
|
|
|
<!-- Custom scripts for all pages-->
|
2018-12-30 05:38:05 +00:00
|
|
|
<script src="/js/sb-admin.min.js"></script>
|
2018-12-27 07:27:47 +00:00
|
|
|
|
|
|
|
<!-- Demo scripts for this page-->
|
2018-12-30 05:38:05 +00:00
|
|
|
<script src="/js/demo/chart-area-demo.js"></script>
|
|
|
|
<script src="/js/demo/chart-bar-demo.js"></script>
|
|
|
|
<script src="/js/demo/chart-pie-demo.js"></script>
|