<?php
    if(isset($_POST) && $_POST['title']){
		$wpdb->query("INSERT INTO `slider` (`title`,`description`,`image`)
        VALUE ('".$_POST['title']."','".$_POST['description']."','".$_POST['image']."')");
        echo "<script>window.location.href='?page=allslider';</script>";
	}
?>
<form action="" method="post">
    <div class="container mt-5">
        <div class="row">
            <div class="col-lg-8 col-12">
                <div class="mb-3">
                    <label for="jassSlider" class="form-label"><h5>Add Slider</h5></label>
                    <input type="text" class="form-control form-control-lg" id="jassSlider" name="title" placeholder="Title">
                </div>
                <div class="mb-3">
                    <label for="jassSlider2" class="form-label"><h5>Description</h5></label>
                    <input type="text" class="form-control form-control-lg" id="jassSlider2" name="description" placeholder="Description">
                </div>
                <div class="mb-3">
                    <label for="jassSlider3" class="form-label"><h5>Image File</h5></label>
                    <input type="text" name="image" value="" id="getSlider" hidden>
                    <img src="<?php echo''.plugins_url('jaas-slider/image/upload-image.jpg').''; ?>" class="d-block w-100" id="bttnImage" height="400px">
                </div>
                <div class="mb-3">
                    <button type="submit" class="btn btn-primary mb-3">Save</button>
                </div>
            </div>
        </div>
    </div>
</form>