Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Spidy's scratchpad

by Spidy (Chaplain)
on Aug 26, 2004 at 03:27 UTC ( #385897=scratchpad: print w/ replies, xml ) Need Help??

## sample input: h1. BA1 h2. Sample Historical Item Headline * 2005-06-14 * 2 * thumbnail.jpg * main-image.png * Photo courtesy * Button text goes here... This is the text displayed in the buttons i +n the bottom screen grid Main content goes here. Paragraph breaks will be rendered appropriatel +y Intrinsicly e-enable technically sound services before optimal benefit +s. Distinctively visualize cross-unit alignments via magnetic intelle +ctual capital. ---- ### sample output: <item headline="Sample Historical Item Headline" date="2005-06-14" typ +e="2" preview="thumbnail.jpg" link="main-image.jpg" courtesy="Photo c +ourtesy"> <intro>Button text goes here... This is the text displayed in the +buttons in the bottom screen grid</intro> <body><![CDATA[<p>Continually empower reliable web services ...</p +> <p>Seamlessly formulate 2.0 process improvements ...</p>]]></b +ody> </item>

Current Regex Progress:

h1\. (.+)\r\rh2\. (.+)\r\r\* (.+)\r\* (.+)\r\* (.+)\r\* (.+)\r\* (.+)\ +r\* (.+)\r

However, I cannot figure out how to use this regular expression to retrieve each of the paragraphs of text - so that I can wrap them into >p< tags within the output XML.

Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (12)
As of 2014-09-23 12:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (219 votes), past polls