Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#616 2009-10-01 13:03:22

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: hak_tinymce WYSIWYG article editor

@dreamer: in the old tiny_mce folder go into plugins and copy the txp_image folder somewhere (this is the image picker). Then replace the old tiny_mce folder with jscripts/tinymce from the new package. Then re-add the txp_image folder to the plugins directory. The image picker should really be the only thing that doesn’t work with 3.x out of the box. I’m hoping enabling the 2.x compatibility plugin will make it work.

@wet: document_base_url is set to hu which I thought would have handled that (at least I remember testing for it). I’ll see if I can figure out what’s going on. In the meantime playing with the url conversion options might help temporarily. document_base_url is set before any of the user defined options so it can be redefined by the user.

Thanks everyone for their patience while I work to get this fixed. I’m only able to work in small bursts and Im trying to clean up stuff while I’m at it. I can get rid of a lot of stuff that I needed when I wrote this back for 4.0.3.

Last edited by hakjoon (2009-10-01 14:47:41)


Shoving is the answer – pusher robot

Offline

#617 2009-10-01 16:53:51

dreamer
Member
Registered: 2007-06-08
Posts: 242

Re: hak_tinymce WYSIWYG article editor

Hakjoon- I will look into this and get back to you.

This is another issue that I posted elsewhere . It may or may not be related to the hak tinymce plugin but here’s the issue;

I can’t access the left sidebar of the Write Interface; Advanced Options, Recent Articles, Textile Help . When I click on them, they won’t drop down at all.

I think the culprit is that the plugin is used. Because when i go to articles that are using Textile, I can access the drop downs. But when I go to articles that uses the plugin ( defaulting to “Leave Text Untouched”), then I can’t access them.

This is occuring in at least IE7 and FF3. Who knows what else.

Suggestions?

Offline

#618 2009-10-01 19:50:10

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: hak_tinymce WYSIWYG article editor

It’s the plugin’s fault. The way the toggles get wired up changed in 4.2 and the method I’m using to inject the toggle editor link is breaking that. This is fixed in the new version I’m working on.

Check out the conversation started by this post it has a temporary solution, that seems to be working.

Let me know if you don’t understand what to do and I can write up something a little clearer.

Last edited by hakjoon (2009-10-01 19:50:32)


Shoving is the answer – pusher robot

Offline

#619 2009-10-02 04:49:13

dreamer
Member
Registered: 2007-06-08
Posts: 242

Re: hak_tinymce WYSIWYG article editor

That fix worked! Thx.

Last edited by dreamer (2009-10-02 05:04:11)

Offline

#620 2009-10-02 05:35:56

dreamer
Member
Registered: 2007-06-08
Posts: 242

Re: hak_tinymce WYSIWYG article editor

@dreamer: in the old tiny_mce folder go into plugins and copy the txp_image folder somewhere (this is the image picker). Then replace the old tiny_mce folder with jscripts/tinymce from the new package. Then re-add the txp_image folder to the plugins directory. The image picker should really be the only thing that doesn’t work with 3.x out of the box. I’m hoping enabling the 2.x compatibility plugin will make it work.

I tried this method, but am stuck with enabling the 2.x compat plugin. I copied the following line of code to the end of plugin code;

tinyMCE.init({
	theme : "advanced",
	mode : "textareas",
	plugins : "compat2x"
});

but I got the following error;

Parse error: parse error, unexpected '{', expecting ')' in /home/content/p/v/t/pvtlabel/html/private_cigar/textpattern/lib/txplib_misc.php(594) : eval()'d code on line 633
The above errors were caused by the plugin:hak_tinymce 

I’m not even sure if did the first part right because in Google Chrome, the WYSIWYG editor doesn’t work at all and defaults to Textile. Though, the same WYSIWYG works in FF.

Just to clarify, I did this;
  • replaced the /tiny_mce folder with /tinymce folder from the new download. Deactivated the old folder by renaming it to tiny_mce-old
  • readded the txpimage folder to the new /tinymce folder

Last edited by dreamer (2009-10-02 05:37:25)

Offline

#621 2009-10-02 14:53:26

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: hak_tinymce WYSIWYG article editor

The problem is just with that tinyMCE.init() call. You can just add the compat plugin in the initalization boxes in the tinyMCE tab.

So get rid of the tinyMCE.init you added and in Extensions -> hak_tinymce in the Initialization for article body editor: box just add compat2x to the plugins that are already there. at least txpimage should be there by default.

You can do the same for excerpt.


Shoving is the answer – pusher robot

Offline

#622 2009-10-02 17:29:33

dreamer
Member
Registered: 2007-06-08
Posts: 242

Re: hak_tinymce WYSIWYG article editor

Hmm….It still doesn’t work. This is what the line of code in the extensions tab looks like;

plugins : "searchreplace,txpimage,compat2x",

Here’s a screenshot of the problem. Like i said, the interface is gone even before I put in the compat2x call. It happened once I uploaded the new tiny_mce folder. Not sure what I could’ve done wrong here….

Offline

#623 2009-10-02 19:52:01

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: hak_tinymce WYSIWYG article editor

Do you not get the Toggle Editor link at all? Are any Javascript errors being logged? My first guess is that it’s not finding the tiny_mce js file but it should still show you the toggle editor and stuff.


Shoving is the answer – pusher robot

Offline

#624 2009-10-02 23:37:01

dreamer
Member
Registered: 2007-06-08
Posts: 242

Re: hak_tinymce WYSIWYG article editor

I get the Toggle Editor. Though, regardless of browser, I can’t tick off the article/excerpt checkboxes to off-mode. I can tick them on, but not off.

As for debugging javascript, I wouldn’t even know where to begin as I know next to nothing about it.

Offline

#625 2009-10-03 00:12:19

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: hak_tinymce WYSIWYG article editor

The checkbox thing is very weird. Is this on a publicly available server? I’d be happy to see if I can figure anything out if you’re comfortable with giving me temporary access.

If you have firebug you can use the Net tab to see if the tiny_mce js file is 404’ing.

Nevermind it doesn’t work. I think the API calls to instantiate the editor are just too different. You could try the last 2.x release and see if it works better in webkit. http://sourceforge.net/projects/tinymce/files/ I think it’s 2..1.3

I’m making good progress with the 4.2.0 update. If you could have people use firefox in the short term.

Last edited by hakjoon (2009-10-03 00:27:58)


Shoving is the answer – pusher robot

Offline

#626 2009-10-03 05:50:14

dreamer
Member
Registered: 2007-06-08
Posts: 242

Re: hak_tinymce WYSIWYG article editor

Bleh. Unfortunately, the hyperlink button still doesn’t work on this. Though, the actual WYSIWYG editor works now. thanks for helping though

Offline

#627 2009-10-09 18:13:26

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: hak_tinymce WYSIWYG article editor

Quick Update. I have a version working with TXP 4.2.0 and the latest TinyMCE. I just need to get the image plugin working now.

If you think there would be value in it without that plugin, I can package up a release while I get that working.


Shoving is the answer – pusher robot

Offline

#628 2009-10-12 09:34:25

amordecosmos
Plugin Author
From: London (Hometown: Vancouver)
Registered: 2004-08-03
Posts: 120
Website

Re: hak_tinymce WYSIWYG article editor

Hakjoon,

You have my vote for a 4.2, latest TinyMCE plugin – even without the image plugin.

And thank you for the version already in service – it has helped my users greatly.

Offline

#629 2009-10-14 01:26:00

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: hak_tinymce WYSIWYG article editor

4.2.0 prerelease seems to mostly be working.

A few things:
  • no image plugin yet (working on it)
  • firebug will report an error when you expand the editor toggle, because txp does not allow plugins to add panes to the list of savable panes. I’m going to try and suppress that for now and hopefully come up with a patch to change that behavior.
  • toggle editor link moved below Textile Help because the help ui callback does not get the current context like the others. I’m going to work on submitting a patch for this as well (this one is easy).
  • this is 4.2.0 only

Please report any problems. If anyone wants to help I have it up on bitbucket now.


Shoving is the answer – pusher robot

Offline

#630 2009-10-14 16:13:52

jelle
Member
Registered: 2006-06-07
Posts: 165

Re: hak_tinymce WYSIWYG article editor

hakjoon wrote:

4.2.0 prerelease

Hi, Patrick. That links delivers a .zip with a whole lot of folders (Users\hakjoon\sites\txp.test\textpattern\hak_tinymce\hak_tinymce-dist\)

….but nothing else :(

Last edited by jelle (2009-10-14 16:14:22)

Offline

Board footer

Powered by FluxBB