微擎基础教程:万能表单使用教程

在PHP类库中有一个类库叫form builder,如果你熟悉form builder的使用方法,那么微擎中万能表单你也会得心应手。微擎代码虽然写的很乱,但是集成了很多用起来很爽的东西。

微擎基础教程

一、后端:

  1. load()->func('tpl');

二、前端:

  1. <ul class="we7-page-tab">
  2.     <li class="active"><a href="{php echo url('module/manage-account/setting',['m'=>'yoby_test1']);}">参数设置</a></li>
  3. </ul>
  4. <div class="content">
  5. <form action="" method="post"  class="we7-form" role="form"  id="form1">
  6.     <div class="panel">
  7.         <div class="panel-body">
  8. </div></div>
  9. </form>
  10. {php we7_text('openid','openid',$settings['openid'],'openid在粉丝信息里面找')}
  11. {php we7_texts('openid','openid9','89','openid在粉丝信息里面找')}
  12. {php we7_editor('openid','openid99','99','openid在粉丝信息里面找')}
  13. {php we7_select("选择","select",["1"=>"中国","2"=>"美国","日本"],"3","选择国家")}
  14. {php we7_image($text="缩略图",$name="thumb",$value='1.jpg',$desc='选择你的图片')}
  15. {php we7_isshow($text="是否显示",$name="isshow",$arr=[0=>'不显示',1=>'显示'],$value=0,$desc='显示选项')}
  16. {php we7_images($text="缩略图",$name="tupian[]",$value=[],$desc='选择你的图片')}
  17. {php we7_color("选择颜色","idsx")}
  18.  {php we7_date("选择日期时间")}
  19.   {php we7_emoji("选择表情","emoji",$value="")}
  20. {php we7_icon("icon","icon")}
  21.  {php we7_audio("音乐上传","music",'',"选择音乐")}
  22. {php we7_video("视频上传","video",'',"只能是mp4或flv")}
  23. {php we7_copy("复制","abc")}
  24. {php we7_dates("时间段","gametime")}
  25. {php we7_birthday()}
  26. {php we7_map()}
  27. {php we7_del()}
  28. {php we7_city("省市县","ssx","湖南省")}
  29. {php we7_checkbox("复选",'chk',["a"=>'男','b'=>"女","c"=>"未知"],"b","选择性别")}
  30. {php we7_radio("单选",'rad',["a"=>'男','b'=>"女","c"=>"未知"],"a","选择性别")}
  31. {php we7_edit("编辑")}
  32. {php we7_btn('保存')}

三、搜索表单直接用不能再form里面

  1. {php we7_search("关键字","k","中国",'')}

 

你想把广告放到这里吗?

发表评论

您必须 登录 才能发表留言!