Skip to content

Instantly share code, notes, and snippets.

@scorchio
Created January 17, 2012 22:27
Show Gist options
  • Save scorchio/1629397 to your computer and use it in GitHub Desktop.
Save scorchio/1629397 to your computer and use it in GitHub Desktop.
Sample for overriding CKeditor settings when used with the WYSIWYG modul in Drupal
<?php
function scor_ckeditor_config_wysiwyg_editor_settings_alter(&$settings, $context) {
if ($context['profile']->editor == 'ckeditor') {
$settings['toolbar'] = array(
array(
'PasteText', 'PasteFromWord', 'RemoveFormat', '-',
'Link', 'Unlink', 'Anchor', '-',
'Image', 'Flash', 'CreateDiv', 'break', '-',
'Source', 'Maximize'),
'/',
array(
'Bold', 'Italic', 'Underline', '-',
'Strike', 'Superscript', 'Subscript', '-',
'JustifyLeft', 'JustifyCenter', 'JustifyRight', '-',
'Blockquote', '-',
'BulletedList', 'NumberedList', '-',
'Format')
);
$settings['skin'] = 'kama';
$settings['language'] = 'hu';
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment