Recent Activity
Recent Heroes of the BenNadel.com Community
-
Posted 173 comments since October 23, 2012
-
Posted 7 comments since March 3, 2009
-
Posted 6 comments since September 22, 2020
-
Posted 2 comments since March 12, 2023
-
Posted 11 comments since November 3, 2010
-
Posted 4 comments since February 24, 2012
-
Posted 1 comment since February 24, 2023
-
Posted 1 comment since February 24, 2023
-
Posted 1 comment since March 3, 2023
Recent Comments
Ben Nadel replied to a post Using "return" To Short-Circuit A CFML Template In ColdFusion
Comment posted March 19, 2023
@Angeli, Yeah, that language is definitely confusing. If the request only had a single CFML template to execute, then I guess you could say calling exit inside that template would be the same as calling abort. But, most request process more than one template, and now-a-days, also have an Application... read entire comment from Ben Nadel.
Angeli Wahlstedt replied to a post Using "return" To Short-Circuit A CFML Template In ColdFusion
Comment posted March 18, 2023
I'd been using cfexit method='exittemplate' cuz I was under the impression that cfexit without any atributes functions the same as cfabort. As a matter of fact, the docs at Adobe for cfexit says, "If this tag is encountered outside the context of a custom tag, for example in the base page or an incl... read entire comment from Angeli Wahlstedt.
Ben Nadel replied to a post Using "return" To Short-Circuit A CFML Template In ColdFusion
Comment posted March 15, 2023
@Angeli, Yeah, definitely a tough call 😳 That said, I believe the default method is exitTemplate; so, you should just be able to omit the attribute and just have exit in most cases (unless your using Custom tags).... read entire comment from Ben Nadel.
Angeli Wahlstedt replied to a post Using "return" To Short-Circuit A CFML Template In ColdFusion
Comment posted March 15, 2023
Very cool and certainly shower to type than cfexit method='exittemplate' :-) But I wonder if it is kosher enough to use in production code? I looked quickly at Adobe's online docs but didn't find anything.... read entire comment from Angeli Wahlstedt.
Ben Nadel replied to a post I've Never Had A Good Story For View-Rendering Helpers In ColdFusion
Comment posted March 15, 2023
@Chris, I've totally done that (reducing a complex condition into a variable, and then using that variable for the dynamic attribute). In fact, I just did that the other day. Clearly great minds think alike! 😉 Re: React functions, my classAttr() method here is more-or-less a direct rip-off of the c... read entire comment from Ben Nadel.
Chris G replied to a post I've Never Had A Good Story For View-Rendering Helpers In ColdFusion
Comment posted March 15, 2023
This would clean up the view code nicely. My colleagues tend to do messy things like wrap verbose CFIF tags around selected, checked, and disabled conditions...which looks really scary within the HTML tag. I thought I was doing better by relocating this logic above as in... <cfset disabledClause = u... read entire comment from Chris G.
Ben Nadel replied to a post Collecting HTML Class Name Attributes In Template Rendering In Lucee CFML 5.3.7.47
Comment posted March 15, 2023
I took this concept for another spin, wondering if I could make a "View helper" ColdFusion component: https://www.bennadel.com/blog/4428-ive-never-had-a-good-story-for-view-rendering-helpers-in-coldfusion.htm... read entire comment from Ben Nadel.
Ben Nadel replied to a post Using "continue" To Short-Circuit .each() Iteration In ColdFusion
Comment posted March 13, 2023
On a somewhat related note, I just accidentally discovered that you can use return to short-circuit a CFML template: https://www.bennadel.com/blog/4425-using-return-to-short-circuit-a-cfml-template-in-coldfusion.htm Normally, I would use exit to halt execution of a CFML template. I wonder if these a... read entire comment from Ben Nadel.
Ivan R replied to a post Managing Lists Of IDs Using HTML FORM Posts In Lucee CFML 5.3.7.47
Comment posted March 12, 2023
@Ben, Yes, the analogy with list functions is perfect. It means this behavior of ColdFusion is not odd but rather consistent. But it can cause issues. For example when submitting multiple hidden inputs representing some optional property or nullable db field.... read entire comment from Ivan R.
Ben Nadel replied to a post Managing Lists Of IDs Using HTML FORM Posts In Lucee CFML 5.3.7.47
Comment posted March 12, 2023
@Ivan, That's a great point. ColdFusion tends to not view empty list items as existing. Even the List* items will skip over empty items (unless told explicitly to include them). That said, I envision this technique, about managing IDs, as being something that happens more behind the scenes. Meaning,... read entire comment from Ben Nadel.
Ivan R replied to a post Managing Lists Of IDs Using HTML FORM Posts In Lucee CFML 5.3.7.47
Comment posted March 12, 2023
It should be noted, that any input with an empty string value, will simply NOT be included in the resulting list or array in the FORM scope. For example inputs with values 1, '' , 3 will submit as '1,3' or [1,3]. This is quite odd and might be unexpected to some. Ray Camden wrote about this and reco... read entire comment from Ivan R.
Ben Nadel replied to a post Exploring Turbo Drive Back-Button Caching Behavior In Lucee CFML
Comment posted March 7, 2023
Just a heads-up (and a note to self), as of the Hotwire v7.3.0 release, the [data-turbo-cache=false] attribute to prevent caching of targeted elements is being deprecated in favor of a new attribute, [data-turbo-temporary]. This is meant to mirror the [data-turbo-permanent] attribute more semantical... read entire comment from Ben Nadel.
Chris G replied to a post The User Experience (UX) Of Disabled Form Buttons
Comment posted March 3, 2023
@Ben, Bwahahahaha!... read entire comment from Chris G.
Ben Nadel replied to a post The User Experience (UX) Of Disabled Form Buttons
Comment posted March 3, 2023
@Chris, It's nice to know how the sausage is made 😉 Gives us super powers!... read entire comment from Ben Nadel.
Chris G replied to a post The User Experience (UX) Of Disabled Form Buttons
Comment posted March 3, 2023
@K Client side validation is great UX. I'm in total agreement with you there as well. The situation we desperately want to avoid is having a form filled out with valid values...yet no way to submit it because the submit button is still disabled. 😭 Ben described one situation which may cause this sc... read entire comment from Chris G.
Ben Nadel replied to a post The User Experience (UX) Of Disabled Form Buttons
Comment posted March 3, 2023
@K, Over time, I'm personally tending to do less and less client-side validation. But, I admit that I always have the luxury of being on a fast internet connection. I don't think there is anything wrong with client-side validation; and, if it's easy for you to add that kind of functionality, I say g... read entire comment from Ben Nadel.
K replied to a post The User Experience (UX) Of Disabled Form Buttons
Comment posted March 3, 2023
I have to disagree, while the "not-enabling-after-autofill" is indeed a bug itself and needs to be ironed out, I feel like that making a round trip to server validation only to return a message to indicate missing field is not necessary and can lead to slowdowns if connection is poor like you are on... read entire comment from K.
Ben Nadel replied to a post The User Experience (UX) Of Disabled Form Buttons
Comment posted March 2, 2023
@Chris, Completely agree - I'm all for preventing double-form submission. I try to do this (whenever I can remember to do it).... read entire comment from Ben Nadel.
Chris G replied to a post The User Experience (UX) Of Disabled Form Buttons
Comment posted March 2, 2023
Preach! 🙌 The one time I support disabling the form button is directly after submission to mitigate the accidental double-submission. But in this scenario, the default should still be enabled...onClick disable for several ms...then enable again. Hopefully by the time it would be re-enabled, the pag... read entire comment from Chris G.
Ben Nadel replied to a post Creating Custom Turbo Stream Actions In Hotwire And Lucee CFML
Comment posted March 1, 2023
@All, So this custom action="visit" Turbo Stream directive just came in handy when transcluding a ColdFusion form into another page: https://www.bennadel.com/blog/4418-transcluding-a-form-into-a-turbo-frame-using-hotwire-and-lucee-cfml.htm Basically, instead of doing a traditional location() redirec... read entire comment from Ben Nadel.
Ben Nadel replied to a post Creating Custom Turbo Stream Actions In Hotwire And Lucee CFML
Comment posted February 27, 2023
@Peter, My pleasure. 💪... read entire comment from Ben Nadel.
Peter replied to a post Creating Custom Turbo Stream Actions In Hotwire And Lucee CFML
Comment posted February 27, 2023
@Ben, Thanks for clearing that up. I wasn't thinking that the the css/js was only a build step, but I recall that now from DHH's initial Hotwire demo.... read entire comment from Peter.
Ben Nadel replied to a post Creating Custom Turbo Stream Actions In Hotwire And Lucee CFML
Comment posted February 27, 2023
Note to self: I was just reading over on this post by Marco Roth, Turbo 7.2: A guide to Custom Turbo Stream Actions, and it looks like the action callback method might be invoked with some helper properties: this.targetElement - for use with the target attribute (ID-based selector). this.targetEleme... read entire comment from Ben Nadel.
Ben Nadel replied to a post Async Communication Is Great, Except For When It's Awful
Comment posted February 27, 2023
@Randall, I think we can all relate to meetings being excessive, for sure! And, I think "confusion" is the a huge part of this. Getting clarity asynchronously is hard and tedious. Getting clarity during a meeting / screen-share is comparatively much easier!... read entire comment from Ben Nadel.
Ben Nadel replied to a post Creating Custom Turbo Stream Actions In Hotwire And Lucee CFML
Comment posted February 27, 2023
@Peter, That's the goal - to move move as much of the processing and logic into CFML as possible. At runtime, you don't need a node.js server, all the pages are being served by ColdFusion. But, I do need Node to build / bundle the JS and CSS files. At this point, I am not sure there's any way around... read entire comment from Ben Nadel.
Peter replied to a post Creating Custom Turbo Stream Actions In Hotwire And Lucee CFML
Comment posted February 26, 2023
Ben, I'm enjoying your series on Hotwire. Keep the content coming. I'm hoping it culminates with an implementation of Hotwire in CFML. I'd love you use mostly CFML to express my apps, or at least a lite implementation. I mentioned in a previous comment. It would be cool if we could get the whole sta... read entire comment from Peter.
Randall replied to a post Async Communication Is Great, Except For When It's Awful
Comment posted February 25, 2023
@Ben, Agreed. There are times when back-and-forth-and-back-and-forth is stupidly excessive. Then there are times when a meeting is excessive. Both have pros and cons. And, yes, putting some items into a queue to work when someone else has completed their prior task can also be very efficient. It see... read entire comment from Randall.
Ben Nadel replied to a post Including Inline Turbo-Stream Actions In Hotwire And Lucee CFML
Comment posted February 24, 2023
Here's a quick follow-up on creating custom Turbo Stream actions: https://www.bennadel.com/blog/4416-creating-custom-turbo-stream-actions-in-hotwire-and-lucee-cfml.htm In that exploration, I create a visit action which invokes a Turbo.visit() call under the hood.... read entire comment from Ben Nadel.
Ben Nadel replied to a post Async Communication Is Great, Except For When It's Awful
Comment posted February 24, 2023
@Adam, Thank you my friend! 🙌... read entire comment from Ben Nadel.
Adam Lewis replied to a post Async Communication Is Great, Except For When It's Awful
Comment posted February 24, 2023
Great article Ben!... read entire comment from Adam Lewis.
Ben Nadel replied to a post Rendering Elements After The HEAD Tag In JavaScript
Comment posted February 24, 2023
@Bret, My pleasure! Glad you found it interesting. I think this will be a good one to have in the back pocket.... read entire comment from Ben Nadel.
Bret Bernhoft replied to a post Rendering Elements After The HEAD Tag In JavaScript
Comment posted February 24, 2023
I didn't know that elements can be rendered outside of the body tag, that's interesting. Thank you for your walkthrough of this topic, as well as the examples you provide.... read entire comment from Bret Bernhoft.
Ben Nadel replied to a post Dynamically Updating Views With Turbo Streams Using Hotwire And Lucee CFML
Comment posted February 23, 2023
I just published a related post in which I demonstrate that Turbo Stream elements can be returned in any response - it doesn't necessarily have to be a dedicated text/vnd.turbo-stream.html response: https://www.bennadel.com/blog/4414-including-inline-turbo-stream-actions-in-hotwire-and-lucee-cfml.ht... read entire comment from Ben Nadel.
Ben Nadel replied to a post Rendering Elements After The HEAD Tag In JavaScript
Comment posted February 22, 2023
I also wanted to try playing around with this technique to create a persisted IFrame-based video play in Hotwire: https://www.bennadel.com/blog/4413-persisting-an-iframe-based-video-player-across-page-visits-with-hotwire-and-lucee-cfml.htm Essentially, I inject the Hotwire Turbo Frame before the <bo... read entire comment from Ben Nadel.
Ben Nadel replied to a post Hotwire Turbo Drive Doesn't Work With .cfm Page Extensions
Comment posted February 21, 2023
@Chris, I've tried a bit of Stimulus - it looks pretty nice, and keeps things with the Turbo Drive simple (in that it automatically connects / disconnects elements and controllers). I have not tried CBWire yet - but, I was just watching a video demo of it over the weekend. It looks interesting, some... read entire comment from Ben Nadel.
Chris replied to a post Hotwire Turbo Drive Doesn't Work With .cfm Page Extensions
Comment posted February 21, 2023
Stimulus is great too. I had done some basic tests integrating that into CF/Lucee. I need to spend some more time with it. Looking into some things I see cbwire as well which sounds similar in concept. https://cbwire.ortusbooks.com/ Have you worked with this at all?... read entire comment from Chris.
Ben Nadel replied to a post Defer Loading Using Permanent Turbo Frames In Hotwire And Lucee CFML
Comment posted February 19, 2023
I thought that data-turbo-permanent would be a cool use-case for Toast Messages. But, this begs the question: how do we add new messages to the persisted element. For that, I'm using a Stimulus controller that manages both transient and persistent element targets: https://www.bennadel.com/blog/4410-... read entire comment from Ben Nadel.
Ben Nadel replied to a post Goodbye GROUP_CONCAT(), Hello JSON_ARRAYAGG() And JSON_OBJECTAGG() In MySQL 5.7.32
Comment posted February 14, 2023
@Scott, Ooof, I feel your pain 😰... read entire comment from Ben Nadel.
Ben Nadel replied to a post Extending The Current Request Timeout In ColdFusion / CFML
Comment posted February 13, 2023
@Chris, Thank you, good sir! Sometimes it's fun to get into the weeds like this.... read entire comment from Ben Nadel.
Chris G replied to a post Extending The Current Request Timeout In ColdFusion / CFML
Comment posted February 13, 2023
Ok, now I feel like I struck gold here! Great stuff! 🙌💥💯... read entire comment from Chris G.
Scott Steinbeck replied to a post Goodbye GROUP_CONCAT(), Hello JSON_ARRAYAGG() And JSON_OBJECTAGG() In MySQL 5.7.32
Comment posted February 13, 2023
@Ben, Yikes 😱, it is definitely a limit that should either not exist or not fail silently. I have had a similar experience where I was sending out text notifications to a list of users and about 20% weren't receiving anything. It was really hard to track down.... read entire comment from Scott Steinbeck.
Ben Nadel replied to a post Goodbye GROUP_CONCAT(), Hello JSON_ARRAYAGG() And JSON_OBJECTAGG() In MySQL 5.7.32
Comment posted February 9, 2023
@Scott, Oh man, I've been burned by that hard in the past! We had a SQL query where the GROUP_CONCAT() was just silently truncating values. We were then using that list of truncated values as input into another query ... and imagine that when the truncation happened, it was splitting some INT values... read entire comment from Ben Nadel.
Scott Steinbeck replied to a post Goodbye GROUP_CONCAT(), Hello JSON_ARRAYAGG() And JSON_OBJECTAGG() In MySQL 5.7.32
Comment posted February 9, 2023
@Mike, I would assume GROUP_CONCAT is faster, but just be aware, there's a hard limit on how many results GROUP_CONCAT can return that is not the case in JSON_ARRAYAGG I don't believe... read entire comment from Scott Steinbeck.
Ben Nadel replied to a post Goodbye GROUP_CONCAT(), Hello JSON_ARRAYAGG() And JSON_OBJECTAGG() In MySQL 5.7.32
Comment posted February 8, 2023
@Mike, I haven't personally done any performance comparisons. But, I also haven't used this technique on any volume of data where performance would become a problem.... read entire comment from Ben Nadel.
Mike Ritchie replied to a post Goodbye GROUP_CONCAT(), Hello JSON_ARRAYAGG() And JSON_OBJECTAGG() In MySQL 5.7.32
Comment posted February 8, 2023
Just wondering if there has been any performance comparisons done between JSON_ARRAYAGG and GROUP_CONCAT?... read entire comment from Mike Ritchie.
Ben Nadel replied to a post Setting Up My ColdFusion + Hotwire Demos Playground
Comment posted February 6, 2023
@Peter, I'm with you - when I can use more CFML in more places, I feel like I'm winning! 💪 🙌 🎉 In this case, the dependence on Node.js is simply for the building of the JavaScript and Less CSS files. You could, from what I understand, just include the Turbo JS file in your <head> element. I feel ... read entire comment from Ben Nadel.
Peter replied to a post Setting Up My ColdFusion + Hotwire Demos Playground
Comment posted February 6, 2023
Thanks for exploring this topic. I love using CFMl for my projects. The spirt of Hotwire is to enable you to use CFML MORE in place where you would have to move application logic into a JS frame work. Until this series, it seemed like it would be way too hard to use hotwire with CFML. Ben - would it... read entire comment from Peter.
Ben Nadel replied to a post The Value Class java.time.LocalDateTime Cannot Be Converted To A Date In ColdFusion
Comment posted February 6, 2023
@Vahe, Sorry, I am not sure what that error means. Given that you are seeing a Java error (and not a MySQL error), it makes me think that you're executing CONVERT(EXPIRATION in the ColdFusion context, and not in the SQL context. But, I don't understand how that would be possible.... read entire comment from Ben Nadel.
Vahe replied to a post The Value Class java.time.LocalDateTime Cannot Be Converted To A Date In ColdFusion
Comment posted February 6, 2023
@Ben, I tried this, it initially worked, but now getting this error: is not indexable by CONVERT(EXPIRATION, type: java.lang.IllegalArgumentException... read entire comment from Vahe.
Ben Nadel replied to a post A Simple Slide Show Using Hotwire And Lucee CFML
Comment posted February 5, 2023
@Adam, When I first heard about Hotwire, I actually heard about HTMX at around the same time; and, was trying to find some discussions about the pros/cons of each. From what I saw, it seems that HTMX is more "low level" and gives you more flexibility and Hotwire is a little more "high level" and wan... read entire comment from Ben Nadel.