报错: Call to undefined method Illuminate\Events\Dispatcher::fire() Whoops\Run::handleError("Uncaught Error: Call to undefined method Illuminate\Events\Dispatcher::fire() in /www/web/laravel/vendor/swooletw/laravel-swoole/src/Server/Manager.php:145 lar…
进行模型关联操作, php artisan tinker 执行 $user = App\Models\User::find(1) $user->followings()->attach([2, 3]) 报错,模型关联定义都是OK的,google了一番,才发现原来是tinker的bug.直接在控制器中调用就没有报这个错误.如果你用tinker也报这个错了,试一下直接在控制器中操作.by the way,我用的是5.1版本…
自己组装的apache,php,mysql phpinfo显示 OpenSSL support     disabled (install ext/openssl) 判断为权限问题,所以修改如下. 1将php安装目录下ext下的php_openssl.dll.libeay32.dll.ssleay32.dll .php_xmlrpc.dll.php_curl.dll文件复制到windows下的system或者system32文件夹中.2将php.ini复制到windows文件夹中,打开php.i…
nginx: 在phpstudy中运行Laravel一键安装包时报错:Call to undefined function Illuminate\Encryption\openssl_cipher_iv_length(),产生错误的原因是没开启php_openssl扩展,开启即可. apache: 检查http.conf   LoadModule ssl_module modules/mod_ssl.so php.ini开启extension=php_openssl.dll 将php7.1要目录…
Method Illuminate\Validation\Validator::validateReuqired does not exist. 此错误是由于我们在配置验证时,写错了关键字, public function rules() { return [ 'file'=>'required', 'folder'=>'reqiured', // 这里reqiured错误,应该required ]; }…
今天做项目时往Gemfile里加了各gem, 然后bundle update了一下, 然后悲剧了,出现了undefined method `environment' for nil:NilClass when importing Bootstrap into rails错误, 各种不理解. 然后查了一下, 找到了解决方案: https://stackoverflow.com/questions/22392862/undefined-method-environment-for-nilnilcla…
如果pod undate 的时候报错"undefined method `root' for nil:NilClass" error when using "pod install" 或 NoMethodError - undefined method `dirname' for nil:NilClass 检查你的podfile文件 保证一下信息存在 Pod::Spec.new do |s| s.name = "DDEBusiness" s.ve…
基于Laravel+Swoole开发智能家居后端 在上一篇<Laravel如何优雅的使用Swoole>中我已经大概谈到了Laravel结合Swoole的用法. 今天,我参与的智能家居项目基本上已经结束了Web服务器及android端的开发(熬了个通宵突击把剩下的做了,好累), 趁热来聊聊基于Laravel+Swoole开发智能家居后端的关键技术点. 16进制ASCII码协议的解析 硬件我不谈,我只需要关心数据解析.如何基于Swoole如果在php中解析16进制的ascii码,这种文章还比较少呢…
Started GET "/mygroup/myproject/tree/master/MyDirectory" for 127.0.0.1 at 2014-10-22 22:42:42 +0200 Processing by Projects::TreeController#show as HTML Parameters: {"project_id"=>"mygroup/myproject", "id"=>&qu…
I am getting the following error in my Rails 3.2 functional tests: ActionView::Template::Error: undefined method `error_messages' for # <ActionView::Helpers::FormBuilder:0x007ff8ad00d3b0> The view code that is creating the error: <%= form_for [@c…