Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

138
Vistas
ckeditor 5 id with array not appear

If I use this code ckeditor does not appear

              $value = 'categories_description_' . $languages[$i]['id'] . '[' . $languages[$i]['id'] . ']'; // ====> here ==> categories_description_[1]
              echo HTMLOverrideAdmin::textAreaCkeditor($value, 'soft', '750', '300', (isset($categories_description[$languages[$i]['id']]) ? str_replace('& ', '& ', trim($categories_description[$languages[$i]['id']])) : $CLICSHOPPING_CategoriesAdmin->getCategoryDescription($cInfo->categories_id, $languages[$i]['id'])), 'id="' . $value . '"'); ?>

===> result example : <textarea name="categories_description_1[1]" id="categories_description_1[1]" />

If I use this code ckeditor appear

          $value = 'categories_description_' . $languages[$i]['id']; /// ===> here  ==> categories_description_1
          echo HTMLOverrideAdmin::textAreaCkeditor($value, 'soft', '750', '300', (isset($categories_description[$languages[$i]['id']]) ? str_replace('& ', '&amp; ', trim($categories_description[$languages[$i]['id']])) : $CLICSHOPPING_CategoriesAdmin->getCategoryDescription($cInfo->categories_id, $languages[$i]['id'])), 'id="' . $value . '"'); ?>

I do not understand why we can not use an array inside the script ckeditor. I need to display ckeditor for multilanguage approach

categories_description_[1] ... categories_description_[2] allow to save my data inside my db in function of the language.

example of the js (not work) with categories_description_1[1] :

ClassicEditor
    .create(document.querySelector('#categories_description_1[1]') , {
        toolbar: ['heading', '|', 'bold', 'italic', 'link', 'bulletedList', 'numberedList', 'imageUpload', 'ckfinder', 'blockQuote', 'insertTable', 'mediaEmbed', 'undo', 'redo', '|', 'help']
    } )

example of the js (work) with categories_description_1 :

ClassicEditor
    .create(document.querySelector('#categories_description_1[1]') , {
        toolbar: ['heading', '|', 'bold', 'italic', 'link', 'bulletedList', 'numberedList', 'imageUpload', 'ckfinder', 'blockQuote', 'insertTable', 'mediaEmbed', 'undo', 'redo', '|', 'help']
    } )

thank you.

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda