- - Site preview

PrestaShop: More characters for article names

  1. Open your database admin tool like PhpMyAdmin
  2. Go to your PrestaShop database and edit the table ps_product_lang
  3. Edit the maximum field length of name
    default value is int(10)
  4. Go to your PrestaShop root directory /classes/Product.php
  5. Edit at the line 403 the size of the name
    'name' => array('type' => self::TYPE_STRING, 'lang' => true, 'validate' => 'isCatalogName', 'required' => false, 'size' => 512),
    find param size
  6. Go to your PrestaShop root directory > src > PrestaShopBundle > Admin > Product > ProductInformation.php
  7. Edit at the line 168 the size of the name
    new AssertLength(['min' => 3, 'max' => 512]),
    find param max

And you’re done. Don’t forget to clean your cache.

An alternative (better) way is overwriting classes