Projet

Général

Profil

Paste
Télécharger (2,55 ko) Statistiques
| Branche: | Révision:

root / drupal7 / sites / all / modules / ckeditor / ckeditor.api.php @ a2baadd1

1
<?php
2

    
3
/**
4
 * CKEditor - The text editor for the Internet - http://ckeditor.com
5
 * Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
6
 *
7
 * == BEGIN LICENSE ==
8
 *
9
 * Licensed under the terms of any of the following licenses of your
10
 * choice:
11
 *
12
 *  - GNU General Public License Version 2 or later (the "GPL")
13
 *    http://www.gnu.org/licenses/gpl.html
14
 *
15
 *  - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
16
 *    http://www.gnu.org/licenses/lgpl.html
17
 *
18
 *  - Mozilla Public License Version 1.1 or later (the "MPL")
19
 *    http://www.mozilla.org/MPL/MPL-1.1.html
20
 *
21
 * == END LICENSE ==
22
 *
23
 * @file
24
 * CKEditor Module for Drupal 7.x
25
 *
26
 * This module allows Drupal to replace textarea fields with CKEditor.
27
 *
28
 * CKEditor is an online rich text editor that can be embedded inside web pages.
29
 * It is a WYSIWYG (What You See Is What You Get) editor which means that the
30
 * text edited in it looks as similar as possible to the results end users will
31
 * see after the document gets published. It brings to the Web popular editing
32
 * features found in desktop word processors such as Microsoft Word and
33
 * OpenOffice.org Writer. CKEditor is truly lightweight and does not require any
34
 * kind of installation on the client computer.
35
 */
36

    
37
/**
38
 * Hook to register the CKEditor plugin - it would appear in the plugins list on the profile setting page.
39
 */
40
function hook_ckeditor_plugin() {
41
  return array(
42
    'plugin_name' => array(
43
      // Name of the plugin used to write it.
44
      'name' => 'plugin_name',
45
      // Description of the plugin - it would be displayed in the plugins management section of profile settings.
46
      'desc' => t('Plugin description'),
47
      // The full path to the CKEditor plugins directory, with the trailing slash.
48
      'path' => drupal_get_path('module', 'my_module') . '/plugin_dir/',
49
      'buttons' => array(
50
        'button_name' => array(
51
          'icon' => 'path to button icon',
52
          'label' => 'Button Label',
53
        )
54
      )
55
    )
56
  );
57
}
58

    
59
/**
60
 * Hook to register the CKEditor security filter - it would appear in the security filters list on the profile setting page.
61
 */
62
function hook_ckeditor_security_filter() {
63
  return array(
64
    'security_filter_name' => array(
65
      // Title of the security filter - it would be displayed in the security filters section of profile settings.
66
      'title' => t('Security filter title'),
67
      // Description of the security filter - it would be displayed in the security filters section of profile settings.
68
      'description' => t('Security filter description'),
69
    )
70
  );
71
}
72

    
73
?>