laravel5中的QR码解码器

时间:2015-07-03 07:05:09

标签: php laravel-5

我正在使用' robbiepaul / zbar-qrdecoder'用于解码laravel5中的QR码图像的包。

我已经把#34; robbiep / zbar-qrdecoder":" ~1.3"在要求composer.json和' RobbieP \ ZbarQrdecoder \ ZbarQrdecoderServiceProvider'在app.php的providers数组中,但在更新composer时,它显示以下错误:

[BadMethodCallException]
Call to undefined method [package]
Script php artisan clear-compiled handling the post-update-cmd event returned with an error

[RuntimeException]
  Error Output:
update [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--lock]
 [--no-plugins] [--no-cust`enter code here`om-installers] [--no-autoloader] [--no-scripts] [--no-
progress] [--with-dependencies] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader]
 [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [packages1] ... [p
ackagesN]

是否有其他包可用于解码laravel5或php中的QR码图像?

1 个答案:

答案 0 :(得分:0)

确保安装ImageMagick

打开终端并按照:

sudo apt-get install zbar-tools
composer require robbiep/zbar-qrdecoder    
php artisan vendor:publish

希望这能解决你的错误!