<?php /* Smarty version Smarty-3.1.12, created on 2017-04-09 11:55:19
         compiled from "D:\WWW\youkeSY\themes\member\website.html" */ ?>
<?php /*%%SmartyHeaderCode:1880858d5ff5fd096a8-11608694%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
$_valid = $_smarty_tpl->decodeProperties(array (
  'file_dependency' => 
  array (
    '8ae7eb13a358cf95657c100aa29bc4a45f65ad3f' => 
    array (
      0 => 'D:\\WWW\\youkeSY\\themes\\member\\website.html',
      1 => 1491738917,
      2 => 'file',
    ),
  ),
  'nocache_hash' => '1880858d5ff5fd096a8-11608694',
  'function' => 
  array (
  ),
  'version' => 'Smarty-3.1.12',
  'unifunc' => 'content_58d5ff5fdc8d56_10422165',
  'variables' => 
  array (
    'pagename' => 0,
    'action' => 0,
    'weblist' => 0,
    'web' => 0,
    'showpage' => 0,
    'cfg' => 0,
    'cate_pids' => 0,
    'key' => 0,
    'do' => 0,
    'item' => 0,
  ),
  'has_nocache_code' => false,
),false); /*/%%SmartyHeaderCode%%*/?>
<?php if ($_valid && !is_callable('content_58d5ff5fdc8d56_10422165')) {function content_58d5ff5fdc8d56_10422165($_smarty_tpl) {?><?php echo $_smarty_tpl->getSubTemplate ("header.html", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, null, null, array(), 0);?>

		
            <div class="content">
            	<div class="title"><?php echo $_smarty_tpl->tpl_vars['pagename']->value;?>
</div>
                <div class="body">
        <?php if ($_smarty_tpl->tpl_vars['action']->value=='list'){?>
        <div id="listbox">
			<table width="100%" border="0" cellspacing="1" cellpadding="0">
				<tr>
					<th>ID</th>
					<th>所属分类</th>
					<th>网站名称</th>
					<th>网站地址</th>
					<th>属性状态</th>
					<th>提交时间</th>
					<th>操作选项</th>
				</tr>
				<?php  $_smarty_tpl->tpl_vars['web'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['web']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['weblist']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['web']->key => $_smarty_tpl->tpl_vars['web']->value){
$_smarty_tpl->tpl_vars['web']->_loop = true;
?>
				<tr>
					<td><?php echo $_smarty_tpl->tpl_vars['web']->value['web_id'];?>
</td>
					<td><?php echo $_smarty_tpl->tpl_vars['web']->value['cate_name'];?>
</td>
					<td class="textleft"><?php echo $_smarty_tpl->tpl_vars['web']->value['web_name'];?>
</td>
					<td class="textleft"><?php echo $_smarty_tpl->tpl_vars['web']->value['web_url'];?>
</td>
					<td style="color: #FF0000;"><?php echo $_smarty_tpl->tpl_vars['web']->value['web_status'];?>
</td>
					<td><?php echo $_smarty_tpl->tpl_vars['web']->value['web_ctime'];?>
</td>
					<td><a  href="?mod=website&act=edit&wid=<?php echo $_smarty_tpl->tpl_vars['web']->value['web_id'];?>
" class="layui-btn layui-btn-normal layui-btn-small"><i class="layui-icon"></i></a></td>
				</tr>
				<?php }
if (!$_smarty_tpl->tpl_vars['web']->_loop) {
?>
				<tr><td colspan="7">您还未提交任何站点！</td></tr>
				<?php } ?>
			</table>
		</div>
        <div id="showpage" class="clearfix"><?php echo $_smarty_tpl->tpl_vars['showpage']->value;?>
</div>
        <?php }?>
        
        <?php if ($_smarty_tpl->tpl_vars['action']->value=='add'||$_smarty_tpl->tpl_vars['action']->value=='edit'){?>
        <?php if ($_smarty_tpl->tpl_vars['cfg']->value['is_enabled_submit']=='yes'){?>
        <div id="formbox">
			<form name="myfrom" id="myfrom" method="post" action="?mod=website">
        	<ul>
        		<li><strong>选择分类：</strong>
        		<?php  $_smarty_tpl->tpl_vars['item'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['item']->_loop = false;
 $_smarty_tpl->tpl_vars['key'] = new Smarty_Variable;
 $_from = $_smarty_tpl->tpl_vars['cate_pids']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['item']->key => $_smarty_tpl->tpl_vars['item']->value){
$_smarty_tpl->tpl_vars['item']->_loop = true;
 $_smarty_tpl->tpl_vars['key']->value = $_smarty_tpl->tpl_vars['item']->key;
?><select name="level_<?php echo $_smarty_tpl->tpl_vars['key']->value;?>
" id="level_<?php echo $_smarty_tpl->tpl_vars['key']->value;?>
" class="sel"></select>
        		<?php }
if (!$_smarty_tpl->tpl_vars['item']->_loop) {
?>
        		<select name="level_0" id="level_0" class="sel"></select>
        		<?php } ?><input type="hidden" name="cate_id" id="cate_id" value="<?php echo $_smarty_tpl->tpl_vars['web']->value['cate_id'];?>
"></li>
        		<li><strong>网站名称：</strong><input type="text" name="web_name" id="web_name" class="ipt" size="50" maxlength="50" 
        		value="<?php if (!empty($_smarty_tpl->tpl_vars['web']->value)){?><?php echo $_smarty_tpl->tpl_vars['web']->value['web_name'];?>
<?php }?>" /></li>
            	<li><strong>网站域名：</strong><input type="text" name="web_url" id="web_url" class="ipt" size="50" maxlength="50" onKeyPress="strip_http()" onChange="strip_http()" onKeyUp="strip_http()" onblur="checkurl(this.value)" value="<?php if (!empty($_smarty_tpl->tpl_vars['web']->value)){?><?php echo $_smarty_tpl->tpl_vars['web']->value['web_url'];?>
<?php }?>" /><input type="button" class="btn" id="meta_btn" value="抓取Meta" onclick="getmeta()"></li>
            	<li><strong>TAG标签：</strong><input type="text" name="web_tags" id="web_tags" class="ipt" size="50" maxlength="50" value="<?php if (!empty($_smarty_tpl->tpl_vars['web']->value)){?><?php echo $_smarty_tpl->tpl_vars['web']->value['web_tags'];?>
<?php }?>" onBlur="javascript:this.value=this.value.replace(/，/ig,',');" /></li>
            	<li><strong>网站简介：</strong><textarea name="web_intro" id="web_intro" cols="55" rows="6" class="ipt"><?php if (!empty($_smarty_tpl->tpl_vars['web']->value)){?><?php echo $_smarty_tpl->tpl_vars['web']->value['web_intro'];?>
<?php }?></textarea></li>
				<li><strong>服务器IP：</strong><input name="web_ip" type="text" class="ipt" id="web_ip" size="30" maxlength="30" value="<?php if (!empty($_smarty_tpl->tpl_vars['web']->value)){?><?php echo $_smarty_tpl->tpl_vars['web']->value['web_ip'];?>
<?php }?>" readonly /><input type="button" class="btn" id="data_btn" value="获取数据" onclick="getdata()">&nbsp;等待系统自动抓取</li>
                <li><strong>百度权重：</strong><input name="web_brank" type="text" class="ipt" id="web_brank" size="10" maxlength="2" value="<?php echo !$_smarty_tpl->tpl_vars['web']->value['web_brank'] ? '0' : $_smarty_tpl->tpl_vars['web']->value['web_brank'];?>
" readonly /></li>
                <li><strong>360权重：</strong><input name="web_r360" type="text" class="ipt" id="web_r360" size="10" maxlength="2" value="<?php echo !$_smarty_tpl->tpl_vars['web']->value['web_r360'] ? '0' : $_smarty_tpl->tpl_vars['web']->value['web_r360'];?>
" readonly /></li>
                <li><strong>搜狗权重：</strong><input name="web_srank" type="text" class="ipt" id="web_srank" size="10" maxlength="2" value="<?php echo !$_smarty_tpl->tpl_vars['web']->value['web_srank'] ? '0' : $_smarty_tpl->tpl_vars['web']->value['web_srank'];?>
" readonly /></li>
				<li><strong>Alexa：</strong><input name="web_arank" type="text" class="ipt" id="web_arank" size="10" maxlength="10" value="<?php echo !$_smarty_tpl->tpl_vars['web']->value['web_arank'] ? '0' : $_smarty_tpl->tpl_vars['web']->value['web_arank'];?>
" readonly /></li>
            	<li><strong>&nbsp;</strong><input type="hidden" name="web_id" id="web_id" value="<?php echo $_smarty_tpl->tpl_vars['web']->value['web_id'];?>
"><input type="hidden" name="do" id="do" value="<?php echo $_smarty_tpl->tpl_vars['do']->value;?>
"><input type="submit" class="btn" value="提 交"> <input type="reset" class="btn" value="重 填"></li>
        	</ul>
        	</form>
        <script type="text/javascript" src="../public/js/linkage.select.js"></script>
        <script type="text/javascript">
		var options = {ajax : '../?mod=ajaxget&type=category', field_name : '[name=cate_id]', auto : true}
		var sel = new LinkageSelect(options);
		<?php if ($_smarty_tpl->tpl_vars['action']->value=='add'){?>
		sel.bind('#level_0');
		<?php }else{ ?>
		<?php  $_smarty_tpl->tpl_vars['item'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['item']->_loop = false;
 $_smarty_tpl->tpl_vars['key'] = new Smarty_Variable;
 $_from = $_smarty_tpl->tpl_vars['cate_pids']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['item']->key => $_smarty_tpl->tpl_vars['item']->value){
$_smarty_tpl->tpl_vars['item']->_loop = true;
 $_smarty_tpl->tpl_vars['key']->value = $_smarty_tpl->tpl_vars['item']->key;
?>
		sel.bind('#level_<?php echo $_smarty_tpl->tpl_vars['key']->value;?>
', <?php echo $_smarty_tpl->tpl_vars['item']->value;?>
);
		<?php } ?>
		<?php }?>
        </script>
    	</div>
        <?php }else{ ?>
        <div style="background: #ffc; border: dashed 1px #f30; color: #f00; padding: 20px; text-align: center;"><?php echo $_smarty_tpl->tpl_vars['cfg']->value['submit_close_reason'];?>
</div>
        <?php }?>
		<?php }?>
                </div>
            </div>

<?php echo $_smarty_tpl->getSubTemplate ("footer.html", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, null, null, array(), 0);?>
<?php }} ?>