Important Notice: Effective immediately, all support will be handled through Discord. Read more about the changes coming to Anodyne's services.

[MOD] Rich Editor in Nova

A place to show off (and others to download) completed MODs. Note: support for MODs is handled by third parties, not Anodyne Productions.

mooeypoo Fri Jun 11, 2010 11:09 pm

[MOD] Rich Editor in Nova

I've seen a few questions already from people who want to add tables and images into fields in Nova but get confused with the HTML code.

So, to make it easy on everyone, I created a little mod that adds CKEditor to some of Nova pages. I chose CKEditor instead of MarkItUp, this time, on purpose, to avoid having the users write code. With CKEditor, you get a full WYSIWYG editor, and you don't have to write an iota of code to display images or write tables.

The mod adds rich editor to the following pages:
  • Write Mission Post
  • Write Personal Log
  • Write News Item
  • Missions -> Add Mission
  • Character Bio

Download the mod here: http://bitbucket.org/mooeypoo/nova-mod- ... et/tip.zip
Instructions are here: http://bitbucket.org/mooeypoo/nova-mod- ... /wiki/Home

EDIT: In order to use this mod, you will need to disable "nl2br" (the replacement of new-lines with <br /> tags) in the pages that the richeditor works in. Beware, that this means overriding view files in the _base_override. If you changed these particular pages in your template, make sure you make the change to text_output() there as well.

Hope you enjoy it,

~mooey
Find my Nova MODs: https://github.com/mooeypoo
User avatar

Posts: 247


wisper Fri Jul 16, 2010 5:10 pm

Re: [MOD] Rich Editor in Nova

The only places I can see the RTE is on the Write Mission Post, Write News Item, Write Personnel Log. The Bio page just continuous loads. The other pages I am not even sure which ones they are.
User avatar

Posts: 233


mooeypoo Sat Jul 17, 2010 8:32 pm

Re: [MOD] Rich Editor in Nova

wisper wrote:The only places I can see the RTE is on the Write Mission Post, Write News Item, Write Personnel Log. The Bio page just continuous loads. The other pages I am not even sure which ones they are.

The bio page takes a bit longer to load because all the textareas are replaced by the RTE, but it shouldn't take such a significant amount of time to reload.

It's not working for you at all, or is it taking more time? can you tell me which version of Nova you're using this with?
Find my Nova MODs: https://github.com/mooeypoo
User avatar

Posts: 247


wisper Sun Jul 18, 2010 1:19 am

Re: [MOD] Rich Editor in Nova

I am using Nova 1.0.6

Well after five minutes of waiting for the page to load I gave up. I see the loading bar and the Edit Bio across the top though.
User avatar

Posts: 233


mooeypoo Sun Jul 18, 2010 1:32 am

Re: [MOD] Rich Editor in Nova

wisper wrote:I am using Nova 1.0.6

Well after five minutes of waiting for the page to load I gave up. I see the loading bar and the Edit Bio across the top though.

And it works in all the other pages? In the write?

I must say I'm stumped. It works great for me and in 4 other sites I've checked. The only recommendation I can make is to get rid of the RTE in the bio page only.
To do that, go to the file: application/views/_base_override/admin/js/character_bio_js.php and change this line:

Code: Select all
$('textarea').ckeditor(config);

to this:
Code: Select all
/*$('textarea').ckeditor(config);*/


As in - comment out the command telling all textareas to become RTEs. At least you can enjoy the RTE in the log editor.

~moo
Find my Nova MODs: https://github.com/mooeypoo
User avatar

Posts: 247


William Mon Jul 19, 2010 8:03 am

Re: [MOD] Rich Editor in Nova

A part of the update in 1.0.6 was to introduce loading animations while the Bio Page loads. This could be interfering with the loading of the RTE in the bio pages. Mabee looking at the placement of the code and where it beging / ends its loading process is needed.

Or

If the loading part is not in your RTE code which was introduced to improve loading, you could put it into the RTE JS files and see if it helps.
SIMMPLICITY.ORG - NEW SITE COMMING SOON

Posts: 52


Stormwolfe Thu Jul 28, 2011 8:21 am

Re: [MOD] Rich Editor in Nova Compatibility Question ??

I would like to add this mod to my site as it will make life easier on my Users that are forum spoiled. I am undecided on adding it to the Bio Form as our forms tend to be very long and complicated. For Mission Posts, Personal Logs, etc., it would be a gem!

However, I need to know if it will work with the Nova 1.2.6 update.

Kindest Regards,

Jericho
User avatar

Posts: 467


mooeypoo Thu Jul 28, 2011 8:33 am

Re: [MOD] Rich Editor in Nova Compatibility Question ??

Jericho wrote:I would like to add this mod to my site as it will make life easier on my Users that are forum spoiled. I am undecided on adding it to the Bio Form as our forms tend to be very long and complicated. For Mission Posts, Personal Logs, etc., it would be a gem!

However, I need to know if it will work with the Nova 1.2.6 update.

Kindest Regards,

Jericho


I am using the mod without problems, and theoretically there SHOULDN'T be any problems, but I can't promise that, since I didn't test it as a standalone mod on that update yet.

Basically, the entire code is a few lines in a javascript page. Removing it is not a problem, you just delete the line - so just make sure you make a backup of the original files, and things should be okay.

However, for the moment, I can't promise. I am in an internship away from my main computer, and can't do much testing at the moment.

I will do the tests the moment I get back home, but that is in about a month...

~mooey
Find my Nova MODs: https://github.com/mooeypoo
User avatar

Posts: 247


Stormwolfe Thu Jul 28, 2011 8:37 am

Re: [MOD] Rich Editor in Nova

Mooeypoo,

Thank you for the response! I might test it out on the slower/less active game and see how it works.

I appreciate the information!

Best Regards,

~ Jer
User avatar

Posts: 467


evshell18 Sat Jan 07, 2012 1:34 pm

Re: [MOD] Rich Editor in Nova

Mooeypoo,

Thanks for this mod!

I just wanted to let you know that I also had the problem with the Bio page. Commenting out the line as you suggested didn't work. That says to me that it is not just an issue with rendering the controls, but with something in the actual page code. I had to rename the page to get rid of the issue so that it would again use the original Nova code.

Secondly, you say to disable "nl2br" on each of the pages. How exactly is that done?

Thanks!

Posts: 16



Return to Nova MODs

Who is online

Users browsing this forum: Bing [Bot] and 1 guest