You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
93 lines
3.9 KiB
93 lines
3.9 KiB
{template 'header', 'member'}
|
|
<div class="menu">
|
|
<table cellpadding="0" cellspacing="0">
|
|
<tr>
|
|
<td class="tab" id="add"><a href="?action=add"><span>添加链接</span></a></td>
|
|
<td class="tab" id="s3"><a href="?action=index"><span>已发布({$nums[3]})</span></a></td>
|
|
<td class="tab" id="s2"><a href="?status=2"><span>审核中({$nums[2]})</span></a></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
{if $action=='add' || $action=='edit'}
|
|
<form method="post" action="?" id="dform" onsubmit="return check();">
|
|
<input type="hidden" name="action" value="{$action}"/>
|
|
<input type="hidden" name="itemid" value="{$itemid}"/>
|
|
<input type="hidden" name="forward" value="{$forward}"/>
|
|
<table cellpadding="10" cellspacing="1" class="tb">
|
|
<tr>
|
|
<td class="tl"><span class="f_red">*</span> 网站名称</td>
|
|
<td class="tr"><input type="text" name="post[title]" id="title" size="40" value="{$title}"/> {dstyle('post[style]', $style)} <span id="dtitle" class="f_red"></span></td>
|
|
</tr>
|
|
<tr>
|
|
<td class="tl"><span class="f_red">*</span> 链接地址</td>
|
|
<td class="tr"><input type="text" size="40" name="post[linkurl]" id="linkurl" value="{$linkurl}"/> <span id="dlinkurl" class="f_red"></span></td>
|
|
</tr>
|
|
<tr>
|
|
<td class="tl">显示顺序</td>
|
|
<td class="tr"><input type="text" name="post[listorder]" id="listorder" size="5" value="{$listorder}"/> <span id="dlistorder" class="f_red"></span> 填写数字,数字越大越靠前</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="tl"> </td>
|
|
<td class="tr" height="50"><input type="submit" name="submit" value="{if $action == 'edit'}修 改{else}添 加{/if}" class="btn_g"/> <input type="button" value="取 消" class="btn" onclick="history.back(-1);"/></td>
|
|
</tr>
|
|
</table>
|
|
</form>
|
|
<script type="text/javascript">s('link');m({if $action=='add'}'add'{else}'s{$status}'{/if});</script>
|
|
{else}
|
|
<form action="?">
|
|
<input type="hidden" name="status" value="{$status}"/>
|
|
<div class="tt">
|
|
<input type="text" size="70" name="kw" value="{$kw}" title="关键词"/>
|
|
<input type="submit" value="搜 索" class="btn"/>
|
|
<input type="button" value="重 置" class="btn" onclick="Go('?status={$status}');"/>
|
|
</div>
|
|
</form>
|
|
<form method="post">
|
|
<div class="ls">
|
|
<table cellspacing="0" cellpadding="10" class="tb">
|
|
<tr>
|
|
<th width="20"><input type="checkbox" onclick="checkall(this.form);"/></th>
|
|
<th>链接名称</th>
|
|
<th>网站地址</th>
|
|
<th>添加时间</th>
|
|
<th width="40">修改</th>
|
|
<th width="40">删除</th>
|
|
</tr>
|
|
{loop $lists $k $v}
|
|
<tr align="center">
|
|
<td><input type="checkbox" name="itemid[]" value="{$v[itemid]}"/></td>
|
|
<td><a href="{$v[url]}" target="_blank">{$v[title]}</a></td>
|
|
<td><a href="{$v[url]}" target="_blank">{$v[linkurl]}</a></td>
|
|
<td class="f_gray">{$v[adddate]}</td>
|
|
<td><a href="?action=edit&itemid={$v[itemid]}"><img width="16" height="16" src="image/edit.png" title="修改" alt=""/></a></td>
|
|
<td><a href="?action=delete&itemid={$v[itemid]}" onclick="if(!confirm('确定要删除吗?此操作将不可撤销')) return false;"><img width="16" height="16" src="image/delete.png" title="删除" alt=""/></a></td>
|
|
</tr>
|
|
{/loop}
|
|
</table>
|
|
</div>
|
|
<div class="btns">
|
|
<input type="submit" value="删除选中" class="btn_r" onclick="if(confirm('确定要删除选中链接吗?')){this.form.action='?action=delete'}else{return false;}"/>
|
|
</div>
|
|
</form>
|
|
{if $MG[link_limit]}
|
|
<div class="limit">总共可发 <span class="f_b f_red">{$MG[link_limit]}</span> 条 当前已发 <span class="f_b">{$limit_used}</span> 条 还可以发 <span class="f_b f_blue">{$limit_free}</span> 条</div>
|
|
{/if}
|
|
<div class="pages">{$pages}</div>
|
|
<script type="text/javascript">s('link');m('s{$status}');</script>
|
|
{/if}
|
|
{if $action=='add' || $action=='edit'}
|
|
<script type="text/javascript">
|
|
function check() {
|
|
if(Dd('title').value.length < 2) {
|
|
Dmsg('请填写网站名称', 'title');
|
|
return false;
|
|
}
|
|
if(Dd('linkurl').value.length < 15) {
|
|
Dmsg('请填写网站地址', 'linkurl');
|
|
return false;
|
|
}
|
|
return true;
|
|
}
|
|
</script>
|
|
{/if}
|
|
{template 'footer', 'member'}
|