Log message #4158346

# At Username Text
# Jul 12th 2018, 13:37 josbeir don't get me wrong, still use it from time to time, but try to do it whitout in a new project, you'll see the benefits
# Jul 12th 2018, 13:36 josbeir and 100kb less :P
# Jul 12th 2018, 13:36 josbeir verbosity is not always a bad thing.
# Jul 12th 2018, 13:36 josbeir just a simple utility lib with some dom manipulation wrappers is good enough
# Jul 12th 2018, 13:36 admad `$('form')` is lot less to type than `document.querySelector('form')` and I am lazy :slightly_smiling_face:
# Jul 12th 2018, 13:36 josbeir its true but now ppl should unlearn jquery...
# Jul 12th 2018, 13:35 itmpls and yeah, they should learn JS
# Jul 12th 2018, 13:35 itmpls but anyway we can't change history
# Jul 12th 2018, 13:35 itmpls the problem is, browsers should've just been more consistent in the beginning otherwise there'd be no jquery
# Jul 12th 2018, 13:34 admad @rogerpro it's an abomination
# Jul 12th 2018, 13:34 josbeir its just lame that, easpecially new developers think that jquery is a language, some havent even heard of javascript, and jquery is still poluting the overall javascript community on the web imo
# Jul 12th 2018, 13:34 rogerpro white chocolate is not chocolate
# Jul 12th 2018, 13:32 josbeir too much metaphors !
# Jul 12th 2018, 13:32 admad chocolate isn't bad, the sugar mixed with it is
# Jul 12th 2018, 13:30 josbeir thats a good reply, hould have tought about that damn @steinkel
# Jul 12th 2018, 13:28 steinkel so true, specially talking about js
# Jul 12th 2018, 13:28 josbeir i got nothing ...
# Jul 12th 2018, 13:28 flavius well, everything in excess is bad for your health :P
# Jul 12th 2018, 13:28 itmpls dark can be good :slightly_smiling_face:
# Jul 12th 2018, 13:28 josbeir chocolate is bad for your health
# Jul 12th 2018, 13:27 flavius i like chocolate better :P
# Jul 12th 2018, 13:25 josbeir its the same thing than @flavius one but in vanilla js
# Jul 12th 2018, 13:24 josbeir File uploaded https://cakesf.slack.com/files/UAG1HNWKT/FBP67L8VA/-.js / https://slack-files.com/T053DPNCM-FBP67L8VA-7f570b35c0
# Jul 12th 2018, 13:24 josbeir did something similar yesterday..
# Jul 12th 2018, 13:24 rogerpro thank you all :slightly_smiling_face:
# Jul 12th 2018, 13:21 flavius ``` // disable backend submit buttons to avoid duplicates $('form').submit(function() { var b = $('[type=submit]', this); b.attr('disabled', 'disabled'); b.html('Vă rugăm așteptați...'); }); ```
# Jul 12th 2018, 13:20 admad google gave me this https://github.com/solarmosaic/jquery-prevent-double-submit
# Jul 12th 2018, 13:20 dereuromark I just tested the posted JS script, and for me it works perfectly :slightly_smiling_face: Gonna use it now. thx!
# Jul 12th 2018, 13:20 flavius had the same problem, resolved with some simple js :slightly_smiling_face:
# Jul 12th 2018, 13:20 dereuromark As for dup rows: where are your table db constraints and cake validation? That shouldnt happen but error out beforehand.
# Jul 12th 2018, 13:19 dereuromark rogerpro: Sec. component, yeah. But with some JS additions it seems to be fine to use in newer cake versions.
# Jul 12th 2018, 13:10 admad nothing needs to be done in PHP code
# Jul 12th 2018, 13:10 admad so add your JS to disable the button
# Jul 12th 2018, 13:09 rogerpro mmm @admad most customers don’t like duplicated rows in their databases :slightly_smiling_face:
# Jul 12th 2018, 13:08 rogerpro @dereuromark what do you mean in “That’s why I usually don’t use it much.” SecurityComponent? JS? https://github.com/cakephp/cakephp/issues/12347#issuecomment-404487006
# Jul 12th 2018, 13:08 admad i don't do anything :slightly_smiling_face:
# Jul 12th 2018, 13:07 rogerpro @admad about https://github.com/cakephp/cakephp/issues/12347#issuecomment-404505212 you mean that you manage a duplicator detector in your apps?
# Jul 12th 2018, 13:02 admad sorry the last wicket wasnt to part timer, i misread
# Jul 12th 2018, 13:00 admad @josbeir hehe
# Jul 12th 2018, 13:00 admad And new they gift a wicket even to a part time spinner :P
# Jul 12th 2018, 13:00 josbeir :)