Getting PHP’s print_r Function To Return A String
PHP’s print_r function is invaluable. It prints a human-readable string representation of a variable. It’s one of the most useful debugging features I’ve seen in any language. I like it so much that...
View ArticleHow to Block a Quote
Blockquotes are a great way to reference others’ material. A blockquote lets your reader know that you are quoting another source, and it pays proper attribution to your quoted source. HTML supports...
View ArticleHow To Use Global Variables From Another File In A Perl Module or Package
I’ve been doing a lot of Perl development for my latest project, and I wanted to use a single config file for many scripts. Using a single config file in a basic Perl script is pretty straightforward –...
View ArticleMySQL Performance Tip: ON DUPLICATE KEY is faster than INSERT IGNORE, but...
I’m working on merging a couple of pretty big MySQL databases. Each database consists of just three tables, but each of those tables has at least 9 million rows. Because I need to maintain and update a...
View Articlemod_rewrite in .htaccess to Force www in URL Not Working
Setting up a new site today, I ran into a problem with a .htaccess not working. It was a pretty simple solution, and was the result of a minor oversight my part. Still, it took me about 10 minutes to...
View ArticleMaking Yahoo! Sports Fantasy Pro Football Pickem Sortable
I play Yahoo! Fantasy Sports Pro Football Pickem. In it, you pick the winner of each NFL game every week. I play a version that requires you to not only pick the winner, but to assign “confidence...
View ArticleThe Zen of Taco Bell Programming – Using Unix Tools to Prevent Reinventing...
Saw this great article by Ted Dziuba that parallels my programming philosophy. ( In case you’re interested, here’s a reddit thread on the article. ) In short, the article states that much of what you...
View ArticleDisabling TextArea Scrolling in Flash AS3
Had a problem while working on a new Flash App today. I have a number of dynamic text fields (TextAreas), and they scroll in-place when the user highlights the text and when the user uses the mouse...
View ArticleHow to Scan a Computer for Open Ports
There are a bunch of GUI utilities for conducting port scans, but I prefer to work from a command line shell. In the past, I’ve used a custom script for scanning a machine for open ports from the...
View ArticleManaging Server Load when unzipping many large files
So, I have about 500 zipped up files that I needed to unzip. Each of these files is about 100M when decompressed. I ran into a big problem when unzipping the files all at once – when I did a simple...
View Article
More Pages to Explore .....