Categories


Loading feed
Loading feed
Loading feed

Stefan Esser Finds Holes in Most preg_match() Filters

Stefan Esser posted on his blog today about a problem he has discovered in code that he was auditing recently. The problem he discusses is in the way regular expressions are written and the modifiers that may or may not be applied.

PHP and MySQL By Example - Sample Chapter

Prentice Hall recently released “PHP and MySQL by Example”, written by Ellie Quigley. They are so proud of this title that they sent us over the sample chapter, “Regular Expressions and Pattern Matching” to share with you. Click on inside, I’ll share.

Having Trouble Getting Your REGEX Mojo Working? Here is an Article That Will Help.

Man I hate REGEX. Not for what it does, it’s a powerful weapon. It’s part sniper rifle, part bazooka and extremely useful in some situations. As powerful as it is though, it is a pain to write a good REGEX query; especially when you only do it occasionally. Thankfully, Bernard Peh and the gang over at WebProNews have released a primer for REGEX in PHP that makes it a little less painful to work with.

Using Perl Compatible Regular Expressions with PHP

This tutorial will show you how to replace, match and otherwise manipulate strings within a target by using regular expressions. A regular expression is used for complex string manipulation in PHP and can be very handy when one needs to validate a value, grab information from an outside source, locate information within a page, or replace all of one specified string or value with another. It can be a great timesaver by doing all of the "find and replace" work that one would otherwise have to do by hand. Regular Expressions can also take care of much of the double checking that one often does when, for example, making sure that e-mail address submitted to a listserv are correct, or that URLs submitted for links are in the proper format.