Recent Web Log Entries By Ben Nadel

Showing 1 - 11 of 11   < Prev | Next >

Grouping Nested ngRepeat Lists In AngularJS

Posted: February 28, 2013 at 9:20 AM by Ben Nadel

Tags: Javascript / DHTML

The other day, I wanted to output a list of values in AngularJS using ngRepeat; however, I wanted that list to be grouped into sublists. Out of the box, ngRepeat doesn't have any group-by control, like ColdFusion does . But, nesting ngRepeats is fairly straightforward if you take on the responsibility of creating the groups yourself. ... read more »

Comments (4)  |  Post Comment  |  Ask Ben  |  Permalink



POIUtility.cfc Now Hosted On GitHub

Posted: February 26, 2013 at 9:33 AM by Ben Nadel

Tags: ColdFusion

This is just a quick post to say that my old POIUtility.cfc is now hosted on GitHub . I cleaned the codebase up a little, adding some organizational folders; but, mostly, it was copied over as-is to GitHub. For those of you who have no idea what the POIUtility.cfc is, it's a ColdFusion component (and set of ColdFusion custom tags) that facilitat... read more »

Comments (9)  |  Post Comment  |  Ask Ben  |  Permalink


Exploring Sample Software Application Layers And Responsibilities

Posted: February 22, 2013 at 9:59 AM by Ben Nadel

Tags: ColdFusion

A couple of months ago, I summarized how I've been thinking about software application layers and the responsibility of those various layers . Of course, putting it on paper and putting it into action are two very different things. And, since then, I've found myself getting lost and confused as to which parts of the application belong in which la... read more »

Comments (12)  |  Post Comment  |  Ask Ben  |  Permalink



Using AtomicInteger To Create Uniquely Named CFThreads In ColdFusion

Posted: February 20, 2013 at 9:39 AM by Ben Nadel

Tags: ColdFusion

When you use CFThread to run code asynchronously in ColdFusion, all threads in a given request need to be uniquely named. This is (theoretically) because all threads in a single request can be accessed, by name, using the "cfthread" scope, regardless of where in the codebase they were spawned. Failure to provide a unique name will precipitate the ... read more »

Comments (11)  |  Post Comment  |  Ask Ben  |  Permalink


Mixing Static And Dynamic Data In An AngularJS Select Menu

Posted: February 19, 2013 at 9:54 AM by Ben Nadel

Tags: Javascript / DHTML

Due to the data-driven, two-way binding nature of AngularJS input elements, mixing static and dynamic data in a single Select menu can be challenging. If your data it completely dynamic, it's a total breeze. But, the moment you want to add a static option, suddenly you have an asymmetric list of references that need to be mapped on to your View Mo... read more »

Comments (0)  |  Post Comment  |  Ask Ben  |  Permalink


Adding An ngRepeat List Delimiter In AngularJS

Posted: February 17, 2013 at 1:23 PM by Ben Nadel

Tags: Javascript / DHTML

Recently, I played around with an AngularJS directive that compiled and transcluded its target element . That experiment left me a little confused as to how the compile step actually worked; so, I wanted to take a step back and look at compiling an element with fewer facets. This time, rather than transcluding, I'm simply going to compile the DOM... read more »

Comments (11)  |  Post Comment  |  Ask Ben  |  Permalink


Using ngController With ngRepeat In AngularJS

Posted: February 15, 2013 at 4:20 PM by Ben Nadel

Tags: Javascript / DHTML

Most of the time, when you use the ngController directive in AngularJS, you're associating a Controller with a relatively static part of your user interface (UI). When it comes to ngRepeat, however, you can still use ngController - you just have to realize that you're creating a controller instance for every clone that gets created in the ngRepeat... read more »

Comments (19)  |  Post Comment  |  Ask Ben  |  Permalink


Directive Link, $observe, And $watch Functions Execute Inside An AngularJS Context

Posted: February 13, 2013 at 9:56 AM by Ben Nadel

Tags: Javascript / DHTML

When you run code inside an AngularJS Controller or Service object, you never have to worry about calling $apply() since your code is executing inside of an AngularJS "context." By this, I mean that AngularJS is aware that your code is running and will perform a dirty-check after the code has completed. When you're inside a Directive, however, Ang... read more »

Comments (2)  |  Post Comment  |  Ask Ben  |  Permalink


Using jQuery Event Delegation In AngularJS

Posted: February 12, 2013 at 9:52 AM by Ben Nadel

Tags: Javascript / DHTML

AngularJS is a very different beast when compared to jQuery (or vanilla JavaScript). In AngularJS, "context" is truly a first-class citizen. By that, I mean that AngularJS executes every piece of code in a specific container that is limited in scope. Unlike binding normal onclick event handlers, which have the entire document as a context, an ngCl... read more »

Comments (6)  |  Post Comment  |  Ask Ben  |  Permalink


Exploring Directive Controllers, Compiling, Linking, And Priority In AngularJS

Posted: February 9, 2013 at 6:41 PM by Ben Nadel

Tags: Javascript / DHTML

Recently, I talked about using Controllers inside of AngularJS Directives as a way to facilitate inter-directive communication . For simple directives, this seems to work great; however, I recently ran into a wall when trying to use directive controllers in conjunction with a directive that also had a compile() function. In my case, a non-compile... read more »

Comments (2)  |  Post Comment  |  Ask Ben  |  Permalink


Using Controllers In Directives In AngularJS

Posted: February 1, 2013 at 5:46 PM by Ben Nadel

Tags: Javascript / DHTML

In AngularJS, you have your Views, which present data to the user; you have your Controllers, which manage the $scope (ie. view model) and expose behavior to the View; and, you have your Directives, which link user interactions to $scope behaviors. But then you also have a special kind of Controller - a Directive Controller. The Directive Controll... read more »

Comments (16)  |  Post Comment  |  Ask Ben  |  Permalink

Showing 1 - 11 of 11   Pages: 1 < Prev | Next >

January 2013 Entries »

View All Blog Entries »

  • Help Wanted - Find Your Next ColdFusion Job
Ben Nadel's Company - Epicenter Consulting Recent Blog Comments
May 23, 2013 at 9:52 PM
Preventing Links In Standalone iPhone Applications From Opening In Mobile Safari
@Muhmmadibn Did you figure out a solution to launching PDFs? I am running into the same issues myself. There is no way to close the PDF or go back once you launch it. Thanks in advance! ... read »
May 23, 2013 at 6:06 PM
The Girl Who Broke My Heart, And Made Me A Better Person
Good day,ladies and gentle men, my name is Dr AMADI the great spell caster in Africa, i have help so many people for different kind of problems,who say there is no solution to problems on earth, that ... read »
May 23, 2013 at 4:26 PM
ColdFusion QueryAppend( qOne, qTwo )
@Heather, Glad people are still getting value out of this! ... read »
May 23, 2013 at 3:49 PM
Strange Interaction Between DeserializeJson(), ArrayContains(), And Database Values In ColdFusion
@WebManWalking, I meant the code at the bottom (not the video). I did try to experiment with an intermediary variable, like: value = users.id[ i ]; arrayContains( userIDs, value ); ... but t ... read »
May 23, 2013 at 11:06 AM
Strange Interaction Between DeserializeJson(), ArrayContains(), And Database Values In ColdFusion
@Ben, Are you talking about As Number: YES As String: YES As Java: YES? If so, that's with 3 different ways of referencing the constant 1, not users.id[1]. Query object references(*) are what seem ... read »
May 23, 2013 at 9:55 AM
Strange Interaction Between DeserializeJson(), ArrayContains(), And Database Values In ColdFusion
@Dan, According to the CF Admin, I'm running Java "1.6.0_45". As far as the DB column, in the database it's an INT. I'll see if I can dig into what CF sees it as. @WebManWalking, But h ... read »
May 23, 2013 at 9:49 AM
Strange Interaction Between DeserializeJson(), ArrayContains(), And Database Values In ColdFusion
@Ben, I think the problem is that we're used to loose typing in ColdFusion, like JavaScript. If a value is a number but it's needed in an expression to be a string, noooo problem. I've encountered ... read »
May 23, 2013 at 9:47 AM
ColdFusion QueryAppend( qOne, qTwo )
You rock! Thank you, thank you, thank you!!! ... read »
InVision App - Prototyping Made Beautiful With Prototyping Tools