@baris Thanks! perfect 🙂
https://github.com/julianlam/nodebb-plugin-support-forum/pull/14
Unsolved How to stop the posting process in a client side script
-
I wrote a small client-side script, which checks
$('write').val()
on a regular expression, and if it contains certain words, displays a recommendation to the user to avoid them.
The script is activated by clicking on the post button of the post / topic.
The question is is it possible to stop the publication of the post along with the presentation of the recommendation (I present the recommendation via app.alert)? Let there be a recommendation, and the post not be published? I want something on the client side, not a server side extension
Thank you! -
nobody? This is very important for controlling the quality of the discourse in my forum
@baris -
Use this hook to prevent posting and displaying and alert https://github.com/NodeBB/nodebb-plugin-composer-default/blob/master/static/lib/composer.js#L677
Suggested Topics
-
Unsolved It shown "no post" on persona theme
Technical Support • • kai