目录 /phpcms/modules/content/templates
content_add.tpl.php 在form中加入 :<input type="hidden" name="info[username]" value="<?php echo $admin_username?>" />
推荐加入:<input value="<?php echo L('save_close');?>" type="submit" name="dosubmit" class="cu" style="width:145px;"> 之前。放在一起规矩。
content_edit.tpl.php 89行入加处:<input value="<?php echo $data['username']?>" type="hidden" name="info[username]" />
加到:<input value="<?php if($r['upgrade']) echo $r['url'];?>" type="hidden" name="upgrade"> 前面。放在一起好看。
更多:
http://bbs.phpcms.cn/forum.php?mod=viewthread&tid=432108&highlight=username
调用真实姓名
{pc:get sql="select realname from v9_admin where username='$username'" return="data" num="1"}
{loop $data $key $val}
{$val['realname']}
{/loop}
{/pc}
模型管理--文章模型字段管理
添加字段:realname ; 别名:姓名
评论