Page 1 of 1

configure wysiwyg editor functions per user

Posted: Fri Sep 21, 2007 4:31 pm
by prost
I can't figure out how to configure the wysiwyg editor (TinyMCE) differently per user (or group). Is this not possible?

If not, is this possible with another editor? (I guess not, but if so, I'd be happy to switch -- I'm not married to TinyMCE :))

The problem is that I'm dealing with users who need a very simple wysiwyg editor (like most humans, they're confused by options they don't need), but some others who do need more functionality.

Re: configure wysiwyg editor functions per user

Posted: Fri Sep 21, 2007 5:06 pm
by alby
prost wrote: I can't figure out how to configure the wysiwyg editor (TinyMCE) differently per user (or group). Is this not possible?

If not, is this possible with another editor? (I guess not, but if so, I'd be happy to switch -- I'm not married to TinyMCE :))
No, you cannot to have different settings but different editors.
You can setting different editor (TinyMCE Basic, FCKEditor, TinyMCE Advanced) but attention because user can change own editor (User Preferences)

Alby

Re: configure wysiwyg editor functions per user

Posted: Tue Mar 04, 2008 10:33 pm
by anivision
Hello, as I have a similar problem as Prost here above, I thought I could reuse this thread a little...

I understood by Albys answer it's possible to have different editors to different users but they can change it back for themself in the "user preferences" area.n There is no way to block this area for a certain group then?

I don't mind if I have to change in the php scripts, but this could be a huge improvement for me.

Re: configure wysiwyg editor functions per user

Posted: Tue Mar 04, 2008 11:27 pm
by anivision
I found out that this is the code inside admin/editprefs.php to change the wysiwyg editor:

:



modules as $key=>$value)
{
if ($gCms->modules[$key]['installed'] == true &&
$gCms->modules[$key]['active'] == true &&
$gCms->modules[$key]['object']->IsWYSIWYG())
{
echo ''.$key.'';
}
}
?>

Maybe its possible to set an "if" term to hide the selection of the editor for a certain group and also set the wysiwyg variable fixed to TinyMCE.

Like:
if group=editor {set wysiwyg=tinymce} else (all the code above)

Is there anyone who knows the needed variables?
Or any other way to acheive the same thing?


Ideés are much appreciated

Re: configure wysiwyg editor functions per user

Posted: Tue Mar 04, 2008 11:42 pm
by calguy1000
it can all be done given time.

All you need to do is: 
  Learn PHP
  Learn the CMS database structure
  Learn the CMS API's
  Edit the user preferences code
  Modify all of the module code and the apis to adjust the wysiwyg call on a per-user basis
 
it should be pretty simple.

Re: configure wysiwyg editor functions per user

Posted: Wed Mar 05, 2008 12:31 am
by anivision
Why do you think I'm asking here, pretty much not becouse I have the time to learn everything about this script.

If you don't have any suggestion, why post a reply? I meen, that replay can fit in to every asked question here right, so why should people bother to ask things here?

Re: configure wysiwyg editor functions per user

Posted: Wed Mar 05, 2008 8:44 am
by anivision
Ok, I found a solution for my problem and I thought I should share this. It's an ugly one but it works.

I installed FCKeditor and removed almost every tool from the toolbar except for the most basic things. Then I logged in as the user I want to restrict the edit abilities for and changed to FCKeditor in his "user preferences". After this I removed the lines in admin/editprefs.php that makes you change the wysiwyg editor.

Now the user is locked to use FCKeditor with the choices of tools I give him.
This was done without knowing PHP, CMS database structure, the CMS API's or the user preferences codes.