[jifty-devel] a wiki toolbar

Yves AGOSTINI agostini at univ-metz.fr
Thu Apr 26 16:56:50 EDT 2007

I'm making a toolbar to help in writing textarea fields (see attached image)

I use a fragment to write the toolbar : 

<div id='toolbar' style='float:right;border:1px solid #ccc;'>
<script type='text/javascript'>
addButton('/static/img/js/h2.png','Heading 2','','\n-------\n','Heading 2');
addButton('/static/img/js/h3.png','Heading 3','### ',' ###\n','Heading 3');

# image, help text, first tag before selected text, last tag, default text

I attached my app.js
most of the code come from wikibit.js (wikipedia)

good points is that is easy to change the toolbar to add button, translate text, change tags, ...

but it's not usable in a jifty page region (javascript is cut off),

more over I don't make test with IE and there's strange behaviour with many textarea by page.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: toolbar.jpg
Type: image/jpeg
Size: 8288 bytes
Desc: not available
Url : http://lists.bestpractical.com/pipermail/jifty-devel/attachments/20070426/8b43b7ab/toolbar.jpg
-------------- next part --------------
A non-text attachment was scrubbed...
Name: app.js
Type: application/javascript
Size: 4823 bytes
Desc: not available
Url : http://lists.bestpractical.com/pipermail/jifty-devel/attachments/20070426/8b43b7ab/app.bin

More information about the jifty-devel mailing list