Hi Wilson,
Wilson Leão Neto wrote:
Hello Vincent,
We are having problems trying to import .doc documents. We are getting this:
"content: Exception while parsing HTML"
A stack trace would be very useful.
Our version: XWiki Enterprise 2.2.5.28407
Also, we would like to be able to customize the wysiwyg editor. I've read
the:
http://platform.xwiki.org/xwiki/bin/view/AdminGuide/WysiwygEditor
And I'm striving to create a button that would add a pagebreak into the
code. That would allow the pdf export to properly generate the document.
Velocity code:
{{velocity
filter="none"}}
{{html clean="false" wiki="true"}}
#pagebreak()
{{/velocity}}
You should start by creating a pagebreak wiki macro
http://platform.xwiki.org/xwiki/bin/view/DevGuide/WikiMacroTutorial so
that your users can insert a page break through the Insert Macro wizard.
Next, if you want to insert the pagebreak macro with one single click,
using a tool bar button, you have two options:
(1) Use the Command Manager API exposed in JavaScript (
http://code.xwiki.org/xwiki/bin/view/Modules/WysiwygEditorModule#HCommandMa…
) to insert the pagebreak macro:
editor.getCommandManager().execute('macroInsert',
'startmacro:pagebreak|-|')
Currently we don't save a reference to the WYSIWYG editor used to edit
wiki pages but you can observe the xwiki:wysiwyg:created event with
prototype and get the editor instance from the 'instance' property of
the event (I don't know prototype that well, others may help you here).
To place a button on the tool bar from outside of the WYSIWYG editor
code you can take a look at what the full screen editing feature does.
(2) It may be easier and cleaner to write a small plugin for the WYSIWYG
editor. You can take
http://svn.xwiki.org/svnroot/xwiki/platform/web/trunk/xwiki-gwt-wysiwyg-cli…
as an example. For this you'll have to checkout the WYSIWYG editor
source code ( mainly
http://svn.xwiki.org/svnroot/xwiki/platform/web/trunk/xwiki-gwt-wysiwyg-cli…
and
http://svn.xwiki.org/svnroot/xwiki/platform/web/trunk/xwiki-gwt-wysiwyg-ser…
), write the plugin in Java, rebuild the editor and update your XWiki
installation.
Hope this helps,
Marius
It may seems like I'm "POGging" around... If you know a better way to do
it,
please, tell me. ;)
Thank you! You're being very helpful!
Wilson
2010/5/4 Vincent Massol <vincent(a)massol.net>
Hi,
On May 4, 2010, at 8:15 PM, Wilson Leão Neto wrote:
Hello all!
Is it possible to completely replace the xwiki wysiwyg editor? For
instance,
use the
http://ckeditor.com/demo. If so, how
should I procede? Will the
work
be almost impossible?
Nothing is
impossible but you'd loose a lot of features.
Why would you be interested in doing this?
Thanks
-Vincent
_______________________________________________
users mailing list
users(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/users
_______________________________________________
users mailing list
users(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/users