<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>AMP转化表-v1.0</title> 
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<link href="http://europe.chtcdn.com/bootstrap/css/bootstrap.min.css" rel="stylesheet"/>
<script type="text/javascript" src="http://europe.chtcdn.com/js/jquery.js"></script>
<script type="text/javascript" src="http://europe.chtcdn.com/bootstrap/js/bootstrap.min.js"></script>
<style type="text/css">
.show-grid {padding: 15px; background: #efefef; border-radius: 5px;}
.mr10 {margin-right: 10px;}
.nav {margin-bottom: 5px;}
.pic {display: none;}
.msg {color: #07c;}
.mt12 {margin-top: 12px;}
.msg_wait {color: #999;}
.none {display: none;}
.form-search {display: inline-block;margin:0 0 0 5px !important;}
.input-medium.search-query {width: 250px;}
#search,#insert,#update {margin-top: 2px;float: right;}
@media (min-width: 1200px) {
.container.wd {
    padding: 0 15px;
    width: 1170px;
}
}
</style>
<script type="text/javascript">
$(function() {
    //下拉选站点
    $('a.sss').on('click', function() {
        var site = $(this).html();
        location.href = '/info.php/login/change_site/'+site+'/?url=/tools/amp_check';
    });
});
</script>
</head>
<body>
    <div class="container wd">
        <div class="row show-grid">
            <ul class="nav nav-pills">
                <li class="active dropdown mr10">
                    <a class="dropdown-toggle" data-toggle="dropdown" href="#">
                        站点:<?php echo($this->config->item('site_code'));?>
                        <b class="caret"></b>
                    </a>
                    <ul class="dropdown-menu">
                        <li>
                            <a class="sss">cht</a>
                        </li>
                        <li>
                            <a class="sss">jp</a>
                        </li>
                        <li>
                            <a class="sss">gm</a>
                        </li>
                        <li>
                            <a class="sss">vc</a>
                        </li>
                        <li>
                            <a class="sss">vac</a>
                        </li>
                        <li>
                            <a class="sss">ru</a>
                        </li>
                        <li>
                            <a class="sss">it</a>
                        </li>
                        <li>
                            <a class="sss">ct</a>
                        </li>
                    </ul>
                </li>
                <span class="label label-info">信息：<?php echo(count($info));?>个 (只显示前800个)</span>
                <form class="form-search" id="path_search" action="#" method="post">
                    <span class="checkbox">
                        <label>
                            <input type="radio" name="amp" value="yes" <?php if($amp == 'yes') echo('checked'); ?>> 显示已转换AMP的信息
                        </label>
                    </span>
                    &nbsp;
                    <span class="checkbox">
                        <label>
                            <input type="radio" name="amp" value="no" <?php if($amp == 'no') echo('checked'); ?>> 显示未转换AMP的信息
                        </label>
                    </span>
                    &nbsp;
                    <button type="submit" class="btn">筛选</button>
                </form>
            </ul>
        </div>
        <div class="row">
            <table class="table table-hover">
                <thead>
                    <tr>
                      <th>#</th>
                      <th>文件名</th>
                      <th width="6%">AMP转化</th>
                      <th width="6%"></th>
                    </tr>
                </thead>
                <tbody class="data_group">
                    <?php foreach($info as $key=>$it) { 
                        if ($key == 800) break;
                    ?>
                    <tr class="data">
                        <td><?php echo($key+1);?></td>
                        <td title="<?php echo($it->ic_url);?>"><?php echo($it->ic_url);?></td>
                        <td>
                            <?php 
                            if ($amp == 'yes')
                                echo('<span style="color:seagreen">是</span>'); 
                            else
                                echo('<span style="color:#a12023">否</span>'); 
                            ?>
                        </td>
                        <td>
                            <a href="javascript:document.getElementById('keywords').value='<?php echo(urlencode($it->ic_url));?>';document.forms.goSearch.submit();" target="_blank">编辑</a>
                        </td>
                    </tr>
                    <?php } ?>
                </tbody>
            </table>
        </div>
    </div>
    <form action="/info.php/welcome/search" method="post" id="goSearch" target="_blank">
        <input type="hidden" name="keywords" id="keywords" value="">
    </form>
</body>
</html>