Vanderkleijn .net

The personal website of...

TinyMCE plugin

pagesdropdown-screenshot.png

Description

TinyMCE is a platform independent web based Javascript HTML WYSIWYG editor control released as Open Source under LGPL by Moxiecode Systems AB. It has the ability to convert HTML TEXTAREA fields or other HTML elements to editor instances. TinyMCE is very easy to integrate into other Content Management Systems.

The TinyMCE plugin for Frog CMS changes all textareas in the "Pages" section of Frog into editor instances. To avoid possible problems with the Markdown and Textile filters, its probably best to turn those plugins off.

Feature list:

  • Easy image selection through dropdown list box.
  • Easy linking to pages within the your Frog CMS through dropdown list box.
  • True WYSIWYG possibility by choosing which CSS stylesheet TinyMCE uses.
  • Easy configuration through a preferences screen in your Frog admin section.

Note: this plugin doesn't change any Frog CMS internal code, neither does it change the TinyMCE implementation.

It uses a stock (unchanged) TinyMCE download. If you want the plugin to use the latest TinyMCE version, just replace the contents of the "tinymce" directory within the plugin directory with the files of the new TinyMCE version.

License

The TinyMCE plugin (not TinyMCE itself) is licensed under the GNU General Public License v3. The TinyMCE code is included with the plugin for your convenience only.

Current version

If you use Frog 0.9.5+, download TinyMCE plugin version 2.0.0 RC1 (zip / tar.gz)

There is a small bug in the 2.0.0 RC1 release concerning the lists/image_list.php file. Fix it by adding an else to the if statement in line 18, here is how the if statement looks after the change:

if (!$first)
print ',';
else
$first = false;

NOT RECOMMENDED, upgrade to Frog 0.9.5 - If you use Frog 0.9.4, download TinyMCE plugin version 1.3.0 (download)

  • Added support for "filter" selection.
  • Added support for i18n.
  • Added Dutch language support.
  • Added check for "administrator" or "developer" roles when trying to access TinyMCE preferences tab in backend.
  • Improved documentation.

You can also see all downloads for Frog on this site.

You can also see the complete changelist for all versions of this plugin.

 

Comments

Leave a comment yourself »

 
Your name
 
Email
 
Website
 
Anti-spam check

Please insert the result of the arithmetical operation from the following image:

Please insert the result of the arithmetical operation from this image. =
 
Comment
 
 
On 2009-12-18 at 12:01, Martijn wrote:
 

You install the plugin in the /frog/plugins folder just like any other Frog plugin.

On 2009-12-14 at 06:31, beazleybub wrote:
 

Where do you install the plugin? What folder?

Thanks

On 2009-11-20 at 17:53, Martijn wrote:
 

@Tom

If I understand correctly:

Your CMS install lives at C:\domains\tobtest
Your images (that you want to access with TinyMCE) live at: C:\domains\tobtest\public\themes\rpmc\images

The full URL to your CMS installation I assume to be: http://localhost/

This means:

Images directory: C:\domains\tobtest\public\themes\rpmc\images

URI to images: /public/themes/rpmc/images
URI to CSS file: /public/themes/rpmc/rpmctob.css

HOWEVER, IF the full URL to your CMS installation is something like: http://localhost/wolfcms/

This means:

Images directory: C:\domains\tobtest\public\themes\rpmc\images

URI to images: /wolfcms/public/themes/rpmc/images
URI to CSS file: /wolfcms/public/themes/rpmc/rpmctob.css

If that doesn't work, something else is wrong. (did you try flushing your browser's cache?)

On 2009-11-20 at 00:20, Tom wrote:
 

Has anyone used this plugin on a windows server. I've spent a lot of time trying to get the settings right but noting works: Link dropdown Image dropdown Defining my own stylesheet

Any help would be appreciated: My image directory is: C:\domains\tobtest\public\themes\rpmc\images

My CSS is at: C:\domains\tobtest\public\themes\rpmc\rpmctob.css

the relative paths would be: /public/themes/rpmc/images /public/themes/rpmc/rpmctob.css Can anyone suggest how these should be entered into the settings page ?
Thanks in advance for any help !

On 2009-11-19 at 00:05, Martijn wrote:
 

@josh - Don't think I have... but that's more a general question concerning TinyMCE. It might be down to your specific browser/version. You could check the TinyMCE forums?

On 2009-11-16 at 22:07, Josh wrote:
 

Anyone else having issues with TinyMCE removing the classes set on links?

On 2009-11-09 at 20:34, Martijn wrote:
 

@Tom - Yes. Absolute is absolute. Never tested it on Windows though. :-p

On 2009-11-06 at 20:03, Tom wrote:
 

How would you specify the alsolute path on a Windows Server ? Does it need a C: ?

for example : Absolute path to images on disk. For example: /home/user/www/public/images Thanks.

On 2009-10-19 at 22:59, Martijn wrote:
 

Hey Andy,

Most often, something like this is caused by a problem in the settings. Check them again and re-read the documentation for the plugin.

If that doesn't pan out... well, you haven't exactly given me much information to work with.

I assume you've used the correct download for your Frog version?

You could always try downloading the latest TinyMCE release from the Moxiecode website and putting that inside the tinymce directory of the plugin.

Sincerely, Martijn.

On 2009-10-15 at 12:40, Andy wrote:
 

I can't get the MCE to editor to drop down in firefox (latest version) when i select it from the filter drop down.

I can see it in the list but it wont bring the bar down.

Any ideas?

On 2009-09-08 at 17:31, Martijn wrote:
 

@Chris McB:

About the preview CSS.. maybe its just me, but why don't you simply edit the file on disk to do the import. Why should the plugin do it for you?

On 2009-09-02 at 19:28, Chris McB wrote:
 

Everything got stripped out:

<?php

require_once('../config.php');
$dir_handle = @opendir($image_list_dir) or die("Unable to open $image_public_path");

print 'var tinyMCEImageList = new Array(';
print list_dir($dir_handle,$image_list_dir,$image_public_path);
print ');';

function list_dir($dir_handle,$path,$webpath) {
$out = '';
while (false !== ($file = readdir($dir_handle))) {
$dir =$path.'/'.$file;
if(is_dir($dir) && $file != '.' && $file !='..' ) {
$handle = @opendir($dir) or die("unable to open file $file");
if ($out!='') $out.=',';
$out .= list_dir($handle, $dir, $webpath.'/'.$file);
}
elseif ($file != '.' && $file !='..') {
if ($out!='') $out.=',';

$out .= '["'.$webpath.'/'.$file.'", "'.$webpath.'/'.$file.'"]';
}
}
return $out;
closedir($dir_handle);


}
?>
On 2009-09-02 at 19:27, Chris McB wrote:
 

One other thing to fix the image list for occurences where the image directory has no files, but has sub directories with files:

On 2009-09-02 at 18:50, Chris McB wrote:
 

Apologies - didn't quite get the code right on WMD!

Remove line 65 of config.php

header("Location: $preview_css");

Replace with

$sheets = split(',',str_replace(' ','',$preview_css)); $amount = sizeof($sheets); for($i=0; $i<$amount; $i++){ echo "@import '" . $sheets[$i] . "';\n"; }
On 2009-09-02 at 18:48, Chris McB wrote:
 

Martijn,

Great work - I started using FCKEditor when I began working with Frog, but your integration of TinyMCE has taken out a lot of hassle and niggles.

Can I suggest an addition to your code?

In the configuration page, you allow for an external CSS to be loaded.

With one tweak, you can change that to multiple CSS files - as I very often require.

On line 65 of config.php, I commented out:

print("header(\"Location: $preview_css\");

"); and added in:

print("$sheets = split(',',str_replace(' ','',$preview_css)); $amount = sizeof($sheets); for($i=0; $i<$amount; $i++){ echo \"@import '\" . $sheets[$i] . \"';\n\"; }

");

As well as that code, just a quick change to the description of the text field in the settings page too.

I hope this helps someone!

On 2009-07-23 at 10:00, Martijn wrote:
 
@Andrew - If you have the same problem as Fred, it would seem the install didn't go okay? Just to make sure people realize: - TinyMCE plugin version 2.0 RC1 is for Frog 0.9.5+ - TinyMCE plugin version 1.3.0 is for Frog 0.9.4 I'll make it more clear on the site.
On 2009-07-15 at 12:29, Andrew wrote:
 
@Jason: Try 2.0 RC1 version, it's working fine.
On 2009-07-15 at 00:33, Jason wrote:
 
I got the same as Fred and Andrew. I just installed Frog 0.9.5 locally, tried setting up TinyMCE and got the 404 when clicking on the TinyMCE tab.
On 2009-07-14 at 23:57, Andrew wrote:
 
Same problem as Fred. PHP5 / MYSQL 5
On 2009-07-13 at 13:12, Martijn wrote:
 

@Fred - Haven't heard of other users with such a problem. Which version on the plugin & Frog are you using?

Also, which DB and DB version are you using?

On 2009-07-13 at 08:47, Fred wrote:
 

Great plug!

However, the tab in the menu for tinymce gives me a Content Not Found (404) page.

How comes ?

On 2009-06-18 at 01:20, vovanbo wrote:
 

Working (and fully new) image_list.php is here.

Don't forget correct image public path. It'll be without first slash, because slash having in URL_PUBLIC definition.

Have fun! :)

On 2009-06-13 at 09:15, zaim wrote:
 

I'm having the same problem with the image list not displaying. Ahmed is correct, the image_list.php is not outputting the correct JavaScript.

If you can't wait for the next release, the fix quite easy. Just edit the file "lists/image_list.php" and add the code "$first = false;" after line number 20.

You can see it here (line 21 is highlighted):

http://pastebin.com/f2d300880

On 2009-05-27 at 01:23, Martijn wrote:
 

@Emrys - I'll try to get out a new release of the plugin before I leave on my trip to Japan. No promises though, life's been a little hectic lately with me trying to finish Frog 0.9.5., being busy at work, trying to prepare for Japan and catching a sever case of the flu a week before departure. :-o lol

@Stéphane - Inside the zip/tar.gz file is a readme.txt This tells you to unzip and upload the plugin to Frog's "plugins" directory.

On 2009-05-20 at 10:06, Stéphane (french) wrote:
 

how (where) to install (configure) TinyMCE in Madebyfrog ?

Thanks

On 2009-05-12 at 01:54, Emrys wrote:
 

Hi Martijn Has there been a solution to this problem? I have the same issue - the dropdown listing the contents of /public/images does not appear?

I created a file to echo out the paths here:

http://staging.artsandhealth.org/frog/plugins/tinymce/lists/vars.php

but as you see here:

http://staging.artsandhealth.org/frog/plugins/tinymce/lists/image_list.php

it is giving an error? the permissions are all ok.

Any help greatly appreciated! Many thanks, emrys

On 2009-04-19 at 23:26, Martijn wrote:
 

Hi Ahmed, thanks for the comment.. unfortunately, the WMD editor seems to have eaten your code. Maybe you could mail it to my gmail addres?

On 2009-04-16 at 01:30, Ahmed Kandel wrote:
 

Dear Martijn, I have found a bug in v2.0.0 RC1 in image_list.php file if the image folder contains more than one file or any files other than images or any folder it will not produce the right array to TinyMCE so i have worked on that her is my code :

With all my respect.

 
Ads
Information