regular expression

David Otton's Blog: Stupid PHP Tricks: Illegal Variable Names

PHPDeveloper.org  Fri, 08/22/2008 - 13:47

David Otton has shared another of his "stupid PHP tricks" on his blog today. This one looks at illegal variable names that don't match the "can't start with a number" rule the manual points out.



 

Debuggable Blog: String substitution using UUIDs

PHPDeveloper.org  Fri, 08/22/2008 - 12:04

On the Debuggable blog, Felix Geisendorfer shows how to create a string parser that allows you to pull out parts of the string you don't currently want manipulated to be put back later.



 

Strings to array - Gareth Heyes

Planet PHP  Tue, 07/29/2008 - 17:01

I’ve been busy lately so I’ve not had time to post much but while writing yet another fuzzer I added a new tag to Hackvertor.

Basically I write this code a million times and adding to Hackvertor enables me to save time and conveniently convert strings to arrays.

The tag supports both Javascript and PHP array creation and uses a regular expression to split the data.



 

Creating custom PHPUnit assertions - Raphael Stolt

Planet PHP  Mon, 07/28/2008 - 12:02

While developing PHP applications and applying developer testing the applications safety net will grow along the timeline, and as normal code, test code should be in a fresh, odour free state too.

A common test code smell, amongst others, is the duplication of assertion logic which can reduce reusability, readability and thereby obscure the specific verification intention of tests.

To subdue this special smell several patterns and refactorings are available to acquaint the test code with the DRY principle.



 

grep Is A Beautiful Tool

Linux Today  Mon, 07/14/2008 - 20:00

Eric Wendelin's Blog: "Global Regular Expression Print is a staple of every command-line user’s toolbox.

As with find, it derives a lot of power from being combined with other tools and can increase your productivity significantly."



 

PHPImpact Blog: TDD with Symfony: The first test always fails

PHPDeveloper.org  Wed, 07/02/2008 - 09:33

On the PHP::Impact blog, Federico Cargnelutti has posted about test-driven design, specifically with the Symfony framework.



 

Community News: UNA Editor Screencast - PHP integration

PHPDeveloper.org  Fri, 06/27/2008 - 12:07

John De Goes (of N-Brain) let us know about a screencast he's posted on Vimeo of how he's set up the UNA Editor (Personal Edition - now free!) to work with PHP.



 

Detecting URLs with PCRE - Kore Nordmann

Planet PHP  Sat, 06/21/2008 - 12:37

Form time to time I experience the issue that I should detect URLs in some text, while neither the URLs are standard conform (regarding the used characters), nor the URLs are strictly separated from other stuff by whitespaces or something.

Now Derick asked me to provide him with a regular expression for that, and I finally wrote some, which should work in most cases...



 

Ken Guest's Blog: Validation in Depth - a retort to using just r...

PHPDeveloper.org  Tue, 05/27/2008 - 07:58

Ken Guest, in a response to another post from a different blogger, has posted some of his own validation replacements for the regular expression method the other blogger chose.



 

Bash Regular Expressions

Linux Journal - The Original Magazine of the Linux Community  Mon, 05/26/2008 - 10:48

When working with regular expressions in a shell script the norm is to use grep or sed or some other external command/program.

Since version 3 of bash (released in 2004) there is another option: bash's built-in regular expression comparison operator "=~".

read more