Enabling the CMS content widgets button in the WYSIWYG Editor
Edit on GitHubThe article describes how to enable the CMS content widgets button in the WYSIWYG editor on the Edit Placeholders page.
The content widget drop-down button is used to add CMS content widgets to a block or a page. However, starting with the 201907.0 version, the content widget drop-down button has been disabled in the WYSIWYG editor.
If you want to enable this button on a project level, do the following:
- Create the
src/Pyz/Zed/CmsContentWidget/CmsContentWidgetConfig.php
file. - Insert the following code in that file:
<?php
namespace Pyz\Zed\CmsContentWidget;
use Spryker\Zed\CmsContentWidget\CmsContentWidgetConfig as SprykerCmsContentConfig;
class CmsContentWidgetConfig extends SprykerCmsContentConfig
{
/**
* @return bool
*/
public function isEditorButtonEnabled(): bool
{
return true;
}
}
After the updates have been saved, the content widget drop-down button will be enabled and displayed next to the Content Item drop-down button in the WYSIWYG editor:
Thank you!
For submitting the form