<?php if(!defined('IN_SDCMS')) exit;?><!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="renderer" content="webkit">
<title>违禁词管理</title>
<link rel="stylesheet" href="{WEB_ROOT}public/css/ui.css">
<link rel="stylesheet" href="{WEB_ROOT}public/admin/css/layout.css">
<script src="{WEB_ROOT}public/js/jquery.js"></script>
<script src="{WEB_ROOT}public/js/ui.js"></script>
</head>

<body>
    <div class="position">当前位置：插件管理 > <a href="{U('index')}">违禁词管理</a></div>
    <div class="borders">
        <!---->
        <div class="tabs tabs-white" data-href="1">
            <ul class="tabs-nav">
              <li class="active"><a href="{THIS_LOCAL}">违禁词管理</a></li>
            </ul>
            <div class="tabs-content">
                <div class="tabs-pane active">
                <!--loop-->
                <form method="post" class="ui-form">
                    <div class="form-group row">
                        <label class="col-left col-form-label">违禁词：</label>
                        <div class="col-right">
                            <textarea name="words" rows="20" class="form-ip">{strtr($words,['@@'=>"\r\n"])}</textarea>
                            <span class="input-tips">格式：违禁词1|替换词1<br>　　　违禁词2|替换词2</span>
                        </div>　　
                    </div>
                    <div class="form-group row">
                        <label class="col-left col-form-label"></label>
                        <div class="col-right">
                            <button type="submit" class="btn btn-blue">保存</button>
                        </div>
                    </div>
                </form>
                <!--loop-->
                </div>
            </div>
        </div>
        <!---->
    </div>
<script>
$(function()
{
	$(".ui-form").form(
	{
		type:2,
		result:function(form)
		{
			$.ajax(
			{
				type:'post',
				cache:false,
				dataType:'json',
				url:'{THIS_LOCAL}',
				data:$(form).serialize(),
				error:function(e){alert(e.responseText);},
				success:function(d)
				{
					if(d.state=='success')
					{
						sdcms.success(d.msg);
						setTimeout(function(){location.href='{THIS_LOCAL}'},1000);
					}
					else
					{
						sdcms.error(d.msg);
					}
				}
			});
		}
	});
})
</script>
</body>
</html>