最新国产好看的视频,伊人天堂AV在线,国产Aaaaaa视频,蜜臀视频在线观看一区,人妻av色图,密臀久久久精品影片,青青视频免费观看毛片,久草在线观看视,国产三级精品色情在线

Laravel重定向,a鏈接跳轉(zhuǎn),控制器跳轉(zhuǎn)示例

 更新時間:2019年10月22日 10:01:12   作者:SHUIPING_YANG  
今天小編就為大家分享一篇Laravel重定向,a鏈接跳轉(zhuǎn),控制器跳轉(zhuǎn)示例,具有很好的參考價值,希望對大家有所幫助。一起跟隨小編過來看看吧

Laravel重定向分類如下:

1、a鏈接跳轉(zhuǎn):

<a class="btn btn-success" href="{{url('admin/organization/createAuthCodeView', ['id' => $list['id']])}}" rel="external nofollow" >生成注冊碼</a>

2、form表單提交跳轉(zhuǎn):

<form class="form-inline" method="get" action="{{ url('admin/organization/listOrganization') }}">
 <div class="form-group" style="margin-left: 20px">
  <input type="hidden" name="customer_type" value="1">
  <label for="perPage">每頁顯示數(shù):</label>
  <select class="form-control" id="perPage" name="perPage">
   @foreach ( [10,20,30,50] as $e)
   <option value="{{$e}}" {{ $e==request('perPage') ? 'selected' : '' }} >{{$e}}</option>
   @endforeach
  </select>
 </div>
 <div class="form-group" style="margin-left: 20px">
  <label for="search">模糊搜索:</label>
  <input type="text" name="search" style="width: 400px" class="form-control" id="search" placeholder="請輸入用戶名或者郵箱或者電話" value="{{request('search')}}">
 </div>
 <button type="submit" class="btn btn-primary" style="margin-left: 20px">開始搜索</button>
 <a href="{{url('admin/organization/createOrganization')}}" rel="external nofollow" class="pull-right">
  <button class="btn btn-primary">新增機構(gòu)</button>
 </a>
</form>

3、ajax提交跳轉(zhuǎn):

<script type="text/javascript">
 $(function(){
  $.ajaxSetup({
    headers: { 'X-CSRF-TOKEN' : '{{ csrf_token() }}' }
  });
  $("#generate").click(function(){
  $.ajax({
      url:"/admin/organization/generateAuthCode", //你的路由地址
      type:"post",
      data:{"auth_num":$('#auth_num').val(),"organization_name":$('#organization_name').val()},
      timeout:30000,
      success:function(data){
       $("#auth_codes").val(data);
      },
      error:function(){
      console.log(data);
     }
    });
 });
 })
</script>

4、控制器方法里面跳轉(zhuǎn):

return redirect('/admin/organization/listOrganization');

以上這篇Laravel重定向,a鏈接跳轉(zhuǎn),控制器跳轉(zhuǎn)示例就是小編分享給大家的全部內(nèi)容了,希望能給大家一個參考,也希望大家多多支持腳本之家。

相關(guān)文章

最新評論

宿迁市| 松原市| 彭州市| 鞍山市| 洪泽县| 万宁市| 竹山县| 石城县| 互助| 宜川县| 阿拉尔市| 喀什市| 平远县| 航空| 德惠市| 华容县| 望奎县| 大名县| 荆州市| 金湖县| 屯门区| 浦城县| 邵阳县| 都江堰市| 康马县| 和林格尔县| 凤阳县| 温州市| 哈巴河县| 夏河县| 秀山| 涞水县| 平遥县| 泽库县| 上虞市| 清河县| 安塞县| 肇庆市| 凌源市| 体育| 五指山市|