maclechan

maclechan

https://github.com/maclechan/

  • 财富值125
  • 威望值35
  • 总积分655

个人信息

  • 
    $this->registerJs(
       '$("document").ready(function(){ 
            $("#login-form").validate({
                errorElement : "small", 
                errorClass : "error",
                rules: {
                         "AgNav[nav_cn]": {
                             required: true,
                         },
                },
                messages:{
                       "AgNav[nav_cn]" : {  
                            required : "此字段不能为空.",
                        },
                }
            });
        });'
    );
    
    

    再补个写法

  • 回复了 的评论

    兄台用的是后台模板是?

    自己用bootstrap 和其他改的

  • 发布了教程
    yii2.0 小部件的高级使用
  • 回复了 的评论

    请问migrate有什么用处?
    以及console的用处是什么?

    migrate是一个数据库迁移工具,平时的开发过程中体会不到优越性。console这里面的东西其实是很少用到的。都是用命令来操作!

  • 发布了教程
    yii2.0使用migrate创建后台登陆
  • 回复了 的评论

    楼主辛苦了,咱们网站也有上传图片的功能,以后再发帖请上传到咱们服务器上,不要再外部引用了。

    我是找了半天没找到,图片就只有一个链接。最后没办法。

  • 2015-05-21 已签到
    连续签到1天,获得了5个金钱
  • 回复了 的回复

    1.$this->registerJsFile('@web/other/jquery.autocomplete.min.js',['depends'=>['yii\web\JqueryAsset'],'position'=>View::POS_HEAD])
    2.$this->registerCssFile('@web/other/jquery.autocomplete.css');

    3.$this->registerJs($jsstring)
    4.$this->registerCss($cssstring)

    第一个depends 好像有问题

  • 回复了 的回复

    1.$this->registerJsFile('@web/other/jquery.autocomplete.min.js',['depends'=>['yii\web\JqueryAsset'],'position'=>View::POS_HEAD])
    2.$this->registerCssFile('@web/other/jquery.autocomplete.css');

    3.$this->registerJs($jsstring)
    4.$this->registerCss($cssstring)

    第三、四个,是要在AppAsset.php里面定义吗?

主管 等级规则
655/1000
资料完整度
70/100
用户活跃度
0/100

Ta的关注

0

Ta的粉丝

37

Ta的访客

53