Page 1 of 2

JCE Editor implemented in MyBlog

Posted: Mon Sep 01, 2008 7:21 am
by MindArchr
I was successful in implementing JCE in MyBlog. I was not able to implement all of the features such as the Advanced Link, Image Manager, or Spell Checker, but for the most part, I have most of the buttons I need. I am not sure if this will work for anyone else, this is only what has worked for me.

Open up yourjoomladirectory/components/com_myblog/templates/admin/write.html

Open this write.html in a code editor. Go to line 21. Change the line from this:

Code: Select all

$tinyMCEPath =  $cms->get_path('plugin-live') . '/editors/tinymce/jscripts/tiny_mce/tiny_mce_gzip.php';
to

Code: Select all

$tinyMCEPath =  $cms->get_path('plugin-live') . '/editors/jce/jscripts/tiny_mce/tiny_mce_gzip.php';
Save the file after changing the line.

I didn't modify anything else, only the buttons I wanted implemented. Once again, not sure if this will work for anyone else, if it will cause any errors, etc. so USE AT YOUR OWN RISK!

Re: JCE Editor implemented in MyBlog

Posted: Sun Aug 16, 2009 11:05 pm
by Red Horse
Hi,

Have you found a method that works with the latest versions of Joomla, JCE, and Myblog?

Thanks,
Patrick

Re: JCE Editor implemented in MyBlog

Posted: Mon Aug 17, 2009 7:35 am
by MindArchr
Sorry no I haven't....but I will look into it in the next few weeks and if I come up with a solution, I'll post it here.

Re: JCE Editor implemented in MyBlog

Posted: Mon Aug 17, 2009 10:07 am
by Red Horse
Thanks. I'll also post the solution here if I happen to find it sooner.

Re: JCE Editor implemented in MyBlog

Posted: Wed Sep 02, 2009 3:18 pm
by vijay555com
Guys,

Following on from a thread on Azrul's Blog, I've knocked together a patch to get My Blog working again, and to additionally enable the JCE editor.
I've also enabled the advanced functions in JCE - see here, highlighted in yellow:
Image

To enable JCE:
http://vijay555.com/!images/FixingMyBlog.jpg

Step 1. Install a modern build of JCE, and activate it in your Joomla Global Configuration.

Step 2. Using FTP etc, find and backup the file:
/YourJoomlaInstall/components/com_myblog/templates/admin/write_1512.html

Step 3. Then edit that file. About 32 lines down, find:

Code: Select all

if( $build == 12 )
{
$tinyMCEPath = rtrim( JURI::root() , '/' ) . '/plugins/editors/tinymce/jscripts/tiny_mce/tiny_mce.js';
}
else
{
$tinyMCEPath = rtrim( JURI::root() , '/' ) . '/plugins/editors/tinymce/jscripts/tiny_mce/tiny_mce_gzip.js';
}
And add the lines at the bottom (the echo line is not necessary, just to show it worked):

Code: Select all

if( $build == 12 )
{
$tinyMCEPath = rtrim( JURI::root() , '/' ) . '/plugins/editors/tinymce/jscripts/tiny_mce/tiny_mce.js';
}
else
{
$tinyMCEPath = rtrim( JURI::root() , '/' ) . '/plugins/editors/tinymce/jscripts/tiny_mce/tiny_mce_gzip.js';

//VJ mod
echo"VJ Mod: Build !=12. Using JCE";
$tinyMCEPath = rtrim( JURI::root() , '/' ) . '/plugins/editors/jce/tiny_mce/tiny_mce.js';
}
Enabling advanced features is slightly more convoluted, but basically requires editing write_1512.html to enable them in JCE.
If you require this functionality, drop me an email at vijay AT_SYMBOL vijay555.com and I'll send you a copy of my file.
I'm not posting it here right now, pending slightly further testing by Patrick et al!

V

Re: JCE Editor implemented in MyBlog

Posted: Wed Sep 02, 2009 3:45 pm
by Red Horse
The patch file for getting the more advanced JCE features works fine for me, I'll post here after further testing.

Thanks V,
Patrick

Re: JCE Editor implemented in MyBlog

Posted: Sat Sep 12, 2009 12:56 pm
by jordwbush
Thank you, vijay

The patch file is working perfectly for me. That's what I'm looking for.

Thank you for your hard work.

Re: JCE Editor implemented in MyBlog

Posted: Sat Sep 12, 2009 11:01 pm
by vijay555com
Guys,

I was asked to address an issue where some of the JCE stuff is "offscreen" within the My Blog editor, eg specifically for the Image Editor, dialog buttons being offscreen.

I've looked into it and made some CSS changes, and further changes to the template file, to make the "Fullscreen" mode much more fullscreen.
This is done by removing the useless My Blog blended borders, and enlarging the My Blog editor to take up much more of the screen space (almost 100%, leaving a bit off to account for scrollbars etc).
In fullscreen mode, the Toolbars are also compressed to two rows only, from four. I've measured and this should fit on a NetBook screen and above. If you have a resolution below 1024x600, you're probably in trouble.

Note, the specific issue, that the JCE image editor requires a resolution over 600pixels high (Netbook land) can also be fixed by forcing the editor to over 100% high so it works for netbooks.
This can be done by editing the CSS (in addition to write_1512.html), or using something like Stylish on Firefox.
As this makes working with My Blog on normal screens bigger than Netbook resolution quite tedious (you have to scroll up and down to see the whole of the My Blog editor), I don't suggest enabling this by default.

Screenshot of my "super" fullscreen mode:
Image

As before, I'll supply the required files to those who ask, as they're still experimental IMHO.

V

Re: JCE Editor implemented in MyBlog

Posted: Sat Sep 12, 2009 11:12 pm
by Red Horse
Thanks for keeping us up-to-date, I'll send that direct request for the modified files.

Patrick

Re: JCE Editor implemented in MyBlog

Posted: Sun Sep 13, 2009 12:10 pm
by vijay555com
Guys,

JORD noticed a small issue related to writing blog entries from the front end, when not logged into the backend. I'd never noticed this because I never use the front end to write entries.
I've fixed this, so if anyone who's downloaded the files from me wants the minor fix, let me know.
Future updates will already have this in.

V

Showing enlarged (non fullscreen) editor, and enlarged dialog area in front end mode.
Image

Re: JCE Editor implemented in MyBlog

Posted: Mon Sep 14, 2009 6:51 am
by mikej
vijay555com,

I would like to thank you on behalf of all of us in this topic. It is GREAT seeing people like you helping out people like me. I have tried and tried, and couldn't figure it out. I would greatly appreciate the files to make this work. I tried doing what you said above just to get JCE to show, but it isn't working. So, maybe the files will :). I have sent you an e-mail at the above address.

Re: JCE Editor implemented in MyBlog

Posted: Mon Sep 14, 2009 9:23 am
by vijay555com
I've emailed the files to all who asked, I hope. Note, the fixes are only tested on Firefox. If anyone applies them to any other browser, let me know!

V

Re: JCE Editor implemented in MyBlog

Posted: Thu Sep 17, 2009 11:47 pm
by vijay555com
Guys,

For those that have had some issues with the mods to write_1512.html not "taking", please note that 1512 is only used in versions of Joomla equal to or over version 12: this decision takes place in the file
\Joomla\components\com_myblog\task\write.php

Code: Select all

			if( $build >= 12 )
			{
				$html = $tpl->fetch(MY_TEMPLATE_PATH."/admin/write_1512.html");
			}
			else
			{
				$html = $tpl->fetch(MY_TEMPLATE_PATH."/admin/write.html");
			}
So if modifying write_1512.html has no effect, than somehow you're using a version of Joomla under 12. And you shouldn't be! Upgrade now, for security (and compatibility) reasons!

However, if you're happy to take the risk, you can take my write_1512.html, rename it to write.html, and overwrite your own write.html file (taking a backup first, of course!). This should allow my mods to click in, whatever version of Joomla you're running!

I enclose the file for general use, for now. Please post feedback on how you get on, good or bad.

V

Re: JCE Editor implemented in MyBlog

Posted: Tue Sep 22, 2009 11:34 am
by vijay555com
Guys,

A couple of minor issues were pointed out, so I've re-uploaded a slightly newer version.
If it was working before, it should continue to work:
- I've "prettied" up the HTML/PHP a bit
- I've added a little version display in the top right
- The placing of the JCE loader was not optimal. It's hopefully "more" optimal now!

V

PS I've also enclosed the CSS overrides I use to improve the screen area. Use Stylish in Firefox to enable, or manually modify the MyBlog CSS files.

PPS I don't remember fixing anything, but it seems to be working ok in IE. I might just be lucky. Please test:
Note, both Image Manager and Image Manager Extended seem to be working in both Browsers.
Image

Re: JCE Editor implemented in MyBlog

Posted: Wed Sep 23, 2009 12:24 pm
by vijay555com
Guys,

I'm enclosing a marginally updated patch file.
It merely removes a reported bug in IE (and maybe Firefox) that "tinyMCE_GZ" is not found. As we're not using tinyMCE, I've "nulled" that bit of the original script.

People have reported some issues in Firefox, and IE. I've tried it successfully on IE8 and Firefox 3.5. Please report your own successes or failures, either direct to me (preferable), or on here.
Note, as I'm using it on a development site, I don't have CSS or PHP compression or caching enabled. Please try toggling these settings also.

V

Re: JCE Editor implemented in MyBlog

Posted: Thu Oct 01, 2009 8:44 am
by jasperli
Hey Guys,

Good article.... love it!!! Brings more spice to my site.
But.. does anyone of you know the css tweaks made?
I'v been trying but i think i just miss the right div

Jasper

Re: JCE Editor implemented in MyBlog

Posted: Thu Oct 01, 2009 10:29 pm
by vijay555com
@jasperli: my css tweaks, for fullscreen browser etc?
I've posted them above in one of the zips.

How you implement them depends on your browser etc - personally I use stylish on Firefox so I can switch them on and off easily, but if you want them to be permanently implemented you have to follow the instructions above and merge the mods with the original Azrul css files.

V

Re: JCE Editor implemented in MyBlog

Posted: Fri Oct 02, 2009 3:58 pm
by nmcleod
Vijay

I just wanted to thank you for providing this essential patch! It took me a long time to find a solution, but I guess perseverence pays off in the end. It's just a shame that the good folks over at Azrul.com haven't documented this or any other workable fix for this very common problem. ;)

Anyhow, thanks again!

Neil

Re: JCE Editor implemented in MyBlog

Posted: Fri Oct 02, 2009 4:07 pm
by nmcleod
Vijay

I was trying to upload a picture via the JCE WYSIWYG Editor and the bottom of the pop-up is not accessible as it stops at the base of the Editor page. Consequently, I can't get to the buttons and features at the bottom.

Could you please check this for me.

Thanks!

Neil

Re: JCE Editor implemented in MyBlog

Posted: Fri Oct 02, 2009 4:08 pm
by vijay555com
My pleasure! It's always nice to hear a nice word.
I'll look into IE 7 compatibility if and when I can for those who need it.

V

Re: JCE Editor implemented in MyBlog

Posted: Fri Nov 20, 2009 2:21 pm
by vodka22
Hi, great job .... but manager_ext have a bug when i try to save image whit pop up whit class JCEU. nothing .. in article have image but whit out class="jcepopup" .. can you fix this vijay555com ?

Re: JCE Editor implemented in MyBlog

Posted: Sat Nov 28, 2009 4:13 am
by luisdeita
Great solution! Thanks.
Any idea why I cannot upload images?

Re: JCE Editor implemented in MyBlog

Posted: Sat Dec 05, 2009 10:53 pm
by xterminal
this is what i was just looking for. thanks for everyone one this post :)

Re: JCE Editor implemented in MyBlog

Posted: Wed Jan 20, 2010 10:45 pm
by steve4820
I've just installed the latest jce package and vijay's modified write_1512 file and it seems to be working fine in My Blog. I did have one hiccup when I clicked something in the screen and everything in the text edit window went to html. I closed and reopened and it worked OK again.

Thanks to vijay for this!

I'd appreciate any further updates posted here. I'll email also.

BTW, working in Safari 4.0

Thanks again.

Re: JCE Editor implemented in MyBlog

Posted: Mon Feb 01, 2010 10:03 am
by wilson1973
Hi,

I seem to be having issues getting this to work.

I'm on J1.5.15
MyBlog 3.0.329
JCE 1.5.6

Default editor JCE.

I've overwritten the write_1512.html with the one attached to this forum (23.09.2009). I see in the Myblog 'write new entry' window Vijays reference to his mod, but the editor is still TinyMCE.

I'm not sure whether this is to do with the recent Myblog update ? but I cannot get the JCE editor to work in MyBlog, am normally OK with this sort of mod.


Any ideas?

Cheers

Re: JCE Editor implemented in MyBlog

Posted: Wed Feb 17, 2010 8:05 pm
by chrislynk
This is exactly what we've been looking for! However, I dropped the write_1512.php file into the appropriate directory, myBlog's editor now loads JCE correctly, but when I try to edit an entry that was created without JCE, it doesn't pull any of the content, it's a completely blank article.

Any ideas?

Re: JCE Editor implemented in MyBlog

Posted: Mon Mar 01, 2010 7:09 pm
by Tuliza
Great, many THANKS for this!! :-) It seems to work great for me. It can also load data created without JCE. I am using J1.5.15, JCE 1.5.7 and MyBlog 3.0.331. There are just a few advanced option like template and image caption that are missing.

Re: JCE Editor implemented in MyBlog

Posted: Sat Mar 20, 2010 11:31 pm
by jam620
Hi,

I seem to be having issues getting this to work.

I'm on J1.5.15
MyBlog 3.0.329
JCE 1.5.6

Default editor JCE.

I've overwritten the write_1512.html with the one attached to this forum (23.09.2009). I see in the Myblog 'write new entry' window Vijays reference to his mod, but the editor is still TinyMCE.

I'm not sure whether this is to do with the recent Myblog update ? but I cannot get the JCE editor to work in MyBlog, am normally OK with this sort of mod.


Any ideas?

same problem

any solution?

Re: JCE Editor implemented in MyBlog

Posted: Mon Apr 05, 2010 9:40 am
by dyominroma
Hi, i have russian JCE! How i can use russian language in your hack?

Re: JCE Editor implemented in MyBlog

Posted: Mon Jun 28, 2010 1:44 am
by luisdeita
Hello to all, I can't add tags or images. Any idea how to solve this?

Thanks in advance.