Page 1 of 1

Adding Wysiwyg editor on a custom form

Posted: Tue Apr 09, 2019 2:43 pm
by skouf
Hello

I had to develop a new functionality on my phpbb forum.

I have a form with some fields, + a textfield.
I need this textfield to be like the wysiwyf editor of phpbb (when you post a new topic for example).

Actually, the textfield do not save any line breaks.

Looking at posting_editor.html of the prosilver template do not helps me a lot.

Any quick help regarding that ?

Re: Adding Wysiwyg editor on a custom form

Posted: Tue Apr 09, 2019 3:02 pm
by david63
skouf wrote:
Tue Apr 09, 2019 2:43 pm
I need this textfield to be like the wysiwyf editor of phpbb (when you post a new topic for example).
phpBB does not have a WYSIWYG editor so you will need to explain exactly what it is that you are trying to do.

Re: Adding Wysiwyg editor on a custom form

Posted: Tue Apr 09, 2019 3:20 pm
by skouf
Hello

I just need to have a textarea with break lines. Actually, when I type some text and hit the Return key on my keyboard and save, I see all in only one line.
Line breaks do not exists anymore.

It would be nice to have some buttons for Bold or Italic, but that is not the most important.

Thanks !

Re: Adding Wysiwyg editor on a custom form

Posted: Tue Apr 09, 2019 3:55 pm
by mrgoldy
Is this even regarding extension developing?
And line breaks are rendered in phpBB, by the textformatter.
And a double line break closes the previous paragraph (<p>) and opens a new one.
If you want additional spacing, just add a custom BBCode that will do just that?

Re: Adding Wysiwyg editor on a custom form

Posted: Tue Apr 09, 2019 4:00 pm
by skouf
Mr Goldy I am sorry I didn't know in which topic I had to post this.
If that's not the good one maybe moderators can move it :)

My issue is a development problem. So I thought that was the right place to post :)

I will take a look at your solutions.

Thanks