Mini Shell

Direktori : /home/rizant5/public_html-1210/admin/
Upload File :
Current File : /home/rizant5/public_html-1210/admin/apply-internship.php

<?php 

require_once("../config.php");

require_once("function-file.php");

require_once("function-menu.php");

cookiecheck();

if((!empty($_GET['action']))&&($_GET['action']=='delete')){

	$id=$_GET['id'];

	$conn->exec("delete from tab_content where id='$id'");

	header("location:apply-internship.php");

}?>

<!DOCTYPE html>

<html>

  <head>

    <meta charset="utf-8">

    <meta http-equiv="X-UA-Compatible" content="IE=edge">

    <title>Internship</title>

    <!-- Tell the browser to be responsive to screen width -->

    <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">

    <?php  cssfile();datatablecss();?>

    <style>.selected{color:red;}</style>

  </head>

  <body class="hold-transition skin-blue layout-top-nav">

    <!-- Site wrapper -->

    <div class="wrapper">

<?php headermenu();?>

      <!-- =============================================== -->

      <!-- Content Wrapper. Contains page content -->

      <div class="content-wrapper">

        <!-- Content Header (Page header) -->

        <!-- Main content -->

        <div class="col-sm-12">

        <section class="content">

          <!-- Default box -->

          <div class="box">

            <div class="box-header with-border">

              <h3 class="box-title">Internship</h3>

              <div class="box-tools pull-right">

                <a href="apply-internship-new.php" class="btn btn-primary btn-sm" ><i class="fa fa-plus"></i> Add Tab</a>

              </div>

            </div>

            <div class="box-body">

              <table class="table table-bordered table-striped dataTable" id="data-table">

                <thead><tr><th>Heading</th><th>Content</th><th>Action</th></tr></thead>

                 <tbody>

                 	<?php  $data=$conn->prepare("select * from tab_content where type='2'");

					$data->execute();$result=$data->fetchall();$i=1;

					foreach($result as $row){

						echo "<tr>";

						echo "<td>$row[heading]</td>";

						echo "<td>$row[content]</td>";

						echo "<td><a href='apply-internship-edit.php?id=$row[id]' title='Edit' class='btn btn-info btn-xs'>Edit</a>&nbsp;&nbsp;";?><a href='apply-internship.php?action=delete&id=<?php echo $row['id'];?>' onclick="return confirm('Are you sure you want to delete?')" title='Delete' class='btn btn-danger btn-xs'>Delete</a></td><?php

						echo "</tr>";

						$i++;

					}

					?>

                 </tbody>

                 </table>

            </div><!-- /.box-body -->

          </div><!-- /.box -->

        </section><!-- /.content -->

        </div>

      </div></div><!-- /.content-wrapper -->

      <?php footer();?>

    </div><!-- ./wrapper -->

   <?php jsfile();datatablejs();?>

    <script>
      $('#data-table').dataTable();
    </script>

  </body>

</html>


Zerion Mini Shell 1.0