Linked text and select fields

Just a quick snippet for my own reference (or yours) to link together text fields and select fields so that changes to one change the other.

Assumes the matched fields have IDs of :

  • text field: someFieldID
  • select field: someFieldIDSel

Assumes and initial, unselected Select option with a value of “invalid”.

It also prevents the insertion of illegal values into the text box.

Canaries, legends, and heights

Have been working on a site and all of a sudden, this morning, it was broken. 

AAAAHH!!!! Run around in a panick.

Then I noticed it was only broken in Chrome Canary (their dev browser) and the break was very specific: <legend> tags were having a height applied to them, perhaps inherited from their parent <fieldset> tag? The numbers didn’t add up, so it was hard to tell. Also, it only caused obvious display problems if the legends were being displayed as their own block instead of part of the field set border, but on inspection the blocks were still sized incorrectly behind the scenes.

Continue reading

Filtering a CFML array of structures

For some reason I don’t fully understand, I am now working in a ColdFusion shop. I mean, it is not like it’s a SharePoint shop, but still.

Anyway, I am busy building an assessment tool to assess how people do in courses, almost all of which are bespoke, and I have a nice simple pattern for building questions that involves an array of question structures.

So good so far, but when I want to generate a page with just the questions for that page, I need some way to say which questions to grab. Simple enough, right? Just grab every element in the array that says, “Put me on page X!” Of course, I am still learning CFML, so this simple task involves lots of Googling.

Continue reading

Is atom.io fighting you? Package manager timeouts.

I mostly like atom.io as an editor.

Highly configurable, lots of toys, is built on that evil creature whose initials are JS. Though it was a tough choice between that, Brackets, and Sublime Text. And i really did have to finally move away from jEdit.

But I work in a place with a really big site, so Brackets is out because we run right over its file cap.

And there are many fingers in the pie, some more technologically literate than others, so I need something I can show anyone how to set up and use, especially with how to edit files remotely via FTP. Atom is friendlier than Sublime Text on both those counts.

Which is not to say it doesn’t have its quirks.

Continue reading

Stupid Ideas: Use the Latest Technology

When trying to promote one’s self, or one’s Website, it is important that one take advantage of the newest and latest technologies.

For instance, spinning, flaming logos.

Or, in modern parlance, embracing every new JavaScript framework and sneering at last month’s as passé. It proves you can do really neat things with really neat other things, even if everyone is just using the exact same Bootstrap template.

The latest technology is chic. It’s cutting edge! It’s all about the self-promotion of pushing the envelope beyond what your customer’s browsers actually support. They’ll update eventually.

But really, a problem that often vexes any good application development and design is getting so caught up with the newest toys that things like audience needs get put on the back burner in favor of cool toys.

Why? Usually because it saves us from having to think about it. We don’t have to think about what the audience wants. We don’t have to think about whether what we are promoting is worth the effort. We don’t have to engage with the product. We just make it look pretty, ideally with someone else’s canned solution, or make it appropriately shiny and jangly. Done.

Sometimes pushing out new toys succeeds, and you create demand for something where none existed before, or at a bare minimum you trend for a bit as everyone oohs and aahs over your cleverness. But most of the time it just adds unnecessary clutter to the final product. The really old IBM ad above nails it on the head. It looks neat, but how does it address customer needs?

Compare Google Docs to Microsoft Office. Google Docs has actually be reducing functionality in their office suite, not increasing it. Why? Because it is not meant for desktop publishing, it is meant for sharing ideas online, collaboratively, in the easiest was possible. Once something in finalized, then export it to Word, or better LibreOffice, and give it to the content experts to make it look sharp. Google are masters of using the most advanced toys possible to make things as plain and and simple as possible. Though they are far from innocent on the latest technology trap. They are so determined to keep things as fresh as possible that the tools you are working with can change from one day to the next without even a hint of advance notice. 

Equivalent content

Equivalent content: a brief lesson in basic design principles.

Equivalent content is content that serves the same function as that which it replaces. This equivalency is one of intent and meaning, not of visual appearance, unless the visual appearance is the meaning you are trying to convey. This is a critical and easily addressed point in making Web sites accessible.

Consider this good example of describing visual appearance:

This detail image of the hand of Michalengelo’s David clearly shows how it was disproportionately large, perhaps deliberately scaled to be more prominent when seen from a distance.

Continue reading

Keeping it ratio-nal

Found a wonderful toy to add to the redesign of my Website.

Something I was reading led me to an article on A List Apart titled More Meaningful Typography.

The key takeaway from the article was use meaningful modular scales in setting your font sizes so that there is proportion and balance as fonts scale.

The article came with two toys:
Continue reading

WordPress widgets in Twig

Okay, so I decided I had to be difficult and redo my site in Twig and Sass, which required two nifty plugins:

So, I am going to talk about the issues I encounter while trying to build new template with them. Otherwise it will be months before people hear from me again. Today’s topic is:

Enabling widgets in Twig

Continue reading