     <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script> 
    <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script> 
    <!--data table--> 
    <link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/v/bs/pdfmake-0.1.18/dt-1.10.12/b-1.2.2/b-colvis-1.2.2/b-html5-1.2.2/b-print-1.2.2/r-2.1.0/datatables.min.css" /> 
    <script type="text/javascript" src="https://cdn.datatables.net/v/bs/pdfmake-0.1.18/dt-1.10.12/b-1.2.2/b-colvis-1.2.2/b-html5-1.2.2/b-print-1.2.2/r-2.1.0/datatables.min.js"></script> 
    <!--/.data table--> 
  <div class="content-wrapper">
    <!-- Content Header (Page header) -->
    <section class="content-header">
      <div class="container-fluid">
        <div class="row mb-2">
          <div class="col-sm-6">
            <h1>All New Reviews</h1>
          </div>
          <div class="col-sm-6">
            <ol class="breadcrumb float-sm-right">
              <li class="breadcrumb-item"><a href="#">Home</a></li>
              <li class="breadcrumb-item active">All New Reviews</li>
            </ol>
          </div>
        </div>
      </div><!-- /.container-fluid -->
    </section>

    <!-- Main content -->
    <section class="content">
      <div class="row">
        <div class="col-12">
          <div class="card">
            <div class="card-header">
              <h3 class="card-title">All New Reviews View On This Page You Can Aprove Or Delete Review From This Page</h3>
            </div>
			<?php
              $success = $this->session->flashdata('success');
               if(isset($success)){  ?>
            <div class="alert alert-success">
              <a href="#" class="close" data-dismiss="alert" aria-label="close">&times;</a>
              <?php echo $this->session->flashdata('success');?>
          </div>
          <?php } ?>

          <?php
              $same = $this->session->flashdata('same');
               if(isset($same)){  ?>
            <div class="alert alert-warning">
              <a href="#" class="close" data-dismiss="alert" aria-label="close">&times;</a>
              <?php echo $this->session->flashdata('same');?>
          </div>
          <?php } ?>
          <?php
              $same = $this->session->flashdata('error');
               if(isset($same)){  ?>
            <div class="alert alert-danger">
              <a href="#" class="close" data-dismiss="alert" aria-label="close">&times;</a>
              <?php echo $this->session->flashdata('error');?>
          </div>
          <?php } ?>
            <!-- /.card-header -->
            <div class="card-body">
              <table id="mytable" class="table table-bordered table-striped">
                <thead>
                <tr>
                                        <th>Product Name</th>
                                        <th>Customer Name</th>
                                        <th>Email</th>
                                        <th>Stars</th>
                                        <th>Review</th>
                                        <th>Date</th>
                                        
                                        <th>Action</th>
                                        
                                    </tr>
                </thead>
                 <tbody>
                                    <?php
                                    if($view_all != 0){
                                        $count = count($view_all);
                                        if($count != 0){
                                            foreach ($view_all as $row) {
                                                

                                    ?>
                                    <tr>
                                        <td><?php echo  $res = preg_replace("/[^a-zA-Z]/", " ", $row->product_slug); ?></td>
                                        <td><?php echo $row->name;?></td>
                                        <td><?php echo $row->email;?></td>
                                        <td><?php echo $row->stars;?></td>
                                        <td><?php echo $row->review;?></td>
                                        <td><?php echo $row->date;?></td>
                                        
                                        <td>
                                            <a href="<?php echo base_url('admin/Reviews/mark/').$row->id; ?>" class="btn btn-info" title="Click When Your Agree With this Review"><span class="fa fa-pencil"></span> APPROVE THIS REVIEW </a>
                                            <a href="<?php echo base_url('admin/Reviews/delete/').$row->id; ?>" class="btn btn-danger" title="Click If You Want to Remove This Review"><span class="fa fa-trash"></span> DELETE</a>
                                        </td>
                                        
                                    </tr>
                                    <?php } } } ?>
                                    
                                </tbody>
                <tfoot>
                <tr>
                  <th>Product Name</th>
                                        <th>Customer Name</th>
                                        <th>Email</th>
                                        <th>Stars</th>
                                        <th>Review</th>
                                        <th>Date</th>
                                        
                                        <th>Action</th>
                </tr>
                </tfoot>
              </table>
            </div>
            <!-- /.card-body -->
          </div>
		  </div>
        <!-- /.col -->
      </div>
      <!-- /.row -->
    </section>
    <!-- /.content -->
  </div>
 <script type="text/javascript"> 
        $(document).ready(function() { 
            $("#mytable").dataTable(); 
        }); 
    </script>