Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/dart/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Magento2 未捕获错误:类';GuzzleHttp\Client';找不到_Magento2_Zoho - Fatal编程技术网

Magento2 未捕获错误:类';GuzzleHttp\Client';找不到

Magento2 未捕获错误:类';GuzzleHttp\Client';找不到,magento2,zoho,Magento2,Zoho,在magento2中实现此功能时,我面临一个问题。rest所有依赖项都已解析,但从composer中,它不仅读取GuzzleHttp\Client类,而且在第24行的/vendor/Maidmaid/Zoho/Client.php中给出错误“未捕获错误:未找到类‘GuzzleHttp\Client’” autoload_static.php定义此 'GuzzleHttp\\' => array ( 0 => __DIR__ . '/..' .

在magento2中实现此功能时,我面临一个问题。rest所有依赖项都已解析,但从composer中,它不仅读取GuzzleHttp\Client类,而且在第24行的/vendor/Maidmaid/Zoho/Client.php中给出错误“未捕获错误:未找到类‘GuzzleHttp\Client’”

autoload_static.php定义此

'GuzzleHttp\\' => 
        array (
            0 => __DIR__ . '/..' . '/guzzlehttp/guzzle/src',
        ),
在autoload_psr4中定义了这一点

'Maidmaid\\Zoho\\' => array($vendorDir . '/maidmaid/zoho/src'),
    'GuzzleHttp\\Psr7\\' => array($vendorDir . '/guzzlehttp/psr7/src'),
    'GuzzleHttp\\Promise\\' => array($vendorDir . '/guzzlehttp/promises/src'),
    'GuzzleHttp\\' => array($vendorDir . '/guzzlehttp/guzzle/src'),
如果有人能帮我解决这个问题,请告诉我


谢谢

您必须使用composer安装Guzzle软件包

首先转到项目目录,然后使用以下命令安装guzzle

composer require guzzlehttp/guzzle
尝试在下面的行中添加

require_once 'vendor/autoload.php'