1. Go to this page and download the library: Download bro-world/core-bundle library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
use Bro\WorldCoreBundle\Infrastructure\Service\ApiProxyService;
use Symfony\Component\HttpFoundation\Request;
final class ExampleUploader
{
public function __construct(private ApiProxyService $proxy) {}
public function __invoke(Request $request): array
{
return $this->proxy->requestFile('POST', 'media', $request, [
'contextKey' => 'product-images',
'mediaFolder' => 'product-images',
]);
}
}
use Bro\WorldCoreBundle\Infrastructure\Service\Clock;
final class ExampleController
{
public function __construct(private Clock $clock) {}
public function __invoke(): string
{
return $this->clock->now()->format(DATE_ATOM);
}
}
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.