| Server IP : 186.64.123.29 / Your IP : 216.73.217.94 Web Server : LiteSpeed System : Linux house.hostinglat.cl 5.15.0-185-generic #195-Ubuntu SMP Fri Jun 19 17:11:50 UTC 2026 x86_64 User : tuemp9827 ( 1016) PHP Version : 8.1.31 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /home/tuempresavirtual.cl/public_html/wp-content/plugins/webp-express/web-service/ |
Upload File : |
<?php
require __DIR__ . '/../vendor/autoload.php';
use \WebPConvertCloudService\WebPConvertCloudService;
include_once __DIR__ . '../../lib/classes/Config.php';
use \WebPExpress\Config;
include_once __DIR__ . '../../lib/classes/Paths.php';
use \WebPExpress\Paths;
include_once __DIR__ . '/../lib/classes/Config.php';
// Patch together $options object for wpc...
$options = [];
$config = Config::loadConfigAndFix(false);
if (!isset($config['web-service'])) {
WebPConvertCloudService::exitWithError(WebPConvertCloudService::ERROR_ACCESS_DENIED, 'Web Service is not configured');
}
$webServiceConfig = $config['web-service'];
if (!$webServiceConfig['enabled']) {
WebPConvertCloudService::exitWithError(WebPConvertCloudService::ERROR_ACCESS_DENIED, 'Web Service is not enabled');
}
$options['destination-dir'] = Paths::getCacheDirAbs() . '/wpc';
$options['access'] = [
//'allowed-ips' => ['127.0.0.1'],
'whitelist' => $webServiceConfig['whitelist']
];
$options['webp-convert'] = Config::generateWodOptionsFromConfigObj($config);
WebPConvertCloudService::handleRequest($options);