Main

PHP Archives

December 30, 2007

Regular Expressions

PHP is a simple programming language with a lot of horsepower. That's why I love working with it.

But to take advantage of some of its most useful features, you need to have at least some basic knowledge of regular expressions.

Regular Expressions have a syntax that is complicated, convoluted, and cantankerous. But once you master them, you become powerful indeed.

For instance, to parse a form field to confirm that it is a legitimate email address, this piece of pHP code will do the trick:

eregi("^[a-z0-9\._-]+@+[a-z0-9\._-]+\.+[a-z]{2,3}$", $_POST['email']))

In a nutshell, the eregi function (case-insensitive) uses regular expressions defined here to look in a form field called email for:

  • alphanumeric characters, followed by
  • the "@" symbol, followed by
  • more alphanumeric characters, followed by
  • a period, followed by
  • two or three letters.

Powerful stuff indeed!

Continue reading "Regular Expressions" »

August 24, 2008

Shameless Unpaid Endorsement: The Open Technology Group

In a couple of weeks, I'm off to Raleigh, North Carolina for my third consecutive year of a week's worth of training with Chander Ganeson at The Open Technology Group.

The training you receive for the price that you pay is incomparable, especially when you realize the the reasonable fee includes air fare and a week in a decent hotel! The hotel is within walking easy walking distance, and so is a nice mall and a bunch of restaurants. I never bother to rent a car.

I have personally taken the introductory PHP course and the AJAX programming with PHP course.

I have also taken (elsewhere) the basic CCNA course that Cisco offers. I would compare the quality of that course as dead even with what Chander offers. The difference is that the Cisco course costs more. And that does NOT include any sort of travel arrangements.

Sure, there are some apples and oranges stuff going on here. Networking fundamentals have nothing to do with web development. But that is really meaningless here, as technological training is judged by what you know and put into practice afterwards.

I have had lots of training, including the Red Hat prep course for the RCHT test, an advanced security boot camp, Cisco's Building Multilayer Switched Networks, and a few others. But I consider Cisco's introductory course as one of the top three overall experiences I've had in schooling, along with the two OTG offerings.

Continue reading "Shameless Unpaid Endorsement: The Open Technology Group" »

About PHP

This page contains an archive of all entries posted to Geeky Baldisms in the PHP category. They are listed from oldest to newest.

Everything Else is the previous category.

Software is the next category.

Many more can be found on the main index page or by looking through the archives.

Powered by
Movable Type 3.33