This bundle aims to easily integrate & use the Froala editor in Symfony 4.4+/5.0+.

Overview

KMSFroalaEditorBundle

Package version Build Status Downloads PHP Version Licence

Introduction

This bundle aims to easily integrate & use the Froala editor in Symfony 4.4+/5.0+.

If you want to use it with Symfony < 4.3, see v2 docs. v2.x is compatible with Symfony 2.x to 4.x, but some deprecations are not fixed and static files are integrated to the bundle.

There's also a v3 version available compatible with Symfony 4.3+/5.0+ but the form type options are not prefixed with froala_, which is the major reason for a v4 of the bundle.

The changelogs are available here:

Table of Contents

  1. Migration to Froala Editor bundle v4 from v3
  2. Installation
    1. Step 1: Install the bundle using composer
    2. Step 2: Add the bundle to your bundles.php
    3. Step 3: Import routes
    4. Step 4: Load Twig form widget
    5. Step 5: Configure the bundle
      1. Required
      2. Other options
    6. Step 6: Add Froala to your form
    7. Step 7: Install asset files
    8. Step 8: Display editor content
      1. Manually
      2. Using the Twig extension
    9. Step 9: Profiles (custom configurations)
  3. More configuration
    1. Plugins
    2. Concept: Image upload/manager
    3. Concept: File upload
    4. Concept: Autosave
    5. Webpack Encore configuration
  4. TODO
  5. Licence
  6. Contributing

Migration to Froala Editor bundle v4 from v3

It now supports only Symfony 4.4+ & 5.0+.

If you somehow override/inherit a class from the bundle, be careful as some parameter & return types have been added.

All form type options must now be prefixed by froala_:

// Before
$builder->add('field', FroalaEditorType::class, [
    'toolbarButtons' => [...],
]);

// After
$builder->add('field', FroalaEditorType::class, [
    'froala_toolbarButtons' => [...],
]);

Installation

Step 1: Install the bundle using composer

composer require kms/froala-editor-bundle

Note: if you install the bundle using Symfony Flex & accepted the recipe, you can skip steps 2 to 4.

Step 2: Add the bundle to your bundles.php

// config/bundles.php
return [
    //..
    KMS\FroalaEditorBundle\KMSFroalaEditorBundle::class => ['all' => true],
];

Step 3: Import routes

# config/routes.yaml 
kms_froala_editor:
    resource: '@KMSFroalaEditorBundle/Resources/config/routing.yml'
    prefix:   /froalaeditor

Step 4: Load Twig form widget

# In config/packages/twig.yaml
twig:
    form_themes:
        - '@KMSFroalaEditor/Form/froala_widget.html.twig'

Step 5: Configure the bundle

Required

First, you have to select your language, other settings are optional (see below).

# config/packages/kms_froala_editor.yaml 
kms_froala_editor:
    language: 'nl'

Other options

All Froala options (list provided here) are supported. Just add the option name (prefixed with froala_ if it's in your form type) with your value. If you want to keep Froala default value, don't provide anything in your config file. For options which require an array, provide a value array. For options which require an object, provide a key/value array.

Note that some options need some plugins (all information provided in the Froala documentation).

Example for each option type below:

# config/packages/kms_froala_editor.yaml
kms_froala_editor:
    toolbarInline: true
    tableColors: [ "#FFFFFF", "#FF0000" ]
    saveParams: { "id" : "myEditorField" }

To provide a better integration with Symfony, some custom options are added, see the full list below:

# config/packages/kms_froala_editor.yaml
kms_froala_editor:
    # Froala licence number if you want to use a purchased licence.
    serialNumber: "XXXX-XXXX-XXXX"

    # Disable CodeMirror inclusion.
    includeCodeMirror: false

    # Disable Font Awesome inclusion.
    includeFontAwesome: false

    # Disable all bundle javascripts inclusion (not concerning CodeMirror).
    # Usage: if you are using Grunt or other and you want to include yourself all scripts. 
    includeJS: false

    # Disable all bundle CSS inclusion (not concerning Font Awesome nor CodeMirror).
    # Usage: if you are using Grunt or other and you want to include yourself all stylesheets. 
    includeCSS: false

    # Change the froala base path.
    # Useful eg. when you load it from your own public directory.
    # Defaults to "/bundles/kmsfroalaeditor/froala_editor"
    basePath: "/my/custom/path".

    # Custom JS file.
    # Usage: add custom plugins/buttons...
    customJS: "/custom/js/path"

Step 6: Add Froala to your form

Just add a Froala type in your form:

use KMS\FroalaEditorBundle\Form\Type\FroalaEditorType;

$builder->add('field', FroalaEditorType::class);

All configuration items can be overridden:

$builder->add('field', FroalaEditorType::class, [
    'froala_language'      => 'fr',
    'froala_toolbarInline' => true,
    'froala_tableColors'   => ['#FFFFFF', '#FF0000'],
    'froala_saveParams'    => ['id' => 'myEditorField'],
]);

Step 7: Install asset files

To install the asset files, there is froala:install command that downloads the last version available of Froala Editor and puts it by default in the vendor/kms/froala-editor-bundle/src/Resources/public/froala_editor/ directory:

bin/console froala:install

There are a few arguments/options available:

  • First (and only) argument (optional): the absolute path where the files will be put after download. Defaults to vendor/kms/froala-editor-bundle/src/Resources/public/froala_editor/.
  • Option tag: the version of Froala that will be installed (eg. v3.0.1). Defaults to master.
  • Option clear (no value expected, disabled by default): Allow the command to clear a previous install if the path already exists.

After you launched the install command, you have to link assets, eg.:

bin/console assets:install --symlink public

Step 8: Display editor content

Manually

To preserve the look of the edited HTML outside of the editor you have to include the following CSS files:

">

<link href="../css/froala_style.min.css" rel="stylesheet" type="text/css" />

Also, you should make sure that you put the edited content inside an element that has the class fr-view:

{{ myContentHtml|raw }}
">
<div class="fr-view">
    {{ myContentHtml|raw }}
div>

Using the Twig extension

To use the Twig extension, simply call the display function (note that the front CSS file is not included if the parameter includeCSS is false):

{{ froala_display(myContentHtml) }}

Step 9: Profiles (custom configurations)

You can define several configuration profiles that will be reused in your forms, without repeating these configurations.

When using a profile, the root configuration options will be used & overridden:

# config/packages/kms_froala_editor.yaml
kms_froala_editor:
    heightMax: 400
    attribution: false
    profiles:
        profile_1:
            heightMax: 500
use KMS\FroalaEditorBundle\Form\Type\FroalaEditorType;

$builder->add('field', FroalaEditorType::class, [
    'froala_profile' => 'profile_1',
]);

In this example, profile_1 profile will have these configuration options set:

  • heightMax: 500
  • attribution: false

More configuration

Plugins

All Froala plugins are enabled, but if you don't need one of them, you can disable some plugins...

# config/packages/kms_froala_editor.yaml
kms_froala_editor:
    # Disable some plugins.
    pluginsDisabled: [ "save", "fullscreen" ]

... or chose only plugins to enable:

# config/packages/kms_froala_editor.yaml
kms_froala_editor:
    # Enable only some plugins.
    pluginsEnabled: [ "image", "file" ]

Plugins can be enabled/disabled for each Froala instance by passing the same array in the form builder.

Concept: Image upload/manager

This bundle provides an integration of the Froala image upload concept to store your images on your own web server (see custom options for configuration like upload folder).

If you want to use your own uploader, you can override the configuration (if you need to do that, please explain me why to improve the provided uploader).

To provide a better integration with Symfony, some custom options are added, see the full list below:

# config/packages/kms_froala_editor.yaml
kms_froala_editor:
    # The image upload folder in your /web directory.
    # Default: "/upload".
    imageUploadFolder: "/my/upload/folder"

    # The image upload URL base.
    # Usage: if you are using URL rewritting for your assets.
    # Default: same value as provided as folder.
    imageUploadPath: "/my/upload/path"

Concept: File upload

This bundle provides an integration of the Froala file upload concept to store your files on your own web server (see custom options for configuration like upload folder).

If you want to use your own uploader, you can override the configuration (if you need to do that, please explain me why to improve the provided uploader).

To provide a better integration with Symfony, some custom options are added, see the full list below:

# config/packages/kms_froala_editor.yaml
kms_froala_editor:
    # The file upload folder in your /web directory.
    # Default: "/upload".
    fileUploadFolder: "/my/upload/folder"

    # The file upload URL base.
    # Usage: if you are using URL rewritting for your assets.
    # Default: same value as provided as folder.
    fileUploadPath: "/my/upload/path"

    # Your public directory, from the root directory.
    # Default: "/public"
    publicDir: "/home"

Concept: Autosave

The Froala autosave concept to automatically request a save action on your server is working, just enter the correct options in your configuration file:

# config/packages/kms_froala_editor.yaml
kms_froala_editor:
    saveURL: "my_save_route"
    saveInterval: 2500
    saveParam: "content"

To provide a better integration with Symfony, some custom options are added, see the full list below:

# config/packages/kms_froala_editor.yaml
kms_froala_editor:
    # Add some parameters to your save URL.
    # Usage: if you need parameters to generate your save action route (see save explaination below).
    # Default: null.
    saveURLParams: { "id" : "myId" }

You can add some parameters in your save route (see custom options).

Webpack Encore configuration

If you want to load Froala asset files using npm/yarn and Webpack Encore, here's how to do it:

import FroalaEditor from 'froala-editor';
import 'froala-editor/css/froala_editor.pkgd.min.css';
import 'froala-editor/css/froala_style.min.css';

// Load your languages
import 'froala-editor/js/languages/fr.js';

// Load all plugins, or specific ones
import 'froala-editor/js/plugins.pkgd.min.js';
import 'froala-editor/css/plugins.pkgd.min.css';

window.FroalaEditor = FroalaEditor;

function froalaDisplayError(p_editor, error ) {
    alert(`Error ${error.code}: ${error.message}`);
}

window.froalaDisplayError = froalaDisplayError;

Now you can disable Froala bundle CSS/JS inclusion:

# config/packages/kms_froala_editor.yaml
kms_froala_editor:
    includeJS: false
    includeCSS: false

Don't forget to import the generated Encore CSS/JS files in your HTML if needed.

TODO

  • Add some tests

Licence

This bundle provides an integration of the WYSIWYG Froala Editor commercial version. Please read the Froala licence agreement and go to the pricing page if you don't have a licence.

Contributing

Feel free to contribute, like sending pull requests to add features/tests.

Note there are a few helpers to maintain code quality, that you can run using these commands:

composer cs:dry # Code style check
composer phpstan # Static analysis
vendor/bin/simple-phpunit # Run tests
Comments
  • Integrate Froala with Sonata

    Integrate Froala with Sonata

    Hey

    I am used Froala Editor with Sonata Admin

    $formMapper->add('content', 'froala');

    And I have this exception :

    Impossible to access an attribute ("options") on a null variable in SonataAdminBundle:Form:form_admin_fields.html.twig at line 326

    opened by Khaldoun488 19
  • Upload - Symfony 4 - The

    Upload - Symfony 4 - The "kms_froala_editor.media_manager" service or alias has been removed or inlined when the container was compiled.

    Hello !

    When trying to upload a file, the routes for file management seems to be broken. Here is the error message :

    The "kms_froala_editor.media_manager" service or alias has been removed or inlined when the container was compiled. You should either make it public, or stop using the container directly and use dependency injection instead.

    The "kms_froala_editor.media_manager" service or alias has been removed or inlined when the container was compiled. You should either make it public, or stop using the container directly and use dependency injection instead.
    
      at vendor\symfony\dependency-injection\Container.php:259
      at Symfony\Component\DependencyInjection\Container->get('kms_froala_editor.media_manager')
         (vendor\symfony\framework-bundle\Controller\ControllerTrait.php:61)
      at Symfony\Bundle\FrameworkBundle\Controller\Controller->get('kms_froala_editor.media_manager')
         (vendor\kms\froala-editor-bundle\Controller\MediaController.php:28)
      at KMS\FroalaEditorBundle\Controller\MediaController->uploadImageAction(object(Request))
         (vendor\symfony\http-kernel\HttpKernel.php:149)
      at Symfony\Component\HttpKernel\HttpKernel->handleRaw(object(Request), 1)
         (vendor\symfony\http-kernel\HttpKernel.php:66)
      at Symfony\Component\HttpKernel\HttpKernel->handle(object(Request), 1, true)
         (vendor\symfony\http-kernel\Kernel.php:190)
      at Symfony\Component\HttpKernel\Kernel->handle(object(Request))
         (public\index.php:37)```
    
    I'm using Symfony 4.0
    
    Thank you for you help !
    opened by adrienlamotte 18
  • Configuration for Symfony 3.0.6

    Configuration for Symfony 3.0.6

    I have installed and configured it as given in the instructions, but while adding it to the form as given below, it says Could not load type "froala"

    $builder->add( "yourField", "froala" );

    Can you specifically tell how to add it in form in Symfony 3, because Symfony 3 requires Type and Class to be included and declared, explicitly like below mentioned example:-

    Type:- use Symfony\Component\Form\Extension\Core\Type\TextType;

    and Class- builder->add('title', TextType::class)

    Do we include it from any namespace, as above? Thanks..

    bug 
    opened by prakashsinghgaur 16
  • Massive upgrade :)

    Massive upgrade :)

    Hi,

    Following the v3.0.0 upgrade, I did some changes that I wanted to do for a long time.

    I couldn't split it into several PRs, but I could try if needed.

    Here are the main changes:

    • Symfony 4.3+ support only. I could try to make it compatible with 3.4+ (so 4.0+) if needed
    • PHP 7.1+; stop supporting unsupported PHP versions
    • Added a command to download the editor instead of putting files in the repository; then the bundle won't need an upgrade for a simple editor upgrade (excluding new options): bin/console froala:install
    • Fixed most deprecations for Symfony 4.1+ (routing, container injection in controller, doctrine inflector...)
    • The form widget layout is no longer loaded using DI; it will be added to configuration using the flex recipe (see https://github.com/symfony/recipes-contrib/pull/686)

    The README.md file still needs an upgrade, but before doing it I'd like to get your feedback about this PR and know, if it's accepted, how tags/branches will be handled so I could redirect people to the right docs.

    Thanks!

    opened by jmsche 14
  • [WIP] escape form options/variables with froala namespace

    [WIP] escape form options/variables with froala namespace

    This will show how this fix will be done.

    There is a discrepancy with coding standard since my computer is set up for Symfony CS and the repository is now following it (big one is tab -> space).

    I have test it (without any configured) and it's working so far.

    opened by mpoiriert 9
  • Drop Symfony 2 support?

    Drop Symfony 2 support?

    Hi,

    I'm wondering if Symfony 2 support should be dropped or not, as maintaining it becomes harder and harder - especially if support is for 2.3+.

    Eg. Symfony 4.1 throws deprecations for the routing controller format - should be KMS\FroalaEditorBundle\Controller\MediaController::uploadImageAction instead of KMSFroalaEditorBundle:Media:uploadImage.
    If I'm not wrong, this notation is available for 2.8 but not 2.3, so the fix would be hard to apply.

    WDYT?

    opened by jmsche 9
  • An exception has been thrown during the rendering of a template

    An exception has been thrown during the rendering of a template

    In Symfony4 editor is not working:

    An exception has been thrown during the rendering of a template ("The "templating.helper.assets" service or alias has been removed or inlined when the container was compiled. You should either make it public, or stop using the container directly and use dependency injection instead.").

    {{ froala_display(form.content) }}

    opened by miojamo 9
  • Notice: Undefined index: basePath in /vendor/kms/froala-editor-bundle/Service/OptionManager.php line 68

    Notice: Undefined index: basePath in /vendor/kms/froala-editor-bundle/Service/OptionManager.php line 68

    Hi! I've followed all the steps described in readme but when I try to use the form type it throws:

    Notice: Undefined index: basePath in /vendor/kms/froala-editor-bundle/Service/OptionManager.php line 68
    

    I've already defined a basePath in config but didn't worked.

    bug 
    opened by cassianotartari 9
  • Prefix form type options & code cleanup

    Prefix form type options & code cleanup

    Hi,

    Sending a big PR :)

    Here's what's been done:

    • Escape form options/variables with "froala_" namespace (cherry-picked from @mpoiriert commit)
    • Support for ajax loading (cherry-picked from @mpoiriert commit)
    • Add options related to FontAwesome third party plugin
    • Add parameter types & return types everywhere possible
    • Fix Twig extension
    • Change directory structure
    • Exclude some files & directories for releases
    • Fix plugins' CSS not loaded correctly
    • Don't load packaged Froala JS/CSS files as they contain all plugins
    • Setup php-cs-fixer for Github Actions
    • Setup phpstan for Github Actions
    • README update

    After merging this PR, it will require a major version bump (to 4.0.0) as it introduces huge BC breaks, eg. form type option prefixes and added parameter/return types.

    Even if it's not really easy, could you please review the PR before merging it?

    Thank you!

    opened by jmsche 7
  • [bug] Upload image on my server, Error 4 : Parsing response failed

    [bug] Upload image on my server, Error 4 : Parsing response failed

    Hi, When i want upload an image in froala editor i have this error :

    image

    Error log :

    image

    My code :

    JS

    $('.froala-editor').froalaEditor({
        toolbarButtons: ['fullscreen', 'undo', 'redo', '|',
            'bold', 'italic', 'underline', '|',
            'fontFamily', 'fontSize', 'color', 'emoticons', 'insertHR', 'clearFormatting', '|',
            'paragraphFormat', 'paragraphStyle', 'quote', 'align', 'formatOL', 'formatUL', 'outdent', 'indent', '|',
            'insertLink', 'insertImage', 'insertVideo', 'insertTable', '|',
            'html', 'help'
        ],
    
        saveURL: Routing.generate('admin_upload_image'),
    
        // Set the image upload URL.
        imageUploadURL: Routing.generate('admin_upload_image'),
    
        // Additional upload params.
        imageUploadParams: {id: 'my_editor'},
    
        // Set request type.
        imageUploadMethod: 'POST',
    
        // Set max image size to 5MB.
        imageMaxSize: 5 * 1024 * 1024,
    
        // Allow to upload PNG and JPG.
        imageAllowedTypes: ['jpeg', 'jpg', 'png']
    
    }).on('froalaEditor.image.beforeUpload', function (e, editor, images) {
        // Return false if you want to stop the image upload.
        })
        .on('froalaEditor.image.uploaded', function (e, editor, response) {
            // Image was uploaded to the server.
    
            console.log(uploadUrl, uploadParam, uploadParams);
            console.log('Image uploaded');
            console.log(e);
            console.log(editor);
            console.log(response);
        })
        .on('froalaEditor.image.inserted', function (e, editor, $img, response) {
            // Image was inserted in the editor.
            console.log('Image inserted');
            console.log(e);
            console.log(editor);
            console.log($img);
            console.log(response);
        })
        .on('froalaEditor.image.replaced', function (e, editor, $img, response) {
            // Image was replaced in the editor.
        })
        .on('froalaEditor.image.error', function (e, editor, error, response) {
            console.log('Image error');
            console.log(e);
            console.log(editor);
            console.log(error);
            console.log(response);
        })
    ;
    

    Upload function:

     /**
         * @Route("/uploadImage", name="admin_upload_image", options={"expose": true})
         * @Method({"GET", "POST"})
         * @param Request $request
         * @return JsonResponse
         */
        public function uploadImageAction(Request $request)
        {
            $mediaManager = $this->get("kms_froala_editor.media_manager");
            $path         = $request->request->get("path");
            $folder       = $request->request->get("folder") . '/upload';
            $rootDir      = $this->get("kernel")->getRootDir();
            $basePath     = $request->getBasePath() . '/upload';
    
            return $mediaManager->uploadImage($request->files, $rootDir, $basePath, $folder, $path);
    
        }
    

    What could be the problem?

    opened by tagalpha 7
  • Add stable tag

    Add stable tag

    Hi, this package hasn't enabled auto-update inside Packagist so, the last merged PR is not referenced yet. Can you update the reference and by the way, can you tag a stable version?

    Thanks in advance.

    opened by benatespina 7
  • Bug froala_widget.html.twig

    Bug froala_widget.html.twig

    Hello,

    I wonder if there is not a bug when using the customJS parameter

    In the file "src / Resources / views / Form / froala_widget.html.twig" line 51

    Shouldn't we use the "froala_customJS" variable?

    Regards

    opened by lrix 1
  • Why tag 4.0.0?

    Why tag 4.0.0?

    Hi,

    I'm wondering why version 4.0.0 has been tagged with this change? https://github.com/froala/KMSFroalaEditorBundle/commit/7e6856fcaf2b14933ad66e49a6e62562bd7e735e

    The version number in the command is only an example, not the real value which will be pulled.

    Can this tag/release be reverted please? And removed from packagist as well?

    opened by jmsche 8
  • Will there be multiple css and/or js files included?

    Will there be multiple css and/or js files included?

    I think about to use this bundle for my projects. BUT - I wonder if there will be multiple includes of this css and js files:

     {# CSS. #}
        {% if froala_includeFontAwesome %}
            <link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" />
        {% endif %}
        {% if froala_includeCodeMirror %}
            <link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.3.0/codemirror.min.css" />
        {% endif %}
    
        {% if froala_includeCSS %}
            <link rel="stylesheet" type="text/css" href="{{ asset( froala_basePath ~ 'css/froala_editor.min.css' ) }}" />
            <link rel="stylesheet" type="text/css" href="{{ asset( froala_basePath ~ 'css/froala_style.min.css' ) }}" />
    
            {% if froala_arrOption[ "theme" ] is defined %}
                <link rel="stylesheet" type="text/css" href="{{ asset( froala_basePath ~ 'css/themes/' ~ froala_arrOption[ "theme" ] ~ '.min.css' ) }}" />
            {% endif %}
    
            {% for plugin in froala_arrPluginCSS %}
                <link rel="stylesheet" type="text/css" href="{{ asset( froala_basePath ~ 'css/' ~ plugin ~ '.min.css' ) }}" />
            {% endfor %}
    
        {% endif %}
    
        {# Editor textarea. #}
        <textarea {{ block( "widget_attributes" ) }}>{{ value }}</textarea>
    
        {# JS. #}
    
        {% if froala_includeCodeMirror %}
            <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.3.0/codemirror.min.js"></script>
            <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.3.0/mode/xml/xml.min.js"></script>
        {% endif %}
    
        {% if froala_includeJS %}
            <script type="text/javascript"  src="{{ asset( "bundles/kmsfroalaeditor/misc.js" ) }}"></script>
            <script type="text/javascript"  src="{{ asset( froala_basePath ~ 'js/froala_editor.min.js' ) }}"></script>
    
            <!--[if lt IE 9]>
    		<script type="text/javascript" src="{{ asset( froala_basePath ~ 'js/froala_editor_ie8.min.js' ) }}"></script>
    		<![endif]-->
            <script type="text/javascript" src="{{ asset( froala_basePath ~ 'js/languages/' ~ froala_arrOption.language ~ '.js' ) }}"></script>
    
            {% for plugin in froala_arrPluginJS %}
                <script type="text/javascript" src="{{ asset( froala_basePath ~ 'js/' ~ plugin ~ '.min.js' ) }}"></script>
            {% endfor %}
        {% endif %}
    
        {% if froala_customJS is defined %}
            <script type="text/javascript"  src="{{ asset( customJS ) }}"></script>
        {% endif %}
    

    I mean - this will be included for every form field, when I have multiple on my pages?

    Is that right?

    opened by MichaelBrauner 3
  • getPdf and spellChecker plugins does nothing

    getPdf and spellChecker plugins does nothing

    Hello guys, When I click on getPdf button this seems to do nothing, I enabled all plugins especially the print plugin but it does nothing.

    This is the same for spellChecker I have a js error Your subscription to the service has expired. Contact [email protected] to learn how to resume your subscription.

    Do I have to buy Froala to get this working?

    opened by gabrielncl 3
  • Use CodeMirror twig ?

    Use CodeMirror twig ?

    Hello,

    On a symfony 3.4 with KMS Froala 2.9.8 i'm tring to use Twig : https://codemirror.net/mode/twig/index.html

    $builder->add('twigContent', FroalaEditorType::class, array('codeMirrorOptions' => array(
                    'indentWithTabs' => true,
                    'lineNumbers' => true,
                    'lineWrapping' => true,
                    'mode'=> array('name' => "twig", 'base' => "text/html"),
                    'tabMode' => 'indent',
                    'tabSize' => 2
                )
                , 'label' => 'Contenu', 'attr' => array('class' => 'froalaMailTransTemplate', 'id' => 'froalaMailTransTemplate'), 'required' => false))
    

    if i remove the code 'mode'=> array('name' => "twig", 'base' => "text/html") it's working i have HTML but no "twig" markup

    What did i miss ?

    thanks

    Guldil

    opened by guldil 0
Releases(v4.0.1)
  • v4.0.1(Jun 9, 2021)

    • Fix for Track changes Toolbar sometimes not opening in Froala website
    • Fix for Table, tbody, tr, td having generic styling
    • Fix for CSS style rules for some elements which were broken
    Source code(tar.gz)
    Source code(zip)
  • v4.0.0(Jun 3, 2021)

    • Enable / Disable Track Changes
    • Show / Hide Track Changes
    • Accept Single Change feature in Track Changes
    • Reject Single Change feature in Track Changes
    • Accept ALL Changes feature in Track Changes
    • Reject ALL Changes feature in Track Changes
    • Markdown Support
    Source code(tar.gz)
    Source code(zip)
  • v3.2.7(May 19, 2021)

    • Fixed Froala editor scrolls up if you use enter in table
    • Fixed Enter_BR: Multiple characters gets deleted on backspace
    • Fixed space getting removed between link and text when loading the content with html.set method
    • Fixed uncaught TypeError: Super expression must either be null or a function, not undefined
    • Fixed , with htmlUntouched the empty character is deleted
    • Fixed blur fires if the user clicks a toolbar button in Mobile
    • Fixed , when attribution: false in Froala v3 editor appearance looks odd
    • Fixed , user cannot link the selected word if the enter option is set to BR
    • Fixed, dropdowns has a horizontal scroll in Safari (Mac)
    • Fixed, current instance loses the focus if the user clicks on the button of the shared toolbar
    • Fixed , char counter is missing when the inlineToolbar is enabled
    • Fixed, Ionic4: toolbarBottom option doesn't work
    • Fixed, cannot upload .svg image in the editor
    • Fixed, update State in functional component
    • Fixed , ImageEdit popup doesn't appear on mobile devices
    • Fixed, external javascript is not executing in the editor
    • Fixed, replace fill-available to stretch, because spec had been changed
    • Fixed, uncaught TypeError: Cannot read property 'length' of undefined
    • Fixed, MS SharePoint integration support
    • Fixed, keyboard issue on IOS device running a ionic/capacitor app on angular
    • Fixed, editor cannot be initialized for the second time with ng-if directive
    • Fixed, After setting contenteditable false, can still select the text apply features(like bold) from toolbar
    • Fixed, click on the Clean button should remove all formatting
    • Fixed, form tag removed when editor is itself contained with a form
    • Fixed, pasting a numbered list from Word resets numbers to 1
    • Fixed, pressing backspace on quoted area which contains fr-inner class, removes the whole quoted area or content.
    • Fixed, Content gets deleted on the Enter click in Safari
    • Fixed, adding image caption adds empty P tags on the above and below of the image
    • Fixed, wordPaste plugin unconditionally removes empty table cells in Chrome
    • Fixed, cannot apply an option from the dropdown
    • Fixed, image alignment does not work as expected
    • Fixed, method events.focus() does not work
    • Fixed , TypeError: Cannot read property 'classList' of null
    • Fixed, editTable popup doesn't appear on mobile devices
    • Fixed, TypeError: Cannot read property '0' of undefined
    • Fixed, after pasting the image, the user cannot type
    • Fixed Uncaught TypeError: Cannot read property 'hasOwnProperty' of null
    • Fixed, Unexpected behavior with style height: 100vh in the content when fullpage option is enabled
    • Fixed, quick insert button shows half after adding a table in fullscreen mode
    • Fixed , xss vulnerability issue
    Source code(tar.gz)
    Source code(zip)
  • v2.9.8(Apr 30, 2020)

  • v2.9.7(Apr 27, 2020)

    • Improved Document Ready mode functionalities and alignment improvements, such as:
      • iFrame styling parity.
      • Improved alignment and displaying inline images.
      • Improved Toolbar alignment and placeholder in Document Ready mode.
    • Enhanced copy and paste capabilities, including:
      • Style / format maintained in lists and tables when pasted into the editor.
      • Improved copying, pasting lists, creating indentation and styling.
    • Improved content editing functionalities, such as adding descriptive text, dragging, select, delete and copy/paste formatted text inside the editor.
      • Users can now designate whether content is editable.
    • Enhanced superscript and subscript text editing feature.
    • Improved Font awesome icons.
    • Improved text inside table feature.
    • Hitting backspace won’t delete the line break anymore.
    • Improved video upload and embedding features in iOS and alignment issues in safari browser
    • Improved embedly integration.
    • Improved dropdown in android.
    • Enhanced captioning and resizing in feature images.
    • Improved alignment of toolbar over the text areas.
    • More minor bug fixes like HTMLallowed, enhanced read property of ‘nextSibling’ defined, improved enter/return Key behavior and resolved tab issues inside
      tag.
    Source code(tar.gz)
    Source code(zip)
Owner
Froala
Editing software for fast development with better developer and user experience in mind.
Froala
A very slight PHP framework, very easy to use and integrate.

A very slight PHP framework, very easy to use and integrate.

Jerry 95 Oct 26, 2022
Bugsnag notifier for the Symfony PHP framework. Monitor and report errors in your Symfony apps.

Bugsnag exception reporter for Symfony The Bugsnag Notifier for Symfony gives you instant notification of errors and exceptions in your Symfony PHP ap

Bugsnag 43 Nov 22, 2022
Leaf is a PHP framework that helps you create clean, simple but powerful web apps and APIs quickly and easily.

Leaf is a PHP framework that helps you create clean, simple but powerful web apps and APIs quickly and easily. Leaf introduces a cleaner and much simpler structure to the PHP language while maintaining it's flexibility. With a simple structure and a shallow learning curve, it's an excellent way to rapidly build powerful and high performant web apps and APIs.

Leaf Framework 706 Jan 3, 2023
The Symfony PHP framework

Symfony is a PHP framework for web and console applications and a set of reusable PHP components. Symfony is used by thousands of web applications (in

Symfony 27.8k Jan 2, 2023
Ergonode is modern PIM platform based on Symfony and Vue.js frameworks.

Modern Product Information Management Platform Ergonode is modern PIM platform based on Symfony and Vue.js frameworks. It has modular structure and gi

Ergonode 100 Dec 19, 2022
Symprowire is a PHP MVC Framework based and built on Symfony, using the ProcessWire CMS as DBAL and Service Provider.

Symprowire - PHP MVC Framework for ProcessWire 3.x Symprowire is a PHP MVC Framework based and built on Symfony using ProcessWire 3.x as DBAL and Serv

Luis Mendez 7 Jan 16, 2022
Yii2-symfonymailer - Yii 2 Symfony mailer extension.

Yii Mailer Library - Symfony Mailer Extension This extension provides a Symfony Mailer mail solution for Yii framework 2.0. For license information ch

Yii Software 28 Dec 22, 2022
PHPStan Symfony Framework extensions and rules

PHPStan Symfony Framework extensions and rules PHPStan This extension provides following features: Provides correct return type for ContainerInterface

PHPStan 564 Dec 30, 2022
Quite possibly the smallest MVC framework you'll ever use.

Swiftlet Swiftlet is quite possibly the smallest MVC framework you'll ever use. And it's swift. Licensed under the MIT license. Buzzword compliance ✔

Elbert Alias 429 Nov 13, 2022
A powerful yet easy-to-use PHP micro-framework designed to help you build dynamic and robust Web applications - fast!

A powerful yet easy-to-use PHP micro-framework designed to help you build dynamic and robust Web applications - fast! Condensed in a single ~65KB file

Bong Cosca 2.6k Dec 30, 2022
Multi-process coroutine edition Swoole spider !! Learn about Swoole's network programming and the use of its related APIs

swoole_spider php bin/spider // Just do it !! Cache use Swoole\Table; use App\Table\Cache; $table = new Table(1<<20); // capacity size $table->column

null 3 Apr 22, 2021
Lite & fast micro PHP abuse library that is **easy to use**.

Utopia Abuse Utopia framework abuse library is simple and lite library for managing application usage limits. This library is aiming to be as simple a

utopia 23 Dec 17, 2022
BEdita, ready to use back-end API, extensible API-first Content Management

BEdita, a back-end API BEdita 4 is a ready to use back-end API to handle the data of your mobile, IoT, web and desktop applications. It's also an exte

BEdita 65 Oct 31, 2022
PIP is a tiny application framework built for people who use a LAMP stack.

PIP is a tiny application framework built for people who use a LAMP stack. PIP aims to be as simple as possible to set up and use.

Ron Marasigan 244 Dec 30, 2022
A set of ready-made regex helper methods for use in your Laravel application.

Regex A set of ready-made regex helper methods for use in your Laravel application. Installation composer require hotmeteor/regex Usage Regex comes wi

Adam Campbell 229 Dec 25, 2022
a framework for WebDevelop based on the mvc structure. The name of this project for Fun because everyone can use it. Completely simple and powerful structure for all your projects

A_A (-.-) ▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄ |-| █▄─▄▄─█▄─██─▄█─▄▄▄▄█─▄▄▄▄█▄─█─▄█─▄▄▄─██▀▄─██─▄

MasihGhaznavi 7 Jun 29, 2022
Tarantool connector for yii2 framework. Allow to use activerecord, schemas, widgets and more.

Tarantool connector for yii2 framework Tarantool connector for yii2 framework. Allow to use framework abstractions such as ActiveRecord, Schema, Table

Andrey 11 Nov 21, 2021
TrailLamp is a lightweight, easy-to-use Php MVC framework that can be used to build web applications and REST APIs.

TrailLamp Introduction TrailLamp is a lightweight, easy-to-use Php MVC framework that can be used to build web applications and REST APIs. Installatio

Etorojah Okon 14 Jun 10, 2022