我一直在我的本地网站上测试tumblr库,一切都按预期工作。但是,在上传到AWS时,我收到以下错误:
Fatal error: Class 'Tumblr\API\Client' not found in /var/app/current/tumblr.php on line 15
使用以下代码:
<?php
ini_set('display_errors',1);
ini_set('display_startup_errors',1);
error_reporting(-1);
require 'vendor/autoload.php';
include('dbcon.php');
use Tumblr\API;
$consumerKey = 'xxxxxxxxxxx';
$consumerSecret = 'xxxxxxxxxxx';
$client = new Tumblr\API\Client(
$consumerKey,
$consumerSecret,
'xxxxxxxxxx',
'xxxxxxxxxx'
);
是否有理由将负载用于本地,而不是AWS?