There is a chance you can use the PHP event
core.posting_modify_template_vars
Sorry but that does not work. One block element, three '\n' and another block element? And another is one block element two '\n' and inline element.
You asked multiple questions about it and I patiently answered them. Now you're posting in multiple topics whining that skipping 0 newlines doesn't work for you, and skipping 1 to 2 newlines doesn't work for you and if it's not exactly 1 then you'll take your toys and go home. You went to MyBB's GitHub to complain about it too? In what world does that make sense?
ckeditor.js
from 0.1.6 and everything seems working well again. So this error can't come from PHPBB itself with deleting all lines.As I said earlier I can not do anything about this issue. Please do not insist on it.Miri4ever wrote: ↑Fri Jul 14, 2017 6:00 pm I don*t know what you changed but it worked well with 0.1.6. It could be many of the bugs inside PHPBB but all I know it worked before better and so some changes done from your code. And now it's impossible to do one empty line. It makes now none or at least 2. Thats the funny part of this story.
Ok I just notice everytime you switch between Source Code Mode and WYSIWYG Mode one empty line is removed from the editor as long until no empty line is something. Something of the new code remove one of those lines between every cycle.
I uploaded all files from 0.1.8 but theckeditor.js
from 0.1.6 and everything seems working well again. So this error can't come from PHPBB itself with deleting all lines.
<span style="display:block;">
. Code: Select all
static public function getSubscribedEvents()
{
$Default_Event = array(
'core.user_setup' => 'load_language_on_setup',
'core.display_custom_bbcodes' => 'initialize_rceditor',
'core.viewtopic_modify_page_title' => 'initialize_rceditor',
'core.viewtopic_post_rowset_data' => 'initialize_rcequickquote',
'core.text_formatter_s9e_parser_setup' => 'rce_bbcode_perm',
'core.text_formatter_s9e_configure_after' => 'rce_rmv_ignws',
'core.text_formatter_s9e_render_after' => 'rce_parse_change',
);
return $Default_Event;
}
//Remove globally skip one line before and two after blocks
public function rce_rmv_ignws($event)
{
$event['configurator']->rulesGenerator->remove('IgnoreWhitespaceAroundBlockElements');
}
//Skip one line after block element. But does not contemplate tag like <span style="display:block;">
public function rce_parse_change($event)
{
$patterns = array('/<\/blockquote><br>/', '/<\/div><br>/', '/<\/address><br>/', '/<\/article><br>/', '/<\/aside><br>/', '/<\/canvas><br>/',
'/<\/dd><br>/', '/<\/dl><br>/', '/<\/dt><br>/', '/<\/fieldset><br>/', '/<\/figcaption><br>/', '/<\/figure><br>/', '/<\/footer><br>/',
'/<\/form><br>/', '/<\/h1><br>/', '/<\/h2><br>/', '/<\/h3><br>/', '/<\/h4><br>/', '/<\/h5><br>/', '/<\/h6><br>/', '/<\/header><br>/',
'/<\/hgroup><br>/', '/<\/hr><br>/', '/<\/li><br>/', '/<\/main><br>/', '/<\/nav><br>/', '/<\/noscript><br>/', '/<\/ol><br>/', '/<\/output><br>/',
'/<\/p><br>/', '/<\/pre><br>/', '/<\/section><br>/', '/<\/table><br>/', '/<\/tfoot><br>/', '/<\/ul><br>/', '/<\/video><br>/');
$replacements = array('</blockquote>', '</div>', '</address>', '</article>', '</aside>', '</canvas>',
'</dd>', '</dl>', '</dt>', '</fieldset>', '</figcaption>', '</figure>', '</footer>',
'</form>', '</h1>', '</h2>', '</h3>', '</h4>', '</h5>', '</h6>', '</header>',
'</hgroup>', '</hr>', '</li>', '</main>', '</nav>', '</noscript>', '</ol>', '</output>',
'</p>', '</pre>', '</section>', '</table>', '</tfoot>', '</ul>', '</video>');
$event['html'] = preg_replace($patterns, $replacements, $event['html']);
}
Du darfst bestimmte BBCodes nicht verwenden: [protect].
Du darfst bestimmte BBCodes nicht verwenden: [hide].
thanks... i will fix in next version.Miri4ever wrote: ↑Sat Jul 15, 2017 2:32 pm Wonderfull work, the current Release is working like a charm now and I don't see some performance loss in any way about.
But unfortunatly I discovered 2 new bugs. One from this release maybe and don't know what happened with the second one if this is also result of this update ?
If 2 smilies follow directly after each other the spaces needed between got removed no matter how many I put inside and only the first one is display correctly. Ok I could live with this one if there is no solution arround.
Are you using cache settings? Settings of cache it store too permission settings.Miri4ever wrote: ↑Sat Jul 15, 2017 2:32 pm The second new Error seems strange:
Du darfst bestimmte BBCodes nicht verwenden: [protect].
Du darfst bestimmte BBCodes nicht verwenden: [hide].
If I post those with ADMIN ID 2 they are working. If I use another Admin and Founder Account I got this error. No matter how the permissions set inside your editor. Even if I allow for everyone some BBCodes now seems working only to Founders with ID2 and all others blocked out. Some others customs Codes seems working and some got blocked out. That is the part I not fully understand.
If I'm testing the permissions of my other ADMIN Account with my ID2 Account also everythings work with them. But if I really log out and login with any other account the error is back.
If I submit the text without any changing it works, but as soon I only change one part this BBCode would be noticed and everything stopped.
protect
bbcode now to schutz
and it's going now fine. I also did with hide
for example to hidde
and it goes trough. But the hide extension itself using hide
so I can't use the name change for this one. Are those names somewhere in this extension blocked ?All custom bbcode are handled the same way.Miri4ever wrote: ↑Sat Jul 15, 2017 3:27 pm I did some more tests but it makes me even more confused.
I changed the name of myprotect
bbcode now toschutz
and it's going now fine. I also did withhide
for example tohidde
and it goes trough. But the hide extension itself usinghide
so I can't use the name change for this one. Are those names somewhere in this extension blocked ?
Thanks for feedback!