If you've ever wanted a simple, printable calendar you can print and then put up on your refrigerator, I just created one over on the Valley Programming website. Here's a link to my simple printable calendar blog post over there. And fwiw, here's an image to give you a little idea of what the calendar looks like:
Scala, Java, Unix, MacOS tutorials (page 344)
Perl FAQ: How do I read command-line arguments in Perl?
Note: If you want to handle simple Perl command line arguments, such as filenames and strings, this tutorial shows how to do that. If you want to handle command-line options (flags) in your Perl scripts (like -h or --help), my Perl getopts command line options/flags tutorial is what you need.
Summary: A PHP “string to date” conversion example.
For a recent PHP calendar project I needed to convert a given string into a 'date' I could work with more easily. In short, given a string date like this:
"2011/05/21"
I wanted to convert that to some type of PHP date data structure I could use to render a calendar.
PHP string to date source code
The following PHP code shows the two steps I used to convert a date string into a PHP date structure I could work with:
Summary: How to use the Linux egrep command with multiple regular expressions (regex patterns).
As a quick note here today, I just used the Linux egrep command to perform a case-insensitive search on multiple regular expressions (regex patterns). Really, what I did was a little more complicated:
locate -i calendar | grep Users | egrep -vi 'twiki|gif|shtml|drupal-7|java|PNG'
As you can see from that command, I did this:
Perl "grep array" FAQ: Can you demonstrate a Perl grep array example? (Related: Can you demonstrate how to search a Perl array?)
A very cool thing about Perl is that you can search lists (arrays) with the Perl grep function. This makes it very easy to find things in large lists -- without having to write your own Perl for/foreach loops.
After writing several recent Model/View/Controller (MVC) pattern articles (A Model View Controller diagram, Model View Controller definitions), I thought it might help to share a real-world implementation of an MVC design. To that end, I’d like to share some information from a Java/Swing GUI application I wrote several years ago to help me in my work with Function Point Analysis (FPA).
Summary: A collection of PHP job interview questions (and other standard computer programming interview questions).
Over the years, I've found the best way to find out how a potential programmer works is to sit with him at a computer keyboard and write some code, typically something requiring some database interaction, and potentially interaction with another developer.
From everything I've read on Apple's discussion forums, the Mac Defender trojan/virus can only be installed on your Mac OS X system under the following circumstances:
From what I've read on the Apple discussion forums, here's how you delete the Mac Defender trojan from your system.
It looks like reports of the "Mac Defender" trojan/virus/malware are the real deal. Several Apple discussion forums related to the Mac Defender trojan (it's not a virus) have several thousands page-views and hundreds of comments. You can find these threads by searching Google with this query:
MacBook Air external monitor FAQ: How do I connect an external monitor to my MacBook Air?
Because the MacBook Air and the iMac use the same Apple Mini DisplayPort technology to connect to external monitors, the process of connecting an external monitor to a MacBook Air is nearly the same as connecting a dual monitor to an iMac:
git status FAQ: When I issue the "git status" command, I see the following "Your branch is ahead or origin/master ..." git message:
# On branch master # Your branch is ahead of 'origin/master' by 5 commits. # nothing to commit (working directory clean)
What does this "Your branch is ahead of 'origin/master' by X commits" message mean? I keep committing my changes with "git commit", so this message seems to be in error.
Summary: How to make a Java JFrame transparent (translucent) on Mac OS X.
A lot of people complain about a lot of things in regards to Java on Apple's Mac OS X platform, and okay, occasionally I'm one of them, but a very cool thing you can do on OS X is to create translucent (transparent) frames and windows with Java.
I've been working with the Java keytool command a lot lately, as I needed to learn all about it to license my "Hide your desktop icons" app with the TrueLicense software license manager. I think I've learned a lot about the Java keytool command, keystore files, and certificates, and I'm trying to simplify and share that information here.
Java directory FAQ: How do I create a directory (or directories) in Java? (Also written as, "How do I make a directory in Java?)
To create a directory in Java, just use the "mkdir" or "mkdirs" methods of the Java File class. Here are a few examples to demonstrate this.
Regular expression FAQ: Do you have a list of common regular expression examples, i.e., the most common regex patterns used in programming languages like Java, Perl, PHP, Ruby, and others?
I've been asked several times, so I thought it might be helpful to post some of the most common regular expression examples that are used in programming. Honestly I haven't tested any of these yet -- I did them off the top of my head -- but I think they will work for most open source programming languages.
Today was mostly a day off for me, but I thought I'd do one thing here to help organize the website a little better. To that end, I've put together a list of the Java MySQL examples I've created, i.e., Java database examples that were specifically written for MySQL.
It's so rare that a CEO talks in detail about how their company generates revenue that I want to take a moment and share this TechCrunch link, which covers Evernote CEO Phil Libin's presentation at a meeting named Founder Showcase. Mr. Libin discussed some of the elements of making the "freemium" business model work.
Drupal form fieldset FAQ: How do I build a Drupal form using one or more fieldset areas to group my form elements into logical components (like 'shipping address', 'billing address', 'credit card information', and so on)?
As inferred by the question, you group Drupal form elements using the Drupal fieldset element. You define a fieldset, then add form elements to that fieldset using a simple sub-array syntax. For example, in the following Drupal source code example I define a fieldset using an array like this:
