Recent Activity
Recent Heroes of the BenNadel.com Community
-
Posted 191 comments since October 23, 2012
-
Posted 15 comments since August 16, 2019
-
Posted 2 comments since November 2, 2023
-
Posted 28 comments since December 11, 2008
-
Posted 81 comments since December 11, 2008
-
Posted 4 comments since September 10, 2009
-
Posted 4 comments since June 1, 2014
-
Posted 9 comments since March 4, 2022
-
Posted 1 comment since November 2, 2023
-
Posted 1 comment since November 19, 2023
Recent Comments
Ben Nadel replied to a post Creating A Marquee Effect With CSS Animations
Comment posted December 1, 2023
@James, Too much animation can be a distraction You are preaching to the choir. I actually heavily dislike most animations. And will gladly remove most of them. In fact, in the cast of Pandora, I'd rather just let the long line wrap - that way I can still the full value at a glance. Most designers t... read entire comment from Ben Nadel.
James Moberg replied to a post Creating A Marquee Effect With CSS Animations
Comment posted December 1, 2023
This could be nightmarish if used in abundance on a webpage that has lots of unintended truncated/overflowed content. I think I'd switch it up and add a visual indicator on any elements that use this (due to overflow) and then scroll while hovering/mouseover and perhaps reset to original upon mousee... read entire comment from James Moberg.
MJ Sminkey replied to a post The RegEx Of Everyday Things
Comment posted December 1, 2023
@Chris G - This comment "it often takes me longer to write a good pattern than to weed through all the false positives I'd get without it. " is WAY too close to home, LOL. I use Regex fairly commonly for situations in my code that demand it, but am lazy about figuring it out for myself when it could... read entire comment from MJ Sminkey.
Ben Nadel replied to a post Multi-Var Assignments In A Single Line In ColdFusion
Comment posted November 30, 2023
@Andrew, Right, you mean like, var a = 1, b = 2; Yeah, I believe that currently / still throws a syntax error in CFML. @Will, I agree - it looks like something is missing. I tend to put all my declarations on separate lines.... read entire comment from Ben Nadel.
Will B. replied to a post Multi-Var Assignments In A Single Line In ColdFusion
Comment posted November 30, 2023
Truth is, while debugging, my eyes would skip right over that and never see it. Like a missing semicolon. I'm all about clarity in my code, before efficiency, because I'll be debugging it later! 😆... read entire comment from Will B..
Andrew Kretzer replied to a post Multi-Var Assignments In A Single Line In ColdFusion
Comment posted November 30, 2023
When I saw the title, I got excited thinking there was a way to use a single var to declare multiple local variables ala javascript.... read entire comment from Andrew Kretzer.
Ben Nadel replied to a post Reflecting On Natural Language Operators In ColdFusion
Comment posted November 30, 2023
@Brad, Yeah, that's a great point re: case-sensitive Java call vs. what would presumably be a case-insensitive ColdFusion call. Would absolutely break some stuff that is already out in the wild. 😨 There's definitely no easy answer for that. Unless they made it into an Application.cfc setting — just... read entire comment from Ben Nadel.
Brad Wood replied to a post Reflecting On Natural Language Operators In ColdFusion
Comment posted November 30, 2023
Would adding "string".startsWith() to the CFML spec itself be a problem? Sadly yes, because a lot of code and even frameworks today rely on that calling the Java method which is case sensitive, so adding a CFML version would be a breaking change. This is one of the issues with having a sort of mashu... read entire comment from Brad Wood.
Ben Nadel replied to a post Reflecting On Natural Language Operators In ColdFusion
Comment posted November 29, 2023
I wish I had a litmus test where I could easily answer the question: should it be a member method, as in: String.includes( value ) ... or, should it be in a standard utility library like: StringUtils.includes( source, value ) I wish I had some decision tree that made it easy to answer that type of a... read entire comment from Ben Nadel.
Ben Nadel replied to a post Reflecting On Natural Language Operators In ColdFusion
Comment posted November 29, 2023
@Brad, I can relate. The contains feels like the only one of the existing ones that I would really consider using. But, I have such a mental block to it. And, I'm always so torn about wanting them to add more member-methods to the data types. Does it just start to bloat the language? Would adding "s... read entire comment from Ben Nadel.
Ben Nadel replied to a post The RegEx Of Everyday Things
Comment posted November 29, 2023
@Chris, Oooof! That's more variety than I even had considered. You're really mixing the full gamut of options there. This code must have been around for a really long time! But yeah, that + generic names for stuff, that's a tough one. 😳... read entire comment from Ben Nadel.
Chris G replied to a post The RegEx Of Everyday Things
Comment posted November 29, 2023
@ Ben Thanks for your reply and your insights. My specific challenge is compounded by a couple factors... Our code base is SUPER inconsistent. Many chef's in the kitchen, all with their own style/preferences. So you'll see instances like... 1a: <cfinvoke component="cfc.sites" method="getSiteData" re... read entire comment from Chris G.
Brad Wood replied to a post Reflecting On Natural Language Operators In ColdFusion
Comment posted November 29, 2023
Great, now ChatGPT is going to parse your blog and it won't be long before GitHub CoPilot is suggesting your fake operators to everyone! 😁 I had the same mental association with GTE, LT, etc as the "second-class" operators I had to use in tags back in the day due to parsing issues. I don't tend to ... read entire comment from Brad Wood.
Ben Nadel replied to a post Reflecting On Natural Language Operators In ColdFusion
Comment posted November 29, 2023
@Chris, At least I'm not the only crazy one 😛... read entire comment from Ben Nadel.
Chris G replied to a post Reflecting On Natural Language Operators In ColdFusion
Comment posted November 29, 2023
I fully relate 👏... read entire comment from Chris G.
Ben Nadel replied to a post Extending The Current Request Timeout In ColdFusion / CFML
Comment posted November 28, 2023
@Joe, That's really odd - I would have totally expected setting the <cfsetting> tag in the onApplicationStart() to have worked. That fact that it is not is surprising to me. At this point, I'm just guessing. But, I wonder what would happen if you put the really large <cfsetting> in the component "ps... read entire comment from Ben Nadel.
Joe replied to a post Extending The Current Request Timeout In ColdFusion / CFML
Comment posted November 28, 2023
Hi Ben, We are running ColdFusion 2016 enterprise and having a hard time trying to increase the request time out for a process. The main issue I want to tackle is during the first load of an app, onApplicationStart takes a lot of time (close to 6 minutes) and I don't want to set the timeout time to ... read entire comment from Joe.
Ben Nadel replied to a post The RegEx Of Everyday Things
Comment posted November 28, 2023
@Dmitriy, Good sir! I never learned Perl, but I hear good things. Actually, to bring this whole conversation full-circle (back to text editors), I first started using RegEx in Macromedia HomeSite. I would get all this data from Excel documents that clients would give us. Then, I would copy-pasted it... read entire comment from Ben Nadel.
Dmitriy Goltseker replied to a post The RegEx Of Everyday Things
Comment posted November 28, 2023
I learned a great deal of RegEx when I was learning Perl back in a day.... read entire comment from Dmitriy Goltseker.
Ben Nadel replied to a post The RegEx Of Everyday Things
Comment posted November 28, 2023
@Chris, RegEx is great, but it definitely doesn't solve all the problems the best. I used to try to use it too much for getting at HTML data. But, then I realized that it was much easier to just parse the HTML with something like jSoup and the query the Document Object Model, jQuery-style. But, ther... read entire comment from Ben Nadel.
Chris G replied to a post The RegEx Of Everyday Things
Comment posted November 28, 2023
Bookmarked! I've found Regex to be both helpful and frustrating in equal parts. When I need a quick pattern, it often takes me longer to write a good pattern than to weed through all the false positives I'd get without it. But when you have a great pattern, magic ✨ One I wish I had a good pattern fo... read entire comment from Chris G.
Ben Nadel replied to a post Coming Soon: Feature Flags - From Concept To Cultural Revolution
Comment posted November 27, 2023
@All, I'm super excited to announce that I have an EARLY ACCESS version of the book available. This is a PDF version, and is a bit rough around the edges. But, the content is there and it's 50% off. If you get the early access version, you'll automatically get access to future versions as well. Chec... read entire comment from Ben Nadel.
Ben Nadel replied to a post Code Kata: Array Intersection, Union, And Difference In Lucee CFML 5.3.8.201
Comment posted November 19, 2023
For anyone who gets here and isn't sure what @Chris is talking about, he's dipping down into the Java layer of ColdFusion. The .removeAll() method isn't a member method of the Array data-type in ColdFusion - it's a method on the underlying ArrayList Java class. One of the very fun parts of ColdFusio... read entire comment from Ben Nadel.
Chris Wigginton replied to a post Code Kata: Array Intersection, Union, And Difference In Lucee CFML 5.3.8.201
Comment posted November 19, 2023
Just a short implementation of determing records to delete/insert from a given selection of ID's and existing ID's, which ones are needed to insert and which are needed to deleted. selectedList = "1,2,6"; currentList ="1,2,3,4,5"; selectedArray = ListToArray(selectedList); currentArray = ListToArr... read entire comment from Chris Wigginton.
Mauro Caresimo replied to a post Expected And Unexpected getBaseTagData() Behavior In Lucee CFML 5.3.7.47
Comment posted November 2, 2023
Thanks for your prompt response Ben and may I say its a privilege :-) Is it an official workaround or a hack that you have tried and tested? Also is applying this in terms need consideration regarding case sensitivity? Kind regards, Mauro... read entire comment from Mauro Caresimo.
Arvind Bhargav replied to a post On Starting A Side-Project: Hotwire vs. Angular
Comment posted November 2, 2023
Hey Ban, I'm also working on a project to migrate code from Angular to Hotwire. Do you have any suggestions or tips?... read entire comment from Arvind Bhargav.
Ben Nadel replied to a post Expected And Unexpected getBaseTagData() Behavior In Lucee CFML 5.3.7.47
Comment posted November 2, 2023
@Mauro, Hmm, good question. I honestly don't remember which part of my email DSL caused this problem. Because, I certainly do use CFModule extensively inside the DSL implementation, in both Lucee and Adobe ColdFusion. I just took a look at the code, and it seems that I have some places where I call ... read entire comment from Ben Nadel.
Mauro Caresimo replied to a post Expected And Unexpected getBaseTagData() Behavior In Lucee CFML 5.3.7.47
Comment posted November 2, 2023
Hi Ben Is this a problem only with Lucee version 5.3.7.47 ? and if so is there a workaround? Thanks, Mauro... read entire comment from Mauro Caresimo.
Ben Nadel replied to a post Extending The Current Request Timeout In ColdFusion / CFML
Comment posted October 26, 2023
@Mike, Of course, any time! 💪 One great example of this is for use in scheduled tasks - the background tasks that ColdFusion provides. Often times, we use scheduled tasks to run large calculations or generate documents (really, do any kind of "heavy lifting"). It's great to be able to set a low def... read entire comment from Ben Nadel.
Mike Savoy replied to a post Extending The Current Request Timeout In ColdFusion / CFML
Comment posted October 26, 2023
Many thanks for answering my question... Very nice and appreciated. I will follow your instinct. Thanks Mike... read entire comment from Mike Savoy.
Ben Nadel replied to a post Extending The Current Request Timeout In ColdFusion / CFML
Comment posted October 26, 2023
@Mike, This type of code can go anywhere in the request flow. That said, I will often put the "default" request timeout in the onRequestStart() method in the Application.cfc ColdFusion framework component. This way, I can set an expectation for every request coming into the application. Then, I will... read entire comment from Ben Nadel.
Mike Savoy replied to a post Extending The Current Request Timeout In ColdFusion / CFML
Comment posted October 26, 2023
Sorry for asking but where that code is the best place to put it... application.cfm, application.cfc or in the scipt page Many thanks for great support you are giving us Mike Savoy... read entire comment from Mike Savoy.
Ben Nadel replied to a post CSS overscroll-behavior Only Affects Scroll Containers
Comment posted October 25, 2023
@Jarvis, In my experience, having the width of the page change my a small amount usually isn't a problem since it's happening in conjunction with another large UI change (such as showing a modal window). Only to say that the small change isn't that noticeable. That said, I believe that if you want t... read entire comment from Ben Nadel.
jarvis replied to a post CSS overscroll-behavior Only Affects Scroll Containers
Comment posted October 25, 2023
Is there another way instead of "overflow hidden" on body element? Because if I add and remove "overflow hidden", the scrollbar disappears and appears, which will make the page width shaking. The thing I want is "overscroll-behavior contain" making effect on non-scrollable div.... read entire comment from jarvis.
James Moberg replied to a post Enforcing The HTTP Request Method In ColdFusion
Comment posted October 24, 2023
We do use cfparam to predefine all expected form parameters, but only after the initial request has met the requirements of the structkeyexists() validation.... read entire comment from James Moberg.
James Moberg replied to a post Enforcing The HTTP Request Method In ColdFusion
Comment posted October 24, 2023
There was a CF4 custom tag called CF_FormURL2Attributes that would copy all FORM & URL variables to a generic "attributes" scope. (I believe that it also accepted path-based values from SEO-friendly URLs.) I don't see this CFTag available anywhere online anymore. We used it back in '98 and still use... read entire comment from James Moberg.
Ben Nadel replied to a post Enforcing The HTTP Request Method In ColdFusion
Comment posted October 24, 2023
@James, I think that works well, I use cfparam to set defaults for a lot stuff; so, I tend to have very few "key exists" checks. But, I think it makes sense to have a "post" check as a precursor to actually processing the form (as opposed to just having a throw() like I did my example).... read entire comment from Ben Nadel.
James Moberg replied to a post Enforcing The HTTP Request Method In ColdFusion
Comment posted October 24, 2023
We validate the request method & test for at least one of the required form variables. If this condition is not met, we re-display the form. (If a form post was used and not valid, we display a pretty inline error message.) Something like this... (NOTE: This is generic.) isFormPost = CGI.REQUEST_MET... read entire comment from James Moberg.
Ben Nadel replied to a post Working Code Podcast - Episode 147: Potluck
Comment posted October 24, 2023
@Mike, Thanks for such positive feedback. I too am always so impressed by Carol! She's easily one of the most resilient, most positive persons I've ever met. I'm always in awe of her ability to just roll with the punches and keep moving forward. I wish I had more of that in my life. If you have anyt... read entire comment from Ben Nadel.
Mike replied to a post Working Code Podcast - Episode 147: Potluck
Comment posted October 24, 2023
Great episode! I always enjoy the variety of topics you discuss on the Working Code Podcast, and this one was no exception. Ben's insights into Transactive Memory Systems Theory were fascinating, and it's exciting to think about how such psychological theories can be applied in engineering. Carol's ... read entire comment from Mike.
Christian replied to a post On Starting A Side-Project: Hotwire vs. Angular
Comment posted October 21, 2023
All that led me to the idea to the need of a new html markup language... read entire comment from Christian.
James Moberg replied to a post jSoup Error: Index Out Of Bounds For Length
Comment posted October 20, 2023
A fix for this exact issue (1.16.2) was released last night. https://jsoup.org/news/release-1.16.2 Your blog is also listed in the notes: https://github.com/jhy/jsoup/issues/2013 Appending a node back to its original Element after empty() would throw an Index out of bounds exception. Also, now the c... read entire comment from James Moberg.
Mike replied to a post jSoup Error: Index Out Of Bounds For Length
Comment posted October 20, 2023
Great article, Ben! Your detailed exploration of the jSoup error and the fix is incredibly helpful. It's not uncommon to encounter such issues while working with libraries like jSoup, and your solution will undoubtedly save others a lot of troubleshooting time. It's also fantastic to see how respons... read entire comment from Mike.
Ben Nadel replied to a post jSoup Error: Index Out Of Bounds For Length
Comment posted October 20, 2023
@Charles, To be honest, I don't know how duplicate() plays with Java objects. We're consuming this stuff in ColdFusion; but, the jSoup library is ultimately a Java library; and, I'm not sure how "deep" the "duplicate" logic will run. Meaning, if the issue we have here is with parent-child pointers b... read entire comment from Ben Nadel.
Charles Robertson replied to a post jSoup Error: Index Out Of Bounds For Length
Comment posted October 20, 2023
Hi Ben Just thinking off the top of my head, so this could be a completely idiotic suggestion, but couldn't you just create a deep copy of that object, like: Duplicate(object) Example: paragraph = Duplicate (body.firstElementChild());... read entire comment from Charles Robertson.
Ben Nadel replied to a post Understanding The TrimWhitespace() Function In Lucee CFML
Comment posted October 19, 2023
@James, I love that we can see Lucee's code! Such a benefit of having it open-source. I can't tell you how many times I've wanted to see what Adobe ColdFusion is doing behind the scenes!... read entire comment from Ben Nadel.
Ben Nadel replied to a post jSoup Error: Index Out Of Bounds For Length
Comment posted October 19, 2023
@Jonathan, Wow, thanks for knocking that out! 🔥 As I was looking at the stacktrace, I saw a number of core Java calls, so I wasn't sure if this was something in jSoup itself, or something in the way Java's ArrayList worked. Glad to see it was only simple for-loop change on your end. jSoup is awesom... read entire comment from Ben Nadel.
Jonathan Hedley replied to a post jSoup Error: Index Out Of Bounds For Length
Comment posted October 18, 2023
Thanks Ben, good catch! I have fixed this in jsoup and it'll be in the next release (1.16.2). See bug #2013. Please do feel free to raise issues directly on the jsoup tracker -- whether it's a hardline "bug" or just a rough edge, am always happy for feedback.... read entire comment from Jonathan Hedley.
James Moberg replied to a post Understanding The TrimWhitespace() Function In Lucee CFML
Comment posted October 10, 2023
The java source for Lucee's trimWhitespace() function is available at: https://github.com/lucee/Lucee/blob/8554dddfffcdc5fdb0c4d9f298c61bc0d6c837d2/core/src/main/java/lucee/runtime/functions/string/TrimWhiteSpace.java#L9 It looks like it filters some common ASCII7 space characters, but not UTF-8 or ... read entire comment from James Moberg.
Ben Nadel replied to a post Remediating CSV Injection Attacks In ColdFusion
Comment posted October 2, 2023
@Dawesi, These are really great points! And, unfortunately, I don't really have a good answer. As you are saying, if the importing system doesn't know about these escapes, then the import is going to lead to some unexpected outcomes (if not even errors). Since security is often dictated by a set of ... read entire comment from Ben Nadel.