Drop-down list-of-values populated by database tables are another important component of enterprise-grade web frameworks. Although most frameworks do support them through one technique or other, the ease of implementation is key in this often-used feature.
Unfortunately, many web frameworks make the process of creating data-bound drop-down list-of-values much more difficult than the one-line statement the operation should merit. ASP.NET is the greatest offender, requiring preloading of the values in a special form initialization event, with many vulnerable breaking-points in the code. PHP and Ruby both do a fairly decent job of implementation, with PHP requiring a little more overhead, while Ruby bringing its “convention over configuration” syntax manhandling into the mix. Node.js performs best in respect to this functionality, by enabling systematized reproduction of the drop-downs once it has been coded well the first time.
At its core, the drop-down list-of-values simply populates an HTML select object, and processes the result on the back-end. Where .NET goes wrong with this component is with its design philosophy of isolating the user from being required to write HTML. Unfortunately, web developers cannot escape HTML, since all code eventually generates HTML anyway, so the framework gets in the way as often as it helps.
In the next part of this series, we will review N-depth parent-child relationships, and their comparative implementation in various web frameworks.
Written by Andrew Palczewski
About the Author
Andrew Palczewski is CEO of apHarmony, a Chicago software development company. He holds a Master's degree in Computer Engineering from the University of Illinois at Urbana-Champaign and has over ten years' experience in managing development of software projects.