Attach Files to Taxonomy Terms in Drupal
From what I can tell, there are plenty of ways to attach files to nodes in Drupal, and even a few ways to attach them to users, but none that I could find to attach them to taxonomy terms (images through the Taxonomy Image module, for sure, but not files in general). My guess [...]
How to Manage External Pages within WordPress
Let’s say you install WordPress in a subdirectory of your site, but you want to use it to manage specific pages in the root directory, as well. The ideal solution would be to move the entire WordPress installation into the root directory, but that may not always be feasible. As it turns out, [...]
Internet Explorer Must Be Stopped
Casual web users probably find this chart amusing, but my fellow web professionals know how close it comes to the truth. Today, I’d like you to take note of the giant yellow section in the top, right-hand corner that indicates, “Time spent trying to get the bastard to work in Internet fucking Explorer.”
In case [...]
How to Hotwire WordPress in 7 Steps
First, let me go ahead and set the right expectation for this article. This is a brief guide to gaining legitimate access to a WordPress site for which you do not know the username or password. This is NOT a guide on hacking a WordPress site.
It’s a fine line, but there are legitimate [...]
WYSIWYR: What You See is What You Regret
Once upon a time much earlier in my career, a coworker observed me composing code in a basic text editor and described the approach as, “Spartan.” I argued that my argument was cleaner, leaner, and all together better. My coworker argued that WYSIWYG code was more convenient and efficient.
In the time since, I’ve progressed [...]
Shiver Me Timbers! jQuery Off the Starboard Bow!
Before you get confused, no, jQuery doesn’t have anything to do with pirates (at least, not that I’m aware of). In honor of International Talk Like a Pirate Day, I’ll be interspersing this post with random, distracting, inappropriate pirate jargon. Don’t blame me; blame the guys who started the meme.
I’ve never [...]
Debugging Syntax Errors in PHP
PHP is unforgiving of syntax errors. Misplaced a semicolon? White screen of death. Mismatched your single and double quotes? White screen of death. Considering a career in Ruby on Rails? White screen of death.
Okay, maybe not the last one, but you get the point. Unless you beg and [...]
Output a Snapshot of All Defined Variables in PHP
The following line of code is one of the most useful diagnostic tricks in my PHP coding arsenal:
<?php echo ‘<pre>’; print_r(get_defined_vars()); echo ‘</pre>’; ?>
Simply input the above snippet of code into any PHP file and you’ll get a browser-friendly snapshot of all variables defined in the current scope. This is especially handy in larger [...]
7 Keys to Courteous Coding
All too often in my professional career, I’ve been tasked with working on legacy code. For those of you unfamiliar with the term, “legacy” in the computing sense refers to old software that has been passed down. Often, legacy programs work just well enough to keep, but not well enough that they don’t [...]
The Developer Disconnect: Why the Best Requirements are Explicit
“Developers are profoundly disconnected.”
Those were my exact words in a recent department meeting. I let the statement hang in the air for a moment so that everyone could give it the consideration it deserved. There was dead silence as everyone waited for me to continue. After a few moments, I clarified.
“They are [...]