首页 >社区问答列表 >求大神解答

求大神解答

我的X-admin是2.0的   去1.0里面把system.html拷贝过来了  在视频4:40那里写value值得时候就报错了  Trying to get property 'title' of non-object 


  • 自渡
  • 自渡   2018-06-15 15:12:12 1楼

    {include file="public/header"/} <body> <div class="x-nav"> <span class="layui-breadcrumb"> <a><cite>首页</cite></a> <a><cite>会员管理</cite></a> </span> <a class="layui-btn layui-btn-small" style="line-height:1.6em;margin-top:3px;float:right" href="javascript:location.replace(location.href);" title="刷新"><i class="layui-icon" style="line-height:30px">ဂ</i></a> </div> <div class="x-body"> <div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief"> <ul class="layui-tab-title"> <li class="layui-this">网站设置</li> </ul> <div class="layui-tab-content" > <div class="layui-tab-item layui-show"> <form class="layui-form layui-form-pane" action=""> <div class="layui-form-item"> <label class="layui-form-label"> <span class='x-red'>*</span>网站名称 </label> <div class="layui-input-block"> <input type="text" name="title" autocomplete="off" placeholder="控制在25个字、50个字节以内" class="layui-input" value="{$system->title}" > </div> </div> <div class="layui-form-item"> <label class="layui-form-label"> <span class='x-red'>*</span>关键词 </label> <div class="layui-input-block"> <input type="text" name="keywords" autocomplete="off" placeholder="5个左右,8汉字以内,用英文,隔开" class="layui-input" value="{$system->keywords}" > </div> </div> <div class="layui-form-item"> <label class="layui-form-label"> <span class='x-red'>*</span>描述 </label> <div class="layui-input-block"> <input type="text" name="desc" autocomplete="off" placeholder="空制在80个汉字,160个字符以内" class="layui-input" value="{$system->desc}" > </div> </div> <div class="layui-form-item"> <label for="AppId" class="layui-form-label"> <span class="x-red">*</span>是否开启 </label> <div class="layui-input-block"> <select name="" id=""> {eq name="$system->is_close" value="0"} <option value="0" selected > 开启网站 </option> <option value="1" > 关闭网站 </option> {else/} <option value="0" > 开启网站 </option> <option value="1" selected > 关闭网站 </option> {/eq} </select> </div> </div> <!--用隐藏域发送is_update字段值--> <input type="hidden" name="is_update" value="{$system->is_update}"> <div class="layui-form-item"> <button class="layui-btn" lay-submit="" lay-filter="*"> 保存 </button> </div> </form> <div style="height:100px;"></div> </div> </div> </div> </div> <!--script> layui.use(['element','layer','form'], function(){ $ = layui.jquery;//jquery lement = layui.element();//面包导航 layer = layui.layer;//弹出层 form = layui.form() //监听提交 // form.on('submit(*)', function(data){ // console.log(data); //发异步,把数据提交给php // layer.alert("保存成功", {icon: 6}); // return false; // }); }) </script--> </body></html>

    +0 添加回复

  • 回复