Upload image through Pimcore command in the asset folder

Pimcore

Create the command folder in the AppBundle folder. Than create the ImageUploadCommand.php /var/www/html/thebricktest/thebrick/src/AppBundle/Command/ImageUploadCommand.php <?php namespace AppBundle\Command; use Pimcore\Console\AbstractCommand; use Symfony\Component\Console\Input\InputInterface; use Symfony\Component\Console\Output\OutputInterface; use Symfony\Component\Console\Input\InputArgument; use AppBundle\Service\UploadImage; class ImageUploadCommand extends AbstractCommand { protected function configure() { $this ->setName('imageupload:command') ->setDescription('Image upload command'); } protected function execute(InputInterface $input, OutputInterface $output) { $obj = …

Read More »