We are using the latest version of all software.
We have ckeditor working properly.
Drpual is working correctly.
I installed ckfinder and then I purchased ckfinder and put in the code and website id in the file
config.php
added return isset($_SESSION['IsAuthorized']) && $_SESSION['IsAuthorized']; to the check authentication
Both ckeditor and ckfinder are in their own directories under sites/all/libraries
Checked the directory permission on userfiles to 777 under the ckfinder directory
When I go to add a new post and click on the image icon ckfinder opens but there is no browse buton. I have searched these boards for a few simple answers but cannot find any.
I have tried many ideas but I cannot seem to get it to work.
Please help a newbie and please be specific. Please do not just point me back to the very inadequate installation manual that says it will just work?
We have ckeditor working properly.
Drpual is working correctly.
I installed ckfinder and then I purchased ckfinder and put in the code and website id in the file
config.php
added return isset($_SESSION['IsAuthorized']) && $_SESSION['IsAuthorized']; to the check authentication
Both ckeditor and ckfinder are in their own directories under sites/all/libraries
Checked the directory permission on userfiles to 777 under the ckfinder directory
When I go to add a new post and click on the image icon ckfinder opens but there is no browse buton. I have searched these boards for a few simple answers but cannot find any.
I have tried many ideas but I cannot seem to get it to work.
Please help a newbie and please be specific. Please do not just point me back to the very inadequate installation manual that says it will just work?

Re: ckfinder + ckeditor + Drupal integration
Re: ckfinder + ckeditor + Drupal integration
http://docs.cksource.com/CKEditor_3.x/Developers_Guide/File_Browser_%28Uploader%29
Re: ckfinder + ckeditor + Drupal integration
Re: ckfinder + ckeditor + Drupal integration
http://drupal.org/node/462146?mode=2&sort=2
ckfinder archivesites/all/librariessites/all/libraries/ckfinder
sites/all/libraries/ckeditorsites/all/libraries/ckfinderckfinder
ckeditor.incpatchedwysiwyg-6.x-2.0function wysiwyg_ckeditor_settings
function wysiwyg_ckeditor_settings($editor, $config, $theme) { $settings = array( 'basePath' => base_path() . $editor['library path'] . '/', // 'skin' => 'office2003', 'width' => '100%', 'height' => '420', 'filebrowserBrowseUrl' => base_path() . $editor['library path'] . '/ckfinder/ckfinder.html', 'filebrowserImageBrowseUrl' => base_path() . $editor['library path'] . '/ckfinder/ckfinder.htm l?Type=Images', 'filebrowserFlashBrowseUrl' => base_path() . $editor['library path'] . '/ckfinder/ckfinder.htm l?Type=Flash', 'filebrowserUploadUrl' => base_path() . $editor['library path'] . '/ckfinder/core/connector/ph p/connector.php?command=QuickUpload&type=Files', 'filebrowserImageUploadUrl' => base_path() . $editor['library path'] . '/ckfinder/core/connect or/php/connector.php?command=QuickUpload&type=Images', 'filebrowserFlashUploadUrl' => base_path() . $editor['library path'] . '/ckfinder/core/connect or/php/connector.php?command=QuickUpload&type=Flash', // By default, CKeditor converts most characters into HTML entities. Since // it does not support a custom definition, but Drupal supports Unicode, we // disable at least the additional character sets. CKeditor always converts // XML default characters '&', '<', '>'. // @todo Check whether completely disabling ProcessHTMLEntities is an option. 'IncludeLatinEntities' => FALSE, 'IncludeGreekEntities' => FALSE, ); isset($config['theme']) ? $settings['skin'] = $theme : $settings['skin'] = 'kama'; if (isset($config['block_formats'])) { $settings['FontFormats'] = strtr($config['block_formats'], array(',' => ';')); } ........ ........ ........BIG BUT
Re: ckfinder + ckeditor + Drupal integration
function CheckAuthentication() { //WARNING : DO NOT simply return "true". By doing so, you are allowing //"anyone" to upload and list the files in your server. You must implement //some kind of session validation here. Even something very simple as... // return isset($_SESSION['IsAuthorized']) && $_SESSION['IsAuthorized']; //... where $_SESSION['IsAuthorized'] is set to "true" as soon as the //user logs in your system. //return false; return true; } $baseUrl = 'http://www.xxxxx.com/drupal/sites/default/files/'; $baseDir = '/var/www/htdocs/drupal/sites/default/files/';http://docs.cksource.com/CKFinder/CKFinder_for_PHPfunction CheckAuthentication()sites/all/modules/wysiwyg/editors/ckeditor.inc
Re: ckfinder + ckeditor + Drupal integration
/** * This function must check the user session to be sure that he/she is * authorized to upload and access files in the File Browser. * * @return boolean */ function CheckAuthentication() { //WARNING : DO NOT simply return "true". By doing so, you are allowing //"anyone" to upload and list the files in your server. You must implement //some kind of session validation here. Even something very simple as... // return isset($_SESSION['IsAuthorized']) && $_SESSION['IsAuthorized']; //... where $_SESSION['IsAuthorized'] is set to "true" as soon as the //user logs in your system. static $authenticated; if (!isset($authenticated) && empty($authenticated) == TRUE || $authenticated == FALSE) { $drupal_path = "../../../../"; if(!file_exists($drupal_path . "/includes/bootstrap.inc")) { $drupal_path = "../../.."; do { $drupal_path .= "/.."; $depth = substr_count($drupal_path, ".."); } while(!($bootstrapFileFound = file_exists($drupal_path . "/includes/bootstrap.inc")) && $depth<10); } if (!isset($bootstrapFileFound) || $bootstrapFileFound) { $cwd = getcwd(); chdir($drupal_path); require_once "./includes/bootstrap.inc"; drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL); global $user; if (!is_array($user->session)) { $user->session = array(); } if (is_null($user->session['authenticated'])) { $user->session['authenticated'] = ''; } if (is_array($user->roles) && is_null($user->roles[1])) { $user->session['authenticated'] = true; } else { $user->session['authenticated'] = false; } $authenticated = $user->session['authenticated']; } chdir($cwd); } return $authenticated; } CheckAuthentication(); /* To make it easy to configure CKFinder, the $baseUrl and $baseDir can be used. Those are helper variables used later in this config file. */ /* $baseUrl : the base path used to build the final URL for the resources handled in CKFinder. If empty, the default value (/userfiles/) is used. Examples: $baseUrl = 'http://example.com/ckfinder/files/'; $baseUrl = '/userfiles/'; ATTENTION: The trailing slash is required. */ // regexpression validation preg_match('(^/([^/]+))',$_SERVER['REQUEST_URI'], $uri_matches); // app root directory location $root_directory = rtrim($_SERVER['DOCUMENT_ROOT'], '/'); //$root_directory = ''; // media asset directory location $base_directory = $root_directory.'/sites/default/files/'; $header_url = ''; if (empty($_SERVER['HTTPS'])) { $header_url = 'http://'; } else { $header_url = 'https://'; } $root_url = $header_url.$_SERVER['SERVER_NAME']; $base_url = $root_url.'/sites/default/files/'; // if the uri contains a sub-directory if(isset($uri_matches[1])){ $sub_site_dir = '/sites/'.$_SERVER['HTTP_HOST'].'.'.$uri_matches[1]; $sub_site_path = $root_directory.$sub_site_dir; if(is_dir($sub_site_path)) { $base_url = $root_url.$sub_site_dir.'/files/'; $base_directory = $sub_site_path.'/files/'; } } $baseUrl = $base_url; /* $baseDir : the path to the local directory (in the server) which points to the above $baseUrl URL. This is the path used by CKFinder to handle the files in the server. Full write permissions must be granted to this directory. Examples: // You may point it to a directory directly: $baseDir = '/home/login/public_html/ckfinder/files/'; $baseDir = 'C:/SiteDir/CKFinder/userfiles/'; // Or you may let CKFinder discover the path, based on $baseUrl: $baseDir = resolveUrl($baseUrl); ATTENTION: The trailing slash is required. */ $baseDir = $base_directory;Re: ckfinder + ckeditor + Drupal integration
http://drupal.org/project/wysiwyg
function your_module_name_init() { // added to enable the ckfinder for the ckeditor in the wysiwyg api module. drupal_add_js('sites/all/libraries/ckfinder/ckfinder.js'); }/** start javascript **/ /** * Attach this editor to a target element. */ Drupal.wysiwyg.editor.attach.ckeditor = function(context, params, settings) { // Apply editor instance settings. CKEDITOR.config.customConfig = ''; settings.on = { instanceReady: function(ev) { var editor = ev.editor; // Get a list of block, list and table tags from CKEditor's XHTML DTD. // @see <a href="http://docs.cksource.com/CKEditor_3.x/Developers_Guide/Output_Formatting. " title="http://docs.cksource.com/CKEditor_3.x/Developers_Guide/Output_Formatting. " rel="nofollow">http://docs.cksource.com/CKEditor_3.x/Developers_Guide/Output_Formatting. </a> var dtd = CKEDITOR.dtd; var tags = CKEDITOR.tools.extend({}, dtd.$block, dtd.$listItem, dtd.$tableContent); // Set source formatting rules for each listed tag except <pre>. // Linebreaks can be inserted before or after opening and closing tags. if (settings.apply_source_formatting) { // Mimic FCKeditor output, by breaking lines between tags. for (var tag in tags) { if (tag == 'pre') { continue; } this.dataProcessor.writer.setRules(tag, { indent: true, breakBeforeOpen: true, breakAfterOpen: false, breakBeforeClose: false, breakAfterClose: true }); } } else { // No indents or linebreaks; for (var tag in tags) { if (tag == 'pre') { continue; } this.dataProcessor.writer.setRules(tag, { indent: false, breakBeforeOpen: false, breakAfterOpen: false, breakBeforeClose: false, breakAfterClose: false }); } } }, pluginsLoaded: function(ev) { // Override the conversion methods to let Drupal plugins modify the data. var editor = ev.editor; if (editor.dataProcessor && Drupal.settings.wysiwyg.plugins[params.format]) { editor.dataProcessor.toHtml = CKEDITOR.tools.override(editor.dataProcessor.toHtml, function(originalToHtml) { // Convert raw data for display in WYSIWYG mode. return function(data, fixForBody) { for (var plugin in Drupal.settings.wysiwyg.plugins[params.format].drupal) { if (typeof Drupal.wysiwyg.plugins[plugin].attach == 'function') { data = Drupal.wysiwyg.plugins[plugin].attach(data, Drupal.settings.wysiwyg.plugins.drupal[plugin], editor.name); data = Drupal.wysiwyg.instances[params.field].prepareContent(data); } } return originalToHtml.call(this, data, fixForBody); }; }); editor.dataProcessor.toDataFormat = CKEDITOR.tools.override(editor.dataProcessor.toDataFormat, function(originalToDataFormat) { // Convert WYSIWYG mode content to raw data. return function(data, fixForBody) { data = originalToDataFormat.call(this, data, fixForBody); for (var plugin in Drupal.settings.wysiwyg.plugins[params.format].drupal) { if (typeof Drupal.wysiwyg.plugins[plugin].detach == 'function') { data = Drupal.wysiwyg.plugins[plugin].detach(data, Drupal.settings.wysiwyg.plugins.drupal[plugin], editor.name); } } return data; }; }); } }, focus: function(ev) { Drupal.wysiwyg.activeId = ev.editor.name; } }; // Attach editor. editor = CKEDITOR.replace(params.field, settings); CKFinder.SetupCKEditor( editor, '/sites/all/libraries/ckfinder/' ); }; /** end javascript **/CKFinder no image
Everthing is working on CKFinder but when I go to add a new post and click on the image icon ckfinder opens but when I go to save the post it saves but the image isn't there on the front page. I only see this "[img]".