質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.50%
PHP

PHPは、Webサイト構築に特化して開発されたプログラミング言語です。大きな特徴のひとつは、HTMLに直接プログラムを埋め込むことができるという点です。PHPを用いることで、HTMLを動的コンテンツとして出力できます。HTMLがそのままブラウザに表示されるのに対し、PHPプログラムはサーバ側で実行された結果がブラウザに表示されるため、PHPスクリプトは「サーバサイドスクリプト」と呼ばれています。

composer

Composerとは、PHP5.3.2以上で使用可能なパッケージ管理ツールです。指定ディレクトリ内だけでパッケージ管理します。

Laravel 5

Laravel 5は、PHPフレームワークLaravelの最新バージョンで、2014年11月に発表予定です。ディレクトリ構造がが現行版より大幅に変更されるほか、メソッドインジェクションやFormRequestの利用が可能になります。

Q&A

解決済

2回答

5280閲覧

Laravel Excel 3.0 がインストールできない。

hrsi_teratail

総合スコア93

PHP

PHPは、Webサイト構築に特化して開発されたプログラミング言語です。大きな特徴のひとつは、HTMLに直接プログラムを埋め込むことができるという点です。PHPを用いることで、HTMLを動的コンテンツとして出力できます。HTMLがそのままブラウザに表示されるのに対し、PHPプログラムはサーバ側で実行された結果がブラウザに表示されるため、PHPスクリプトは「サーバサイドスクリプト」と呼ばれています。

composer

Composerとは、PHP5.3.2以上で使用可能なパッケージ管理ツールです。指定ディレクトリ内だけでパッケージ管理します。

Laravel 5

Laravel 5は、PHPフレームワークLaravelの最新バージョンで、2014年11月に発表予定です。ディレクトリ構造がが現行版より大幅に変更されるほか、メソッドインジェクションやFormRequestの利用が可能になります。

0グッド

0クリップ

投稿2018/05/06 16:11

以下のサイトを参考にして、

https://laravel-excel.maatwebsite.nl/docs/3.0/getting-started/installation

Laravel Excel 3.0をインストールしましたが、composerでエラーになります。

SHELL

1$ composer require maatwebsite/excel 2Using version ^3.0 for maatwebsite/excel 3./composer.json has been updated 4Loading composer repositories with package information 5Updating dependencies (including require-dev) 6Your requirements could not be resolved to an installable set of packages. 7 8 Problem 1 9 - maatwebsite/excel 3.0.1 requires phpoffice/phpspreadsheet ^1.2 -> satisfiable by phpoffice/phpspreadsheet[1.2.0, 1.2.1]. 10 - maatwebsite/excel 3.0.2 requires phpoffice/phpspreadsheet ^1.2 -> satisfiable by phpoffice/phpspreadsheet[1.2.0, 1.2.1]. 11 - maatwebsite/excel 3.0.3 requires phpoffice/phpspreadsheet ^1.2 -> satisfiable by phpoffice/phpspreadsheet[1.2.0, 1.2.1]. 12 - maatwebsite/excel 3.0.4 requires phpoffice/phpspreadsheet ^1.2 -> satisfiable by phpoffice/phpspreadsheet[1.2.0, 1.2.1]. 13 - maatwebsite/excel 3.0.5 requires phpoffice/phpspreadsheet ^1.2 -> satisfiable by phpoffice/phpspreadsheet[1.2.0, 1.2.1]. 14 - maatwebsite/excel 3.0.x-dev requires phpoffice/phpspreadsheet ^1.2 -> satisfiable by phpoffice/phpspreadsheet[1.2.0, 1.2.1]. 15 - maatwebsite/excel 3.0.0 requires phpoffice/phpspreadsheet ^1.1 -> satisfiable by phpoffice/phpspreadsheet[1.1.0, 1.2.0, 1.2.1]. 16 - maatwebsite/excel 3.0.0-alpha requires phpoffice/phpspreadsheet ^1.1 -> satisfiable by phpoffice/phpspreadsheet[1.1.0, 1.2.0, 1.2.1]. 17 - phpoffice/phpspreadsheet 1.2.1 requires ext-zip * -> the requested PHP extension zip is missing from your system. 18 - phpoffice/phpspreadsheet 1.2.0 requires ext-zip * -> the requested PHP extension zip is missing from your system. 19 - phpoffice/phpspreadsheet 1.1.0 requires ext-zip * -> the requested PHP extension zip is missing from your system. 20 - Installation request for maatwebsite/excel ^3.0 -> satisfiable by maatwebsite/excel[3.0.0, 3.0.0-alpha, 3.0.1, 3.0.2, 3.0.3, 3.0.4, 3.0.5, 3.0.x-dev]. 21 22 To enable extensions, verify that they are enabled in your .ini files: 23 - /etc/php.ini 24 - /etc/php.d/20-bz2.ini 25 - /etc/php.d/20-calendar.ini 26 - /etc/php.d/20-ctype.ini 27 - /etc/php.d/20-curl.ini 28 - /etc/php.d/20-dom.ini 29 - /etc/php.d/20-exif.ini 30 - /etc/php.d/20-fileinfo.ini 31 - /etc/php.d/20-ftp.ini 32 - /etc/php.d/20-gd.ini 33 - /etc/php.d/20-gettext.ini 34 - /etc/php.d/20-iconv.ini 35 - /etc/php.d/20-json.ini 36 - /etc/php.d/20-mbstring.ini 37 - /etc/php.d/20-mysqlnd.ini 38 - /etc/php.d/20-pdo.ini 39 - /etc/php.d/20-phar.ini 40 - /etc/php.d/20-posix.ini 41 - /etc/php.d/20-shmop.ini 42 - /etc/php.d/20-simplexml.ini 43 - /etc/php.d/20-soap.ini 44 - /etc/php.d/20-sockets.ini 45 - /etc/php.d/20-sqlite3.ini 46 - /etc/php.d/20-sysvmsg.ini 47 - /etc/php.d/20-sysvsem.ini 48 - /etc/php.d/20-sysvshm.ini 49 - /etc/php.d/20-tokenizer.ini 50 - /etc/php.d/20-xml.ini 51 - /etc/php.d/20-xmlwriter.ini 52 - /etc/php.d/20-xsl.ini 53 - /etc/php.d/30-mysqli.ini 54 - /etc/php.d/30-pdo_mysql.ini 55 - /etc/php.d/30-pdo_sqlite.ini 56 - /etc/php.d/30-wddx.ini 57 - /etc/php.d/30-xmlreader.ini 58 - /etc/php.d/30-xmlrpc.ini 59 - /etc/php.d/40-apcu.ini 60 - /etc/php.d/50-apc.ini 61 You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode. 62 63Installation failed, reverting ./composer.json to its original content.

回避方法がわからず困っております。

PHPのバージョンは

PHP 7.1.15 (cli) (built: Feb 28 2018 14:06:54) ( NTS ) Copyright (c) 1997-2018 The PHP Group Zend Engine v3.1.0, Copyright (c) 1998-2018 Zend Technologies

になります。何か設定等が必要でしょうか?

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

guest

回答2

0

自己解決

以下のPHPを削除後に
再インストールさればいけました。

yum remove php-*
yum -y install --enablerepo=remi,remi-php72 php
yum -y install --enablerepo=remi --enablerepo=remi-php72 php php-opcache php-devel php-mbstring php-mysqlnd php-phpunit-PHPUnit php-pecl-xdebug php-gd php-intl php-symfony php php-pdo php-xml php-tokenizer php-pear php-zip

PHP 7.2.5 (cli) (built: Apr 24 2018 19:12:06) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
with Zend OPcache v7.2.5, Copyright (c) 1999-2018, by Zend Technologies
with Xdebug v2.6.0, Copyright (c) 2002-2018, by Derick Rethans

投稿2018/05/06 16:37

hrsi_teratail

総合スコア93

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

0

参考にしているサイトの「Requirements」にある環境は整っていますでしょうか。

  • PHP: ^7.1
  • Laravel: ^5.5
  • PhpSpreadsheet: ^1.2
  • PHP extension php_zip enabled
  • PHP extension php_xml enabled
  • PHP extension php_gd2 enabled

記載いただいたエラーメッセージを確認すると「php_zip」はインストールされていない(または有効になっていない)ように思えます。

投稿2018/05/06 16:21

takyafumin

総合スコア2335

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

hrsi_teratail

2018/05/06 16:45

なるほど、PHPを再インストールすればいけました。 ありがとうございます。
guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.50%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問