-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.inc.php
47 lines (39 loc) · 1.62 KB
/
config.inc.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<?php
// init addon
$REX['ADDON']['name']['ckeditor'] = 'CKEditor';
$REX['ADDON']['page']['ckeditor'] = 'ckeditor';
$REX['ADDON']['version']['ckeditor'] = '3.0.0';
$REX['ADDON']['author']['ckeditor'] = "RexDude";
$REX['ADDON']['supportpage']['ckeditor'] = 'forum.redaxo.de';
$REX['ADDON']['perm']['ckeditor'] = 'ckeditor[]';
// permissions
$REX['PERM'][] = 'ckeditor[]';
if ($REX['REDAXO']) {
// add lang file
$I18N->appendFile($REX['INCLUDE_PATH'] . '/addons/ckeditor/lang/');
// includes
require($REX['INCLUDE_PATH'] . '/addons/ckeditor/classes/class.rex_ckeditor_utils.inc.php');
// default settings (user settings are saved in data dir!)
$REX['ADDON']['ckeditor']['settings'] = array(
'smart_strip' => true,
'resize_grip' => false
);
// overwrite default settings with user settings
rex_ckeditor_utils::includeSettingsFile();
// add subpages
$REX['ADDON']['ckeditor']['SUBPAGES'] = array(
array('', $I18N->msg('ckeditor_start')),
array('modules', $I18N->msg('ckeditor_modules')),
array('settings', $I18N->msg('ckeditor_settings')),
array('help', $I18N->msg('ckeditor_help'))
);
// add css/js to page header
if (rex_request('page') != 'mediapool' && rex_request('page') != 'linkmap') { // needed for new redaxo.js patching the link dialog etc., as outehwise insertLink() etc. is definied twice
rex_register_extension('OUTPUT_FILTER', 'rex_ckeditor_utils::addToOutputFilter'); // better loading time with output filter and avoids flickering
}
// add backend css for addon styles only
if (rex_request('page') == 'ckeditor') {
rex_register_extension('OUTPUT_FILTER', 'rex_ckeditor_utils::addBackendCSS');
}
}
?>