<head>
<script type="text/javaScript" src="components/com_wishlogue/assets/jquery.magnifier.js"></script>
</head>
<?php
    defined('_JEXEC') or die('Restricted access');
    jimport('joomla.application.component.model');
    $getallads = $this->getallads;
    $document = JFactory::getDocument();
    $document->addStyleSheet('components'.DS.'com_wishlogue'.DS.'assets'.DS.'jquery.magnifier.js');
?>
<form id="adminForm" action="index.php?option=com_wishlogue&layout=wishlogueadspace" method="POST" name="adminForm" enctype="multipart/form-data">

    <table class="table table-striped">
        <thead>
            <tr>
                <th width="3%">#</th>
                <th width="2%"><input type="checkbox" name="toggle" value="" onclick="Joomla.checkAll(this)" /></th>
                <th width="15%"><?php echo JHtml::_('grid.sort',  'Advertisement URL', 'url', $getallads['order_Dir'], $getallads['order'] ); ?></th>
                <th width="15%"><?php echo JHtml::_('grid.sort',  'Description', 'description', $getallads['order_Dir'], $getallads['order'] ); ?></th>
                <th width="10%" style="text-align:center"><?php echo JHtml::_('grid.sort',  'Image', 'imagename', $getallads['order_Dir'], $getallads['order'] ); ?></th>
                <th width="10%" style="text-align:center"><?php echo JHtml::_('grid.sort',  'Created Date', 'createddate', $getallads['order_Dir'], $getallads['order'] ); ?></th>
                <th width="8%" style="text-align:center" ><?php echo JHtml::_('grid.sort',  'Published', 'status', $getallads['order_Dir'], $getallads['order'] ); ?></th>
                <th width="10%"><?php echo JHtml::_('grid.sort',  'ID', 'id', $getallads['order_Dir'], $getallads['order'] ); ?></th>
            </tr>
        </thead>

       <?php
            $sno = 0;
            foreach($getallads['getallads'] as $adval)
            {
               $checked = JHtml::_('grid.id', $sno, $adval->id);
            ?>
            <tr>
                <td width="3%"><?php echo ($sno+1); ?></td>
                <td width="2%"><?php echo $checked; ?></td>
                <td width="15%"><?php echo $adval->url; ?></td>
                <td width="15%"><?php echo $adval->description; ?></td>
                <td width="10%"><?php echo "<img src='" . JURI::root() . "components/com_wishlogue/images/wishlogueadspace/" . $adval->imagename . "' class='magnify' style='width:50px; height:50px'>"; ?></td>
                <td width="10%"><?php echo date("d M Y", strtotime($adval->createddate)); ?></td>
                <td width="8%" style="text-align:center" ><?php echo JHtml::_('jgrid.published',$adval->status,$sno); ?></td>
                <td width="10%"><?php echo $adval->id; ?></td>
            </tr>
        <?php
        $sno++;
            }
       ?>
    </table>
    <input type="hidden" name="option" value="<?php echo JRequest::getVar( 'option','wishlogue' );?>"/>
    <input type="hidden" name="optionvalue" value="<?php echo JRequest::getVar( 'option' );?>"/>
    <input type="hidden" name="task" value=""/>
    <input type="hidden" name="boxchecked" value="0"/>
    <input type="hidden" name="filter_order" value="<?php echo $this->getallads['order']; ?>" /> 
    <input type="hidden" name="filter_order_Dir" value="<?php echo $this->getallads['order_Dir']; ?>" />
    <input type="hidden" name="hidemainmenu" value="0"/>

</form>