You are here

function ckeditor_plugins_render in CKEditor - WYSIWYG HTML editor 6

Same name and namespace in other branches
  1. 7 includes/ckeditor.lib.inc \ckeditor_plugins_render()

Render CKEditor plugins path

2 calls to ckeditor_plugins_render()
ckeditor_load_plugins in includes/ckeditor.lib.inc
List of CKEditor plugins
ckeditor_process_textarea in ./ckeditor.module
This function creates the HTML objects required for CKEditor.

File

includes/ckeditor.lib.inc, line 472
CKEditor - The text editor for the Internet - http://ckeditor.com Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.

Code

function ckeditor_plugins_render($plugins) {
  $render = array();
  $render["%base_path%"] = base_path();
  $render["%editor_path%"] = ckeditor_path(TRUE) . '/';
  $render["%ckeditor_path%"] = drupal_get_path('module', 'ckeditor') . '/';
  $render["%plugin_dir%"] = $render["%ckeditor_path%"] . 'plugins/';
  $render["%plugin_dir_extra%"] = ckeditor_plugins_path(TRUE) . '/';
  foreach ((array) $plugins as $i => $plugin) {
    $plugins[$i]['path'] = str_replace(array_keys($render), array_values($render), $plugin['path']);
  }
  return $plugins;
}