Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#313 2007-07-03 18:17:16

vittorio
Member
From: Roma caput mundi
Registered: 2006-02-01
Posts: 122
Website

Re: hak_tinymce WYSIWYG article editor

Follow up: Thanks Hakjoon. Editing the editor_content.css file (for the advanced theme) seems to work, but only in IE, not in Firefox. Do you know why?


Happily served with Txp: Strampelli.net, Brain Essence, NicolaTranfaglia.com

Offline

#314 2007-07-03 20:10:03

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

Re: hak_tinymce WYSIWYG article editor

My guess is that it’s something with the cascade. Maybe try !important see if it does anything. Tracing the style in firebug might help to see if its being overridden by something.


Shoving is the answer – pusher robot

Offline

#315 2007-07-04 08:37:08

beztak
Member
From: Czech Republic
Registered: 2005-07-21
Posts: 184
Website

Re: hak_tinymce WYSIWYG article editor

Clean instalation of TXP 4.0.5 and your plugin 0.7.1 with paragraph wrap callback is little bugy now but I think it’s in TXP core. Because when you update hak_tinymce settings, entities in wrap callback are escaped. So when you update settings again, save callback doesn’t work.

Result:

function mceTagWrap(element_id, html, body) { html = trim(html); /*check that text starts and ends with tags if not wrap it in <p>s. This only happens for single line text messages*/ if(html.charAt(0) != "<" || (html.charAt(html.length – 1) != ">" || html.charAt(html.length -2) == "/")) { html = "<p>"+html+"</p>"; } return html;
}
function trim(sInString) { sInString = sInString.replace( /^\s+/g, "" );// strip leading return sInString.replace( /\s+$/g, "" );// strip trailing
}

Last edited by beztak (2007-07-04 08:39:08)

Offline

#316 2007-07-07 20:48:46

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

Re: hak_tinymce WYSIWYG article editor

So the encoding is happening in the hak_tinymce tab right? I haven’t had a chance to test run 4.0.5 yet thanks for catching this.


Shoving is the answer – pusher robot

Offline

#317 2007-07-08 08:05:46

beztak
Member
From: Czech Republic
Registered: 2005-07-21
Posts: 184
Website

Re: hak_tinymce WYSIWYG article editor

hakjoon wrote:

So the encoding is happening in the hak_tinymce tab right?

Exactly ;)

Offline

#318 2007-07-08 09:14:24

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,091
Website GitHub Mastodon Twitter

Re: hak_tinymce WYSIWYG article editor

Hi patrick
for the first time i’m experimenting with your plugin and I just noticed another problem (using mac ff2.0.0.4, txp4.0.5)

After saving the preview loses the text colours. (this only happens in the preview and not in the ‘published’ text.)


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#319 2007-07-08 21:27:17

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

Re: hak_tinymce WYSIWYG article editor

Colak,

I’m not sure I’m understanding what is happening.


Shoving is the answer – pusher robot

Offline

#320 2007-07-21 06:40:10

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,091
Website GitHub Mastodon Twitter

Re: hak_tinymce WYSIWYG article editor

hi patrick

Sorry I haven’t been very clear above…

What I meant to say was that there seems to be a problem with the tinymce preview when the user wishes to change the colours of particular words.

if I allocate text colours and then save, the page reloads, the colours no longer show in the tinymce preview

Using tinymce try to change the colours of a couple of words and hit save.
something like:

this colour is <span style="color: #ff0000">red</span> and this is <span style="color: #0000ff">blue</span>

The second problem i found is that if I am to continue to edit the above the additional text will be blue unless I edit the html

Last edited by colak (2007-07-21 06:40:45)


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#321 2007-07-28 19:00:20

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

Re: hak_tinymce WYSIWYG article editor

Sorry guys I’ve been absent for a little bit.

Beztak: I found the source of the problem. The text_area() function now encodes the html for me. Before you had to do it yourself, so the contents are getting double encoded in the preferences page. I’ll release a fix shortly but in the meantime you can fix it by replacing this htmlspecialchars($callbacks) with just $callbacks in the hak_tinymce_prefs() function.

Colak: That happens sometimes with TinyMCE as the spans get stacked on top of each other. The only solutions I found is to use the cleanup button along with the removeformat button to cleanup the html every once in awhile when things get funky. Have you tried 2.1.1.1 to see if it’s any better?


Shoving is the answer – pusher robot

Offline

#322 2007-07-28 19:13:17

beztak
Member
From: Czech Republic
Registered: 2005-07-21
Posts: 184
Website

Re: hak_tinymce WYSIWYG article editor

Thank you. I’ll look at it. And I have one more question… I plan to use tiny_mce on more than only on 2 textareas… I need 3 or 4 (maybe 6)… If you can explain in some easy way how to do that, it would be great… I tried it by myself but it didnt work. I know this is something little bit extraordinary… so if this would be difficult, I will donate some money for development…

Offline

#323 2007-07-28 19:25:24

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

Re: hak_tinymce WYSIWYG article editor

Are you planning on using this inside TXP or somewhere else? It’s pretty easy to attach TinyMCE to multiple Textareas. The complications depend on the specific setup (a lot of the work in hak_tinymce is to make make work decently with the textile selections)

Send me an email and we can discuss it in better detail if you want.


Shoving is the answer – pusher robot

Offline

#324 2007-07-28 19:45:37

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

Re: hak_tinymce WYSIWYG article editor

I just pushed up version 0.7.2 which fixes the issue with callbacks and 0.4.5. Nothing else changes so you can just re-install the plugin file.


Shoving is the answer – pusher robot

Offline

Board footer

Powered by FluxBB