unusual regex expression

General discussions related to php

Moderators: macek, egami, gesf

Post Reply
php-forum Fan User
php-forum Fan User
Posts: 973
Joined: Mon Oct 01, 2012 12:32 pm

Re: unusual regex expression

Post by seandisanti » Wed Oct 03, 2012 8:44 am

i usually have a hard time with regex, but this one looks straightforward. (.*) says to capture all sequential iteration of a pattern, in this case no pattern is specified so it will return everything. (:) means to capture just that character, and then back to another (.*). i believe that the pattern you've listed would return the same result as a single (.*)

Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 1 guest