<?php $__env->startSection('title'); ?>
<?php echo e($title); ?>

<?php $__env->stopSection(); ?>

<?php $__env->startSection('content'); ?>

<div class="row">    
    <div class="col-lg-12">
        <div class="panel panel-default">
            <div class="panel-heading">Contacts</div>
            <!-- /.panel-heading -->
            <div class="panel-body">
                <div class="table-responsive">
                    <table class="table table-condensed">
                        <thead>
                            <tr>
                                <th>Name</th>
                                <th>Email</th>
                                <th>Content</th>
                                <th>Created At</th>
                                <th></th>
                            </tr>
                        </thead>
                        <tbody>
                        	<?php foreach($contacts as $contact): ?>
                            <tr>
                                <td><?php echo e($contact -> fullname); ?></td>
                                <td><?php echo e($contact -> email); ?></td>
                                <td><?php echo e(substr($contact -> content,0,100)); ?></td> 
                                <td><?php echo e(date('d-m-Y H:i:s', strtotime($contact -> created_at))); ?></td>
                                <td><a href='destroy/<?php echo e($contact -> id); ?>' class='btn btn-danger btn-xs'><i class='fa fa-trash-o'></i></a></td>    
                            </tr>
                            <?php endforeach; ?>                            
                        </tbody>
                    </table>
                </div>
                <!-- /.table-responsive -->
            </div>
            <!-- /.panel-body -->
        </div>
        <!-- /.panel -->
    </div>
    <!-- /.col-lg-6 -->
</div>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('template.admin', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>