<?php
$values = $_GET['branch'];
  include 'connection.php';
  
 //inquiry categorie
if(isset($_POST['update12']))
{
  $InquirySno = isset($_POST['InquirySno'])?$_POST['InquirySno']:null;
  $InquiryName = isset($_POST['InquiryName'])?$_POST['InquiryName']:null;
    $InquiryEmail = isset($_POST['InquiryEmail'])?$_POST['InquiryEmail']:null;
    $InquiryPhone =  isset($_POST['InquiryPhone'])?$_POST['InquiryPhone']:null;
    $InquiryCourse =  isset($_POST['InquiryPhone'])?$_POST['InquiryPhone']:null;
    $InquiryMessage =  isset($_POST['InquiryMessage'])?$_POST['InquiryMessage']:null;
    $branch = isset($_POST['branch'])?$_POST['branch']:null;

  $result = mysqli_query($sql_con, "UPDATE `inquiry` SET `Name`='$InquiryName', `E_Mail`=' $InquiryEmail', `PhoneNo`='$InquiryPhone',`course`='$InquiryCourse',`Status`='$InquiryMessage',`Branch`='$branch' WHERE Sno='$InquirySno'");
 

}
if(isset($_POST['delete12']))
{
 $InquirySno = isset($_POST['InquirySno'])?$_POST['InquirySno']:null;
$result1 = mysqli_query($sql_con,"DELETE FROM `inquiry` WHERE Sno='$InquirySno'");

}
  
?>


<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Modi Traning Institute</title>
    <!-- ================= Favicon ================== -->
    <!-- Standard -->
    <link rel="shortcut icon" href="http://placehold.it/64.png/000/fff">
    <!-- Retina iPad Touch Icon-->
    <link rel="apple-touch-icon" sizes="144x144" href="http://placehold.it/144.png/000/fff">
    <!-- Retina iPhone Touch Icon-->
    <link rel="apple-touch-icon" sizes="114x114" href="http://placehold.it/114.png/000/fff">
    <!-- Standard iPad Touch Icon-->
    <link rel="apple-touch-icon" sizes="72x72" href="http://placehold.it/72.png/000/fff">
    <!-- Standard iPhone Touch Icon-->
    <link rel="apple-touch-icon" sizes="57x57" href="http://placehold.it/57.png/000/fff">
    <!-- Styles -->
    <link href="assets/css/lib/select2/select2.min.css" rel="stylesheet">
    <link href="assets/css/lib/font-awesome.min.css" rel="stylesheet">
    <link href="assets/css/lib/themify-icons.css" rel="stylesheet">
    <link href="assets/css/lib/menubar/sidebar.css" rel="stylesheet">
    <link href="assets/css/lib/bootstrap.min.css" rel="stylesheet">
    <link href="assets/css/lib/helper.css" rel="stylesheet">
    <link href="assets/css/style.css" rel="stylesheet">

     <script type="text/javascript" src="https://unpkg.com/xlsx@0.15.1/dist/xlsx.full.min.js"></script>

</head>

<body>
    
            <div class="sidebar sidebar-hide-to-small sidebar-shrink sidebar-gestures">
            <div class="nano">
                <div class="nano-content">
                    <div class="logo"><a href="address.php?BranchName=<?php echo $values; ?>"><!-- <img src="assets/images/logo.png" alt="" /> --><span>Modi Traning Institute</span></a></div>
                    <ul>
                        <li class="label">Main</li>
                        <li><a class="sidebar-sub-toggle"><i class="ti-layout"></i>Website Master <span class="sidebar-collapse-icon ti-angle-down"></span></a>
                            <ul>
                               <li><a href="online-exam-course.php?branch=<?php echo $values; ?>">Online Exam Course Master</a></li>
                         <li><a href="contact.php?branch=<?php echo $values; ?>">Contact Form</a></li>
                          <li><a href="demo.php?branch=<?php echo $values; ?>">Demo Form</a></li>
                          <li><a href="register.php?branch=<?php echo $values; ?>">REG by Website</a></li>
                          <li><a href="enquiry.php?branch=<?php echo $values; ?>">Enquiry Form</a></li>
                         <li><a href="idcard.php?branch=<?php echo $values; ?>">Student Id Card Master</a></li>
                        <li><a href="address.php?BranchName=<?php echo $values; ?>">Address Master</a></li>
                        <li><a href="link.php?branch=<?php echo $values; ?>"> Link Master</a></li>
                        <li><a href="testimonial.php?branch=<?php echo $values; ?>">Testimonial Master</a></li>
                        <li><a href="team.php?branch=<?php echo $values; ?>">Team Master</a></li>
                         <li><a href="gallery.php?branch=<?php echo $values; ?>">Gallery Master</a></li>
                        <li><a href="blog.php?branch=<?php echo $values; ?>">Blog Master</a></li>
                        <li><a href="event.php?branch=<?php echo $values; ?>">Event Master</a></li>
                        <li><a href="course.php?branch=<?php echo $values; ?>">Course Master</a></li>
                        <li><a href="course-content.php?branch=<?php echo $values; ?>">Course Content Master</a></li>
                        <li><a href="batch.php?branch=<?php echo $values; ?>">Batch Master</a></li>
                        <li><a href="course-description.php?branch=<?php echo $values; ?>">Course Description Master</a></li>
                        <li><a href="offer.php?branch=<?php echo $values; ?>">Offer Master</a></li>
                        <li><a href="afflication.php?branch=<?php echo $values; ?>">Afflication Master</a></li>
                        <li><a href="placement.php?branch=<?php echo $values; ?>">Placement Master</a></li>
                            </ul>
                        </li>
                        <li><a class="sidebar-sub-toggle"><i class="ti-layout"></i>Admission Master <span class="sidebar-collapse-icon ti-angle-down"></span></a>
                            <ul>
                                <li><a href="personal.php?branch=<?php echo $values; ?>">Personal Info</a></li>
                                <li><a href="bank.php?branch=<?php echo $values; ?>">Bank Detail</a></li>
                                
                                <li><a href="course-admin.php?branch=<?php echo $values; ?>">Course Detail</a></li>
                                <li><a href="fee.php?branch=<?php echo $values; ?>">Fees Detail</a></li>
                            </ul>
                        </li>
                        <li><a class="sidebar-sub-toggle"><i class="ti-panel"></i>Inquiry <span class="sidebar-collapse-icon ti-angle-down"></span></a>
                            <ul>
                                <li><a href="inquiry.php?branch=<?php echo $values; ?>">Inquiry Form</a></li>
                                <li><a href="inquiry-report.php?branch=<?php echo $values; ?>">All Inquiry Report</a></li>
                                <li><a href="converted.php?branch=<?php echo $values; ?>">Converted</a></li>
                                <li><a href="not-converted.php?branch=<?php echo $values; ?>">Not Converted</a></li>
                            </ul>
                        </li>
                        <li><a class="sidebar-sub-toggle"><i class="ti-layout-grid4-alt"></i>Fees Master <span class="sidebar-collapse-icon ti-angle-down"></span></a>
                            <ul>
                                <li><a href="create-fee.php?branch=<?php echo $values; ?>">Fees Form</a></li>
                               
                                <li><a href="print-fees.php?branch=<?php echo $values; ?>">All Fees Detail</a></li>
                                <li><a href="due-fees.php?branch=<?php echo $values; ?>">Due Fees Detail</a></li>
                            </ul>
                        </li>
                        <li><a class="sidebar-sub-toggle"><i class="ti-heart"></i>Document Master <span class="sidebar-collapse-icon ti-angle-down"></span></a>
                            <ul>
                                <li><a href="document.php?branch=<?php echo $values; ?>">Document</a></li>
                                <li><a href="certificate.php?branch=<?php echo $values; ?>">Certificate</a></li>
                                <li><a href="document-records.php?branch=<?php echo $values; ?>">All Document Records</a></li>
                                <li><a href="Certificate-record.php?branch=<?php echo $values; ?>">All Certificate Records</a></li>
                            </ul>
                        </li>
                         <li><a class="sidebar-sub-toggle"><i class="ti-heart"></i>Certificate Master <span class="sidebar-collapse-icon ti-angle-down"></span></a>
                            <ul>
                                <li><a href="create-certificate.php?branch=<?php echo $values; ?>">Certificate Create</a></li>
                                <li><a href="print-certificate.php?branch=<?php echo $values; ?>">All Certificate Records</a></li>
                            </ul>
                        </li>
                        <li><a href="../HRMS/HRMS/security.php?branch=<?php echo $values; ?>" target="_blank"><i class="ti-user"></i> HRMS Login</a></li>
                        <li><a href="../admin-dashboard.php"><i class="ti-close"></i> Logout</a></li>
                    </ul>
                </div>
            </div>
        </div>
        <!-- /# sidebar -->


    <div class="header">
        <div class="container-fluid">
            <div class="row">
                <div class="col-lg-12">
                    <div class="float-left">
                        <div class="hamburger sidebar-toggle">
                            <span class="line"></span>
                            <span class="line"></span>
                            <span class="line"></span>
                        </div>
                    </div>
                    
            </div>
        </div>
    </div>


    
    <div class="content-wrap">
        <div class="main">
            <div class="container-fluid">
                <div class="row">
                    <div class="col-lg-8 p-r-0 title-margin-right">
                        <div class="page-header">
                            <div class="page-title">
                                <h1>Converted Enquiry Application Information</h1>
                            </div>
                        </div>
                    </div>
                    
                </div>
                <!-- /# row -->
                <section id="main-content">
                    <div class="row">
                        <div class="col-lg-12">
                            <div class="card">
                                <div class="card-body">
                                     <form method="post">
                                        <div class="row">
                    <div class="col-md-8">
                        <div class="row">
                            <div class="col-4">
                        <input type="text" name="search1" class="form-control" placeholder="Search Here .....">
                    </div>
                    <div class="col-4">
                        <input type="date" name="start" class="form-control rounded" placeholder="Search" />
                    </div>
                    <div class="col-4">
                        <input type="date" name="end" class="form-control rounded" placeholder="Search" />
                    </div>
                </div>
            </div>
                    <div class="col-md-4">
                     &nbsp;&nbsp;<input type="submit" class="btn btn-info" name="search" value="Search">
                      <button onclick="ExportToExcel('xlsx')" class="btn btn-success">Excel</button>
             <input type="button" value="PDF" id="btPrint" onclick="createPDF()" class="btn btn-success" />
                    </div>
                    
                </div>
                 
            </form>
           
                                    <div class="table-responsive" >
                                        <div id="tab">
                                    <table class="table table-bordered" id="tblData">
    <thead>
      <tr>
        <th>Sno</th>
        <th>Branch</th>
        <th>Enquiry Date</th>
        <th>Name</th>
        <th>Email</th>
        <th>Phone No</th>
        <th>Address</th>
        <th>Pincode</th>
        <th>Date of Birth</th>
        <th>Course</th>
        <th>Gender</th>
        <th>Categories</th>
        <th>Father's Name / Husband Name</th>
        <th>Mother Name</th>
        <th>Occupation</th>
        <th>Occupation Address</th>
        <th>Qualify Exam</th>
        <th>University</th>
        <th>Year</th>
        <th>Subject</th>
        <th>Marks Obtained</th>
        <th>Total Marks</th>
        <th>Percentage</th>
        <th>Organisation</th>
        <th>From</th>
        <th>To</th>
        <th>Designation</th>
        <th>Image</th>
        <th>Status</th>
      </tr>
    </thead>
    <tbody>
     <?php
 $search = isset($_POST['search1'])?$_POST['search1']:null;

if($search==null && isset($_POST['search']))
{
 $original_date = isset($_POST['start'])?$_POST['start']:null;
$timestamp = strtotime($original_date);
$new_date = date("Y-m-d", $timestamp);


$original_date1 = isset($_POST['end'])?$_POST['end']:null;
$timestamp1 = strtotime($original_date1);
$new_date1 = date("Y-m-d", $timestamp1);

 $oquery = mysqli_query($sql_con,"SELECT * FROM inquiry WHERE RegistrationDate BETWEEN '$new_date' AND '$new_date1'");
 while($row21 = mysqli_fetch_array($oquery))
{
  $Inquiryid = $row21["Sno"];
  $InquiryName = $row21["Name"];
  $InquiryEmail = $row21["E_mail"];
  $InquiryPhone = $row21["PhoneNo"];
   $InquiryCourse = $row21["course"];
  $InquiryMessage = $row21["Status"];
  $branch = $row21["Branch"];
  $address = $row21["Address"];
  $date = $row21["RegistrationDate"];
  $pincode = $row21["Pincode"];
  $image = $row21["Image"];
  $birth = $row21["DateOfBirth"];
  $gender = $row21["Gender"];
  $categories = $row21["Categories"];
  $father = $row21["FatherName"];
  $mother = $row21["MotherName"];
  $occupation = $row21["Occupation"];
  $occadd = $row21["OccupationAddress"];
  $qualify = $row21["QualifyExam"];
  $university = $row21["University"];
  $year = $row21["Year"];
  $subject = $row21["Subject"];
  $marks = $row21["Marks"];
  $total = $row21["Total"];
  $percentage = $row21["Percentage"];
  $orgination = $row21["Organisation"];
  $from = $row21["From"];
  $to = $row21["DateTo"];
  $designation = $row21["Designation"];
?>    
 <tr>
    <td><?php echo $Inquiryid;?></td>
    <td><?php echo $branch; ?></td>
    <td><?php echo $date; ?></td>
<td><?php echo $InquiryName;?></td>
        <td><?php echo $InquiryEmail;?></td>
        <td><?php echo $InquiryPhone;?></td>
        <td><?php echo $address; ?></td>
        <td><?php echo $pincode; ?></td>
        <td><?php echo $birth; ?></td>
         <td><?php echo $InquiryCourse;?></td>
        <td><?php echo $gender;?></td>
        <td><?php echo $categories; ?></td>
        <td><?php echo $father; ?></td>
        <td><?php echo $mother; ?></td>
        <td><?php echo $occupation; ?></td>
        <td><?php echo $occadd; ?></td>
        <td><?php echo $qualify; ?></td>
        <td><?php echo $university; ?></td>
        <td><?php echo $year; ?></td>
        <td><?php echo $subject; ?></td>
        <td><?php echo $marks; ?></td>
        <td><?php echo $total; ?></td>
        <td><?php echo $percentage; ?></td>
        <td><?php echo $orgination; ?></td>
        <td><?php echo $from; ?></td>
        <td><?php echo $to; ?></td>
        <td><?php echo $designation; ?></td>
        <td><img src="master/images/<?php echo $image; ?>" style="height: 70px;"></td>
        <td><?php echo $InquiryMessage;?></td>

    <td><button type="button" class="btn btn-primary" data-toggle="modal" onclick="document.getElementById('Inquiryid').value = '<?php echo $Inquiryid; ?>';document.getElementById('InquiryName').value = '<?php echo $InquiryName; ?>';document.getElementById('InquiryEmail').value = '<?php echo $InquiryEmail; ?>';document.getElementById('InquiryPhone').value = '<?php echo $InquiryPhone; ?>';document.getElementById('InquiryCourse').value = '<?php echo $InquiryCourse; ?>';document.getElementById('InquiryMessage').value = '<?php echo $InquiryMessage; ?>';document.getElementById('Branch').value = '<?php echo $branch; ?>';" data-target="#myModal12">Details</button></td></tr>
  <?php
}
}
      else if(isset($_POST['search']))
        { 
$result9 = mysqli_query($sql_con,"SELECT * FROM `inquiry` where Name like '%$search%' or PhoneNo like '%$search%' or E_mail like '%$search%' or course like '%$search%' or Status like '%$search%' or Branch like '%$search%' or Address like '%$search%' or RegistrationDate like '%$search%' or Pincode like '%$search%' or Image like '%$search%' or DateOfBirth like '%$search%' or Gender like '%$search%' or Categories like '%$search%' or FatherName like '%$search%' or MotherName like '%$search%' or Occupation like '%$search%' or OccupationAddress like '%$search%' or QualifyExam like '%$search%' or University like '%$search%' or Year like '%$search%' or Subject like '%$search%' or Marks like '%$search%' or Total like '%$search%' or Percentage like '%$search%' or Organisation like '%$search%' or DateTo like '%$search%' or Designation like '%$search%'");
   while($sub1 = mysqli_fetch_array($result9))
{
  $Inquiryid = $sub1["Sno"];
  $InquiryName = $sub1["Name"];
  $InquiryEmail = $sub1["E_mail"];
  $InquiryPhone = $sub1["PhoneNo"];
   $InquiryCourse = $sub1["course"];
  $InquiryMessage = $sub1["Status"];
  $branch = $sub1["Branch"];
  $address = $sub1["Address"];
  $date = $sub1["RegistrationDate"];
  $pincode = $sub1["Pincode"];
  $image = $sub1["Image"];
  $birth = $sub1["DateOfBirth"];
  $gender = $sub1["Gender"];
  $categories = $sub1["Categories"];
  $father = $sub1["FatherName"];
  $mother = $sub1["MotherName"];
  $occupation = $sub1["Occupation"];
  $occadd = $sub1["OccupationAddress"];
  $qualify = $sub1["QualifyExam"];
  $university = $sub1["University"];
  $year = $sub1["Year"];
  $subject = $sub1["Subject"];
  $marks = $sub1["Marks"];
  $total = $sub1["Total"];
  $percentage = $sub1["Percentage"];
  $orgination = $sub1["Organisation"];
  $from = $sub1["From"];
  $to = $sub1["DateTo"];
  $designation = $sub1["Designation"];
?>    
 <tr>
    <td><?php echo $Inquiryid;?></td>
    <td><?php echo $branch; ?></td>
    <td><?php echo $date; ?></td>
<td><?php echo $InquiryName;?></td>
        <td><?php echo $InquiryEmail;?></td>
        <td><?php echo $InquiryPhone;?></td>
        <td><?php echo $address; ?></td>
        <td><?php echo $pincode; ?></td>
        <td><?php echo $birth; ?></td>
         <td><?php echo $InquiryCourse;?></td>
        <td><?php echo $gender;?></td>
        <td><?php echo $categories; ?></td>
        <td><?php echo $father; ?></td>
        <td><?php echo $mother; ?></td>
        <td><?php echo $occupation; ?></td>
        <td><?php echo $occadd; ?></td>
        <td><?php echo $qualify; ?></td>
        <td><?php echo $university; ?></td>
        <td><?php echo $year; ?></td>
        <td><?php echo $subject; ?></td>
        <td><?php echo $marks; ?></td>
        <td><?php echo $total; ?></td>
        <td><?php echo $percentage; ?></td>
        <td><?php echo $orgination; ?></td>
        <td><?php echo $from; ?></td>
        <td><?php echo $to; ?></td>
        <td><?php echo $designation; ?></td>
        <td><img src="master/images/<?php echo $image; ?>" style="height: 70px;"></td>
        <td><?php echo $InquiryMessage;?></td>

    <td><button type="button" class="btn btn-primary" data-toggle="modal" onclick="document.getElementById('Inquiryid').value = '<?php echo $Inquiryid; ?>';document.getElementById('InquiryName').value = '<?php echo $InquiryName; ?>';document.getElementById('InquiryEmail').value = '<?php echo $InquiryEmail; ?>';document.getElementById('InquiryPhone').value = '<?php echo $InquiryPhone; ?>';document.getElementById('InquiryCourse').value = '<?php echo $InquiryCourse; ?>';document.getElementById('InquiryMessage').value = '<?php echo $InquiryMessage; ?>';document.getElementById('Branch').value = '<?php echo $branch; ?>';" data-target="#myModal12">Details</button></td></tr>
  <?php
}
}
else
{
$result = mysqli_query($sql_con,"SELECT * FROM `inquiry` where Status='Converted' and Branch='$values' ");
while($row = mysqli_fetch_array($result))
{
  $Inquiryid = $row["Sno"];
  $InquiryName = $row["Name"];
  $InquiryEmail = $row["E_mail"];
  $InquiryPhone = $row["PhoneNo"];
   $InquiryCourse = $row["course"];
  $InquiryMessage = $row["Status"];
  $branch = $row["Branch"];
  $address = $row["Address"];
  $date = $row["RegistrationDate"];
  $pincode = $row["Pincode"];
  $image = $row["Image"];
  $birth = $row["DateOfBirth"];
  $gender = $row["Gender"];
  $categories = $row["Categories"];
  $father = $row["FatherName"];
  $mother = $row["MotherName"];
  $occupation = $row["Occupation"];
  $occadd = $row["OccupationAddress"];
  $qualify = $row["QualifyExam"];
  $university = $row["University"];
  $year = $row["Year"];
  $subject = $row["Subject"];
  $marks = $row["Marks"];
  $total = $row["Total"];
  $percentage = $row["Percentage"];
  $orgination = $row["Organisation"];
  $from = $row["From"];
  $to = $row["DateTo"];
  $designation = $row["Designation"];
  
  ?>
   <tr>
     <td><?php echo $Inquiryid;?></td>
    <td><?php echo $branch; ?></td>
    <td><?php echo $date; ?></td>
<td><?php echo $InquiryName;?></td>
        <td><?php echo $InquiryEmail;?></td>
        <td><?php echo $InquiryPhone;?></td>
        <td><?php echo $address; ?></td>
        <td><?php echo $pincode; ?></td>
        <td><?php echo $birth; ?></td>
         <td><?php echo $InquiryCourse;?></td>
        <td><?php echo $gender;?></td>
        <td><?php echo $categories; ?></td>
        <td><?php echo $father; ?></td>
        <td><?php echo $mother; ?></td>
        <td><?php echo $occupation; ?></td>
        <td><?php echo $occadd; ?></td>
        <td><?php echo $qualify; ?></td>
        <td><?php echo $university; ?></td>
        <td><?php echo $year; ?></td>
        <td><?php echo $subject; ?></td>
        <td><?php echo $marks; ?></td>
        <td><?php echo $total; ?></td>
        <td><?php echo $percentage; ?></td>
        <td><?php echo $orgination; ?></td>
        <td><?php echo $from; ?></td>
        <td><?php echo $to; ?></td>
        <td><?php echo $designation; ?></td>
        <td><img src="master/images/<?php echo $image; ?>" style="height: 70px;"></td>
        <td><?php echo $InquiryMessage;?></td>

    <td><button type="button" class="btn btn-primary" data-toggle="modal" onclick="document.getElementById('Inquiryid').value = '<?php echo $Inquiryid; ?>';document.getElementById('InquiryName').value = '<?php echo $InquiryName; ?>';document.getElementById('InquiryEmail').value = '<?php echo $InquiryEmail; ?>';document.getElementById('InquiryPhone').value = '<?php echo $InquiryPhone; ?>';document.getElementById('InquiryCourse').value = '<?php echo $InquiryCourse; ?>';document.getElementById('InquiryMessage').value = '<?php echo $InquiryMessage; ?>';document.getElementById('branch').value = '<?php echo $branch; ?>';" data-target="#myModal12">Details</button></td></tr>
  <?php
}
}
       ?>
        
      
      
    </tbody>
  </table></div>
  <div class="container">
  

  <!-- The Modal -->
  <div class="modal fade" id="myModal12">
    <div class="modal-dialog modal-lg">
      <div class="modal-content">
      
        <!-- Modal Header -->
        <div class="modal-header">
          <h4 class="modal-title">Inquiry Information</h4>
          <button type="button" class="close" data-dismiss="modal">&times;</button>
        </div>
        
        <!-- Modal body -->
        <div class="modal-body">
          <div class="container">

          <form method="post" enctype="multipart/form-data">
            <div class="form-group has-success">
        <label for="Name">Sno </label>
    <input type="name" class="form-control" id="Inquiryid" placeholder="Location" name="InquirySno" >
  </div>
  <div class="form-group has-success">
    <label for="Name">Name </label>
    <input type="text" class="form-control" id="InquiryName" placeholder="Name" name="InquiryName" >
  </div>
  <div class="form-group has-warning">
    <label for="landmark">Email</label>
    <input type="email" class="form-control" id="InquiryEmail" placeholder="Email" name="InquiryEmail">
  </div>  
  <div class="form-group has-error">
    <label for="country">Phone</label>
     <input type="text" class="form-control" id="InquiryPhone" placeholder="Phone" name="InquiryPhone">
  </div>  
  <div class="form-group has-error">
    <label for="country">Course</label>
     <input type="text" class="form-control" id="InquiryCourse" placeholder="Course" name="InquiryCourse">
  </div>  
  <div class="form-group has-error">
    <label for="country">Branch</label>
     <input type="text" class="form-control" id="branch" placeholder="Branch" name="branch">
  </div>  
  <div class="form-group has-error">
    <label for="country">Status</label>
     <select class="form-control" id="InquiryMessage" placeholder="Message" name="InquiryMessage">
        <option>Select Status</option>
        <option>Converted</option>
        <option>Not Converted</option> 
     </select>
  </div> 

  <button type="submit" name="update12" class="btn btn-info">Update Inquiry</button>
  <button type="submit" name="delete12" class="btn btn-info">Delete Inquiry</button>
</form>

</div>
        </div>
        
        <!-- Modal footer -->
        <div class="modal-footer">
          <button type="button" class="btn btn-danger" data-dismiss="modal">Close</button>
        </div>
        
      </div>
    </div>
  </div>
  
</div>

                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                    <div class="row">
                        <div class="col-lg-6">
                            <div class="footer">
                                <p>All right reserved by- <a href="">Modi Training Institute</a> 
                            </div>
                        </div>
                        <div class="col-lg-6">
                            <div class="footer" style="text-align: right;">
                                <p style="text-align: right;">Managed By- <a href="https://www.kiyanchsolutions.com/" target="_blank">Kiyan Ch Solutions</a> 
                            </div>
                        </div>
                    </div>
                </section>
            </div>
        </div>
    </div>
    
    <!-- jquery vendor -->
    <script src="assets/js/lib/jquery.min.js"></script>
    <script src="assets/js/lib/jquery.nanoscroller.min.js"></script>
    <!-- nano scroller -->
    <script src="assets/js/lib/menubar/sidebar.js"></script>
    <script src="assets/js/lib/preloader/pace.min.js"></script>
    <!-- sidebar -->
    
    <!-- bootstrap -->
    <!-- Select2 -->
    <script src="assets/js/lib/select2/select2.full.min.js"></script>
    <script src="assets/js/lib/form-validation/jquery.validate.min.js"></script>
    <script src="assets/js/lib/form-validation/jquery.validate-init.js"></script>
    <script src="assets/js/lib/bootstrap.min.js"></script><script src="assets/js/scripts.js"></script>
    <!-- scripit init-->

     <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.22/pdfmake.min.js"></script>
    <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/html2canvas/0.4.1/html2canvas.min.js"></script>
    
       <script>
    function createPDF() {
        var sTable = document.getElementById('tab').innerHTML;

        var style = "<style>";
        style = style + "table {width: 100%;font: 17px Calibri;}";
        style = style + "table, th, td {border: solid 1px #DDD; border-collapse: collapse;";
        style = style + "padding: 2px 3px;text-align: center;}";
        style = style + "</style>";

        // CREATE A WINDOW OBJECT.
        var win = window.open('', '', 'height=700,width=700');

        win.document.write('<html><head>');
        win.document.write('<title>Profile</title>');   // <title> FOR PDF HEADER.
        win.document.write(style);          // ADD STYLE INSIDE THE HEAD TAG.
        win.document.write('</head>');
        win.document.write('<body>');
        win.document.write(sTable);         // THE TABLE CONTENTS INSIDE THE BODY TAG.
        win.document.write('</body></html>');

        win.document.close();   // CLOSE THE CURRENT WINDOW.

        win.print();    // PRINT THE CONTENTS.
    }
</script>
    
 <script>

        function ExportToExcel(type, fn, dl) {
            var elt = document.getElementById('tblData');
            var wb = XLSX.utils.table_to_book(elt, { sheet: "sheet1" });
            return dl ?
                XLSX.write(wb, { bookType: type, bookSST: true, type: 'base64' }) :
                XLSX.writeFile(wb, fn || ('MySheetName.' + (type || 'xlsx')));
        }

    </script>

<script type="text/javascript">
    function Export2Doc(element, filename = ''){
        var html = "<html xmlns:o='urn:schemas-microsoft-com:office:office' xmlns:w='urn:schemas-microsoft-com:office:word' xmlns='http://www.w3.org/TR/REC-html40'><head><meta><title>Export HTML To Doc</title></head><body>";
        var footer = "</body></html>";
        var html = html+document.getElementById(element).innerHTML+footer;
    
        
        //link url
        var url = 'data:application/vnd.ms-word;charset=utf-8,' + encodeURIComponent(html);
        
        //file name
        filename = filename?filename+'.doc':'document.doc';
        
        // Creates the  download link element dynamically
        var downloadLink = document.createElement("a");
    
        document.body.appendChild(downloadLink);
        
        //Link to the file
        downloadLink.href = url;
            
        //Setting up file name
        downloadLink.download = filename;
            
        //triggering the function
        downloadLink.click();
        //Remove the a tag after donwload starts.
        document.body.removeChild(downloadLink);
    }
</script>

<script>
  
 $(document).ready(function () {
    $("#tblData").table2excel({
        filename: "Students.xls"
    });
 });
  
</script>

</body>

</html>