1 (edited by rs324 2010-09-05 14:03)

Topic: [Extension release] PunBB WYSIWYG - using TinyMCE

New Version 1.0.3
------------------------------

full info :

http://punbb.informer.com/forums/post/137505/#p137505

----------------------------------------------------------------------------------------------------------------------------------------
----------------------------------------------------------------------------------------------------------------------------------------
New Version is out : V 0.2

http://rs324.s3.amazonaws.com/PunBB/punbb_wysiwyg0.2.jpg

check it out :

http://punbb.informer.com/forums/post/137371/#p137371

--------------------------------
Hey all ,

i made a quick hook for getting wysiwyg editor to PunBB using TinyMCE 3.3.8

(i used TinyMCE Jquery plugin)

tested on PunBB 1.3.4
download link - its the old version - you dont need that

to control textarea css just edit : forums_root/extensions/punbb_wysiwyg/editor.css

you can edit editor style according to tinyMCE api (skin or what ever you want)
also , you can use TinyMCE multi-lang support from their site.

at next version i will add few more options like simles support , etc.
enjoy  big_smile

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

any demo exp please

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

@Gujjerji110: Here's what the demo looks like by default...

http://keydogbb.info/img/tiny.png

@rs324: Nice extension!
Q: Those options above appearing on the right can be controlled by the css right? Also the code, color, list - how would you add those?

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

thanks for demo brother

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

yesss! i will try it.... very nice!

6

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

KeyDog wrote:

@Gujjerji110: Here's what the demo looks like by default...

http://keydogbb.info/img/tiny.png

@rs324: Nice extension!
Q: Those options above appearing on the right can be controlled by the css right? Also the code, color, list - how would you add those?

hey , im sorry becouse im using rtl so i place the icons on the right

to change them to left just edit manfiest.xml  line 43

find

theme_advanced_toolbar_align : "right",

replace with

theme_advanced_toolbar_align : "left",

or if you want them in center , replace with

theme_advanced_toolbar_align : "center",

also you can change the skin of the editor
to so go to line 31 or line 32 and remove the comment

skins info are from here : http://tinymce.moxiecode.com/examples/skins.php


about code , color , list & simlies ,
actually i havent used them yet (im using punbb only for 2 days) i guss i will add them to the next version.

im glad you like this extntion (i made it only becouse i hate to write  & use bbcode - reminds me year 2000)

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

Thanks for those infos smile
============================
Just noticed I run into trouble as soon as I use a lot of the other options
http://keydogbb.info/img/tiny2.png

If I insert emotions into manifest and then use the smilies I get code in post instead of actual smilies, like this:

[img]extensions/punbb_wysiwyg/tiny_mce/plugins/emotions/img/smiley-innocent.gif[/img]

If I use background color I get

<span style="background-color: #ffcc00;">This is a test</span>

When I try lists with bullets I just get

<ul><li>

etc....  and for numbered list I get

<ol><li>

etc


Guess one would have to add support to all those others via parser.php....?

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

KeyDog wrote:

Just noticed I run into trouble as soon as I use a lot of the other options
http://keydogbb.info/img/tiny2.png

If I insert emotions into manifest and then use the smilies I get code in post instead of actual smilies, like this:

[img]extensions/punbb_wysiwyg/tiny_mce/plugins/emotions/img/smiley-innocent.gif[/img]

If I use background color I get

<span style="background-color: #ffcc00;">This is a test</span>

When I try lists with bullets I just get

<ul><li>

etc....  and for numbered list I get

<ol><li>

etc


Guess one would have to add support to all those others via parser.php....?

wow that is so coll i will wait for this brother
it really amg
so will you complate brother ??

9

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

KeyDog wrote:

Thanks for those infos smile
============================
Just noticed I run into trouble as soon as I use a lot of the other options
http://keydogbb.info/img/tiny2.png

If I insert emotions into manifest and then use the smilies I get code in post instead of actual smilies, like this:

[img]extensions/punbb_wysiwyg/tiny_mce/plugins/emotions/img/smiley-innocent.gif[/img]

If I use background color I get

<span style="background-color: #ffcc00;">This is a test</span>

When I try lists with bullets I just get

<ul><li>

etc....  and for numbered list I get

<ol><li>

etc


Guess one would have to add support to all those others via parser.php....?

hmm i didnt added all of tinymce functions becouse you need to write a special code for it ,
the idea is to write a code that works on tinymce because when you edit a document you need tinymce to understand the formating , so what i need to do is to write a special function for each of forum's bbcode options ,
i will use the parser to add some more function like [rtl][/rtl] [ltr][ltr][center] [right] [left] and stuff like that , also for the smilies , i need to check the checkbox of use smilies at edit mode before showing them on screen

the important idea is the basic function will work for the first version

btw ,
do you know how can i disable the caching of the hook ? (each edit of file i need to uninstall & reinstall the plugin) ?

thanks.

10

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

hello,
seems it is going to be a great extension

however, I got few issues:

  • Can you kindly make RTL and LTR configurable? Because, if we edit manifest.xml, it will loose the portability from future releases of your extension!
    if all the tinymce functions can't be implemented, then why to use it? isn't it better to use some other lightweight wysiwyg editor?

i think this is an extension that may need community attention! so after some progress, if you release it and maintain actively, we will also be able to contribute!

11

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

rs324 wrote:

the important idea is the basic function will work for the first version

Yes it's a nice first release big_smile

rajuru wrote:

i think this is an extension that may need community attention!

Yes and/or a PunBB developer to tell us how best to make it compatible....

rajuru wrote:

Can you kindly make RTL and LTR configurable?

He can also very simply just change that line (43) / or someone else can - and release the identical extension - it's not necessary to add that to admin settings necessarily...

12 (edited by rs324 2010-08-31 12:08)

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

rajuru wrote:

hello,
seems it is going to be a great extension

however, I got few issues:

  • Can you kindly make RTL and LTR configurable? Because, if we edit manifest.xml, it will loose the portability from future releases of your extension!
    if all the tinymce functions can't be implemented, then why to use it? isn't it better to use some other lightweight wysiwyg editor?

i think this is an extension that may need community attention! so after some progress, if you release it and maintain actively, we will also be able to contribute!

about your first point , im using the rtl version of this extntion , so there is not problem using it as rtl , to change 1 line of code is not such truble for the first version of this extention

usally its , rtl OR ltr and you will change this option only once , when you installing the extention,

any way when i will get punbb little better ill make an admin section to edit direction , buttons , theme of tinymce

if all the tinymce functions can't be implemented, then why to use it? isn't it better to use some other lightweight wysiwyg editor?

if your not loading all of plugins tinymce is very lightweight and came with out of box bbcode support , also its have great docs, so its easy to builld new extentions to it, and make it punbb function suppot , i need to builld custom js function for tinyMce

you have other extentions that not using tinymce , if you don't like tinymce you can try them (for example UBB Editor)

-------------------

at the moment next stable release will include :
smilies support ,
code block support ,
lists support,
justify support



after that
few more features , and admin config zone

13

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

New Version : 0.2
--------------------------------------
http://rs324.s3.amazonaws.com/PunBB/punbb_wysiwyg0.2.jpg

what has been changed ?
-----------------------------------

added support for left , right, center , justfiy text-aligns
added support for inlinde rtl & ltr text direction
added support for font color & background color
added support for orderd & unordered lists
Smilies  smile  smile

added 2 Options for smiles , as drop down button or as inline (at wysiwyg UI)

custom php functions for parsing bbcode.

fixed few bugs :

tinymce now loaded only on page with editor (last version loaded on every page)
all scripts are now on external file : scripts.js instead of inline writing.


to change plugin settings , just go to scripts.js and you can change skin or direction (ltr,rtl)  , or buttons appreance order
you can use multi-lang throw tinymce translation page



i have worked very hard on writing the tinymce JS plugins for custom bbcode  and to make it work right
i hope you will enjoy it.

download here

14

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

Thanks a lot, just tried and even though directionality is set ltr the cursor always appears on right hand side... but great job on getting all those functions to work!

15

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

KeyDog wrote:

Thanks a lot, just tried and even though directionality is set ltr the cursor always appears on right hand side... but great job on getting all those functions to work!

thats because editor.css file is set to rtl

if you want you can edit this file and setup what ever you want.

any way  i updated the file so you can re download.

16

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

Thanks.
Just noticed small thing, you zipped and named the file so that when it's unpacked one needs to rename it otherwise there's mismatch between extension name and folder name
btw also added version number 1.0.2 instead of just 0.2 ...
uploaded it here:
http://punbb.informer.com/wiki/_media/p … _1_0_2.zip

17

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

KeyDog wrote:

Thanks.
Just noticed small thing, you zipped and named the file so that when it's unpacked one needs to rename it otherwise there's mismatch between extension name and folder name
btw also added version number 1.0.2 instead of just 0.2 ...
uploaded it here:
http://punbb.informer.com/wiki/_media/p … _1_0_2.zip

i didnt wanted ppl think its version 0.1 so i just renamed the rar file
so i will edit the version number and upload it again
hmm

you put the extention at wiki pages , so its mean i can remove it from my server ?
btw , did you found any bugs ?
will you use it ?

18

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

It's good if you keep it for download on your server aswell. I just upload to wiki for backup.
Numbering is just detail. Also it's good if you always keep the download link the same; so
http://rs324.s3.amazonaws.com/PunBB/punbb_wysiwyg.rar  instead of
http://rs324.s3.amazonaws.com/PunBB/pun … wyg0.2.rar
but that's up to you - maybe you want one light version and one full

Only thing I noticed "bug" wise, is that
- on left side there's a border
- it doesn't warn to turn off pun_bbcode (so one has both showing smile ) - but that's not a real bug
- and the smilies are there twice (indirectly via dropdown, then on second line all)

All functions are working as wanted for me in chrome - so I'm happy...

Also many other users have been wanting something like this, so your work is appreciated greatly

19

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

KeyDog wrote:

It's good if you keep it for download on your server aswell. I just upload to wiki for backup.
Numbering is just detail. Also it's good if you always keep the download link the same; so
http://rs324.s3.amazonaws.com/PunBB/punbb_wysiwyg.rar  instead of
http://rs324.s3.amazonaws.com/PunBB/pun … wyg0.2.rar
but that's up to you - maybe you want one light version and one full

Only thing I noticed "bug" wise, is that
- on left side there's a border
- it doesn't warn to turn off pun_bbcode (so one has both showing smile ) - but that's not a real bug
- and the smilies are there twice (indirectly via dropdown, then on second line all)

All functions are working as wanted for me in chrome - so I'm happy...

Also many other users have been wanting something like this, so your work is appreciated greatly

i will fix the downlod link smile

about the double of icons i puted them both so users will notice that there are 2 options

to remove the second line you just need to edit scripts.js
and set
theme_advanced_buttons2 : ""

if you want to remove the drop down button ,
find : ,rs324smilies at theme_advanced_buttons1
and remove it.

i like the wyiwyg extention (reminds the vbulletin wysiwyg)
make the textarea looks much better

about the warning , i have no-idea how to do that.

20

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

Big th'z for this ext!!!

21

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

after install not worked pun_quote, insert_nick_to_quickpost...

22

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

kmbxxx wrote:

after install not worked pun_quote, insert_nick_to_quickpost...

i guss this hacks uses javascript to update the textarea can you give me links to this extntions ? i will update mine to support them.

23

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

rs324, pun_quote v2.2.2 is official extensions -> http://punbb.informer.com/extensions/ insert_nick_to_quickpost
hook
vt_row_pre_post_ident_merge
code

if ($forum_config['o_quickpost'] == '1' &&
    !$forum_user['is_guest'] &&
    ($cur_topic['post_replies'] == '1' || ($cur_topic['post_replies'] == '' && $forum_user['g_post_replies'] == '1')) &&
    ($cur_topic['closed'] == '0' || $forum_page['is_admmod'])) $forum_page['post_ident']['byline'] = str_replace('</span><a title=', '</span><a onclick="return insert_text(\'\', \'[b]'.forum_htmlencode($cur_post['username']).'[/b], \')" href="#req_message"> → </a><a title=', $forum_page['post_ident']['byline']);

24

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

+
official extensions pun_tags v1.5 -> http://punbb.informer.com/extensions/
+
Moderator extension
Edit post:
http://img821.imageshack.us/img821/7945/53876597.jpg

25

Re: [Extension release] PunBB WYSIWYG - using TinyMCE

btw @ rs324; added the info to the official tinyMCE forum board (which runs PunBB 1.2 big_smile )
http://tinymce.moxiecode.com/punbb/view … hp?id=1323