TinyMCE works - but functions do not open correct windows

Having trouble installing serendipity?
Post Reply
bebr
Regular
Posts: 34
Joined: Thu Apr 26, 2007 2:47 am

TinyMCE works - but functions do not open correct windows

Post by bebr »

On my SY 1.1.2 I installed the tinyMCE editor plugin. It works, I can use the styles from the menu, change the fonts etc.

What does _not_ work is any function that is meant to open a popup/window for further input - for example inserting an image:
javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceAdvImage');

It opens a small window, but the content is always the blog's homepage, not the form that it should show. The same happens with "Edit HTML source", "Insert link" etc.

I understand this is not a pure serendipity problem but somewhere between SY and tinyMCE. Maybe someone has some experience with this plugin or an idea what to check - thanks.
// Bernd
Last edited by bebr on Fri Jul 27, 2007 2:54 am, edited 1 time in total.
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: TinyMCE works - but functions do open correct windows

Post by garvinhicking »

Hi!

Are you using mod_rewrite URL rewriting? You might need to put a .htaccess file into your tinemce directory with "RewriteEngine Off".

HTH,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
bebr
Regular
Posts: 34
Joined: Thu Apr 26, 2007 2:47 am

Ok, and mediamanager?

Post by bebr »

This does it - great!

Now I get a form for the URL of the image to be inserted, and it works.

It would be fine though to see a list or thumbnails of images from mediamanager - I understood that was the idea of it?
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Ok, and mediamanager?

Post by garvinhicking »

Hi!

THe problem is that all WYSIWYG editors have different rules on how to integrate custom buttons. I didn't have the time to check out how to add buttons to TInyMCE to embed the media manager, so this media manager implemention is only available when using the bundled WYISWYG editor.

If there's someone with tinymce knowledge who knows how to transfer that functionality to tinymce, that would be much appreciated.

Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
bebr
Regular
Posts: 34
Joined: Thu Apr 26, 2007 2:47 am

Post by bebr »

Ok, understood.
And the problem will be not only to start the mediamanager but to adapt the Javascript Code so that a chosen image is inserted correctly.
Unfortunately, my JS knowledge is insufficient for this.
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking »

Hi!

Actually, the s9y js functions (in serendipity_editor.js) already take care of returning the proper HTML!

So all that is needed is a way for a tinymce button to open a popup window and add the possibility so that the popup window can pass raw HTML back to the originating textarea...

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
bebr
Regular
Posts: 34
Joined: Thu Apr 26, 2007 2:47 am

Post by bebr »

Ok, hope someone can do this.
Maybe some time we see a default editor that can do both - use the user's styles (that was the reason why I installed tinyMCE at all) _and_ integrate the media manager.
blog.brockha.us
Regular
Posts: 695
Joined: Tue Jul 03, 2007 3:34 am
Location: Berlin, Germany
Contact:

Post by blog.brockha.us »

As I am using TinyMCE in my blog, too, and needed the access to the Media DB, I implemented this button yesterday (see my German post in my blog. If you don't understand German you will at least notice the picture showing the new button. http://blog.brockha.us/index.php?/archi ... inden.html )

I will release the extra button and a description how to add it soon. I was unsure, how to release it, but the only way seems to offer the extra code at my blog. I already changed the TinyMCE plugin to be prepared for adding new buttons and plugins, it is version 0.9 now and it is needed to realize this patch.

P.S.: I added an english version of the article mentioned. Found a nice s9y plugin: Multilingual articles. Very cool! :-)
- Grischa Brockhaus - http://blog.brockha.us
- Want to make me happy? http://wishes.brockha.us/
bebr
Regular
Posts: 34
Joined: Thu Apr 26, 2007 2:47 am

Post by bebr »

I was offline for some weeks .. thanks, that sounds like the solution I was looking for.

Now for installing your modification - maybe I'm a bit stupid, but I only find the discussion link. I have no "shared installation" and I don't bother hacking my code directly, but I'm not proficient with CVS - could you provide a step-by-step guide or link for simple users like me?

(German is no problem, only I like to stick to english here so that more users can profit from our enlightenments.)
Post Reply