<?php
foreach ($score_data_list as $key => $item) {
    
}
?>


<div class="table-responsive">
    <table class="table table-hover">
        <thead>
            <tr>
                <th class="col-sm-1">#</th>
                <th class="col-sm-5">页面</th>
                <th class="col-sm-1">移动端</th>
                <th class="col-sm-1">桌面端</th>
                <th class="col-sm-2">更新时间</th>
                <th class="col-sm-2">操作</th>
            </tr>
        </thead>
        <tbody>
            <?php
            $site_url = rtrim($this->config->item('site_url'), '/');
            if (!empty($score_data_list)) {
                foreach ($score_data_list as $key => $item) {
                    ?>
                    <tr>
                        <td><?php echo ++$key; ?></td>
                        <td><?php echo $item->psd_URL; ?></td>
                        <td><?php echo $item->psd_MobileScore; ?></td>
                        <td><?php echo $item->psd_DesktopScore; ?></td>
                        <td><?php echo date('Y-m-d', strtotime($item->psd_Datetime)); ?></td>
                        <td>
                            <a href="<?php echo $site_url . $item->psd_URL ?>" target="_blank">查看页面</a>  |
                            <a href="https://developers.google.com/speed/pagespeed/insights/?url=<?php echo urlencode($site_url . $item->psd_URL); ?>" target="_blank">Google insights</a> 
                        </td>
                    </tr>
                    <?php
                }
            }
            ?>

        </tbody>
    </table>
</div>