简体   繁体   中英

Error when install dompdf in laravel 5.4

I run this to install dompdf:

composer require barryvdh/laravel-dompdf

And the error looks like this:

Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Installation request for barryvdh/laravel-dompdf ^0.8.1 -> satisfiable by barryvdh/laravel-dompdf[v0.8.1].
    - Conclusion: remove dompdf/dompdf v0.7.0
    - Conclusion: don't install dompdf/dompdf v0.7.0
    - barryvdh/laravel-dompdf v0.8.1 requires dompdf/dompdf ^0.8 -> satisfiable by dompdf/dompdf[v0.8.0, v0.8.1].
    - Can only install one of: dompdf/dompdf[v0.8.0, v0.7.0].
    - Can only install one of: dompdf/dompdf[v0.8.1, v0.7.0].
    - Installation request for dompdf/dompdf (locked at v0.7.0) -> satisfiable by dompdf/dompdf[v0.7.0].


Installation failed, reverting ./composer.json to its original content.

Any of you know what's wrong or what should i do?

The error message states that barryvdh/laravel-dompdf package require "dompdf/dompdf": "^0.8" which is newer version but you have dompdf/dompdf v0.7.0 which is older version installed.

So you should try to remove old version of dompdf to install new version.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM