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

Re^2: Split tags and words nicely

by logie17 (Friar)
on Dec 28, 2006 at 21:04 UTC ( [id://592137]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    $a = q{<tag ref=1>Start<tag ref=2>and more</tag>and end</tag>};
    my @b;
    $a =~ s/(<\/?tag[^>]*>)(\w*)/push @b, ($1,$2)/eg;
    map {print $_,"\n"} @b;
    
  2. or download this
    <tag ref=1>
    Start
    ...
    </tag>
    and
    </tag>
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://592137]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (2)
As of 2024-04-20 11:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found