[thelist] php pattern matching

Bob Meetin bobm at dottedi.biz
Sun Feb 13 11:39:18 CST 2011

Imagine some date formatting like the following:

{12345|tom smith|whatever title} oh what a beautiful morning, yadda yadda

The curly brackets will be used to contain some particular information 
always the same structure. Anything external to whatever is contained 
within the curly brackets {} is descriptive text.  The descriptive text 
may be a long passage, many lines.

What is the PHP syntax used to:

1) Extract anything between the curly brackets into a simple string?
2) Remove the part within the curly brackets leaving the descriptive text?

-Thx, Bob

More information about the thelist mailing list