Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

more selective gsr

Status
Not open for further replies.

Wolfie7873

Technical User
Joined
Jan 15, 2004
Messages
94
Location
US
so in making the move from straight HTML to HTML with CSS, I have a lot of 'stuff' that essentially needs the markup completely removed so that I can have a cleaner slate to add the style classes too. This worked pretty well, where $string holds the contents of the html file.

Code:
$string =~ s/<.*?>//g;

This stripped out ALL of the markup. Now, I want to modify that statement a bit so that I can leave behind a few select tags that go to the perl processor. So if I have a tag like
Code:
<perl blahblah> Yadda Yadda </perl>
, I want that markup to stay, but all the rest of it to go. I'm really new at this, and I'm not sure of the simplest way to proceed. Any ideas?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top