function fckeditor_is_enabled in FCKeditor - WYSIWYG HTML editor 6.2
Same name and namespace in other branches
- 5.2 fckeditor.module \fckeditor_is_enabled()
- 6 fckeditor.module \fckeditor_is_enabled()
Parameters
int $excl_mode 1/include, exclude otherwise:
string $excl_regex paths (drupal paths with ids attached):
string $element_id current ID:
string $get_q current path:
Return value
boolean returns true if FCKeditor is enabled
2 calls to fckeditor_is_enabled()
- fckeditor_process_textarea in ./
fckeditor.module - This function create the HTML objects required for the FCKeditor
- fckeditor_user_get_profile in ./
fckeditor.module
File
- ./
fckeditor.module, line 490 - FCKeditor - The text editor for Internet - http://www.fckeditor.net Copyright (C) 2003-2008 Frederico Caldeira Knabben
Code
function fckeditor_is_enabled($excl_mode, $excl_regex, $element_id, $get_q) {
$front = variable_get('site_frontpage', 'node');
$excl_regex = str_replace('<front>', $front, $excl_regex);
$nodetype = fckeditor_get_nodetype($get_q);
$element_id = str_replace('.', '\\.', $element_id);
$match = !empty($excl_regex) && preg_match($excl_regex, $nodetype . '@' . $get_q . '.' . $element_id);
return $excl_mode == '0' xor $match;
}