Commit 3d8d9857 authored by webchick's avatar webchick

Issue #2029737 by ifrik, batigolix, Wim Leers: Create hook_help() for ckeditor module.

parent 8671e6c1
......@@ -6,6 +6,30 @@
*/
/**
* Implements hook_help().
*/
function ckeditor_help($path, $arg) {
switch ($path) {
case 'admin/help#ckeditor':
$output = '';
$output .= '<h3>' . t('About') . '</h3>';
$output .= '<p>' . t('The CKEditor module provides a visual text editor and adds a toolbar to text fields. Users can use buttons to format content and to create semantically correct and valid HTML. The CKEditor module uses the framework provided by the <a href="@text_editor">Text Editor module</a>. It requires JavaScript to be enabled in the browser. For more information, see <a href="@doc_url">the online documentation for the CKEditor module</a> and the <a href="@cke_url">CKEditor website</a>.', array( '@doc_url' => 'https://drupal.org/documentation/modules/ckeditor', '@cke_url'=>'http://ckeditor.com', '@text_editor' => url('admin/help/editor'))) . '</p>';
$output .= '<h3>' . t('Uses') . '</h3>';
$output .= '<dl>';
$output .= '<dt>' . t('Enabling CKEditor for individual text formats') . '</dt>';
$output .= '<dd>' . t('CKEditor has to be enabled and configured separately for individual text formats from the <a href="@formats">Text formats and editors page</a> because the filter settings for each text format can be different. For more information, see the <a href="@text_editor">Text Editor help page</a> and <a href="@filter">Filter help page</a>.', array('@formats' => url('admin/config/content/formats'), '@text_editor' => url('admin/help/editor'), '@filter' => url('admin/help/filter'))) . '</dd>';
$output .= '<dt>' . t('Configuring the toolbar') . '</dt>';
$output .= '<dd>' . t('When CKEditor is chosen from the <em>Text editor</em> drop-down menu, its toolbar configuration is displayed. You can add and remove buttons from the <em>Active toolbar</em> by dragging and dropping them, and additional rows can be added to organize the buttons.') . '</dd>';
$output .= '<dt>' . t('Formatting content') . '</dt>';
$output .= '<dd>' . t('CKEditor only allow users to format content in accordance with the filter configuration of the specific text format. If a text format excludes certain HTML tags, the corresponding toolbar buttons are not displayed to users when they edit a text field in this format. For more information see the <a href="@filter">Filter help page</a>.', array('@filter' => url('admin/help/filter'))) . '</dd>';
$output .= '<dt>' . t('Toggling between formatted text and HTML source') . '</dt>';
$output .= '<dd>' . t('If the <em>Source</em> button is available in the toolbar, users can click this button to disable the visual editor and edit the HTML source directly. After toggling back, the visual editor uses the allowed HTML tags to format the text — independent of whether buttons for these tags are available in the toolbar. If the text format is set to <em>limit the use of HTML tags</em>, then all excluded tags will be stripped out of the HTML source when the user toggles back to the text editor.') . '</dd>';
$output .= '</dl>';
return $output;
}
}
/*
* Implements hook_library_info().
*/
function ckeditor_library_info() {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment