lemonmind / pimcore-localized-assets
Pimcore Localized Assets - localize your assets with no duplicating files
Installs: 969
Dependents: 0
Suggesters: 0
Security: 0
Stars: 7
Watchers: 1
Forks: 0
Open Issues: 1
Type:pimcore-bundle
Requires
- pimcore/pimcore: ^10.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.6
- phpstan/phpstan: ^1.4
- symfony/phpunit-bridge: ^6.1
This package is auto-updated.
Last update: 2024-12-18 15:40:08 UTC
README
Pimcore Bundle to localize your assets with same file.
Installation
composer require lemonmind/pimcore-localized-assets bin/console pimcore:bundle:enable PimcoreLocalizedAssetsBundle bin/console pimcore:bundle:install PimcoreLocalizedAssetsBundle
After installation predefined assets metadata definitions with name "localized_asset_name" should be visible. Each language should has its own entity.
Usage
In specific asset in "Custom Metadata" add predefined metadata from "Localized Assets Bundle" group. Then add values that should be replaced from original name.
So for example if asset has default path /images/tree.jpg on spanish page it will be replaced with /images/bosque.jpg.
It works in documents and data objects also with thumbnails.
Run phpstan and php-cs-fixer
There is prepared a composer script to run both phpstan and php-cs-fixer.
composer fix