Categories
PHP Tips & Tutorials

Checklist slides to learn the new features in PHP 5.3 with examples

One of my old Internet friends Brad made a very nice online slide that introduces to you some of the exciting new features of PHP 5.3. I’m most interested in namespace that would make coding in a large project and code reuse much easier, especially for people who find keeping naming conventions a challenge in the team.

Here’s the original post and slide: http://bradley-holt.com/2010/11/new-features-in-php-53/

All the new stuff and concepts are presented in a practical manner that’s extremely straightforward. Programmers should find them a breeze to crunch.

Categories
Regular Expression Tips & Tutorials

A small mistake in a regular expression caused connection to reset – (.+)+

Was doing something with a regular expression and very oddly the connection keeps being reset every time I refresh the web page.

I tried to narrow down the problematic line by removing the code in functional chunks. Finally it comes down to a preg_match() instance with a small bit in the regular expression that’s accidentally and wrongly typed in caught my attention:

(.+)+

Got rid of the second plus sign:

(.+)

And it’s all right.