[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ale] Foolish Perl Question



I wrote a small perl script to clean up some output from another 
application.  This data is then imported into a SQL database.

One of the most tedious ascpect is trying to filter out all of the 
"font" markers in the format of [font color = blue], [font color = red] 
, etc.

What I would like to do is come up with something that allows a 
wildcard.  For example, right now:

$line[7] =~ s/\[font color \=red\]//g;

will strip out all of the "[font color = red]"

What I would like to do is identify anything that starts with "[font" , 
and strip everything until the next "]".  So, if the character "*" did 
that, it would look something like:

$line[7]=~s/\[font*]//g;

Any ideas?

Regards - Bob Kruger


---
This message has been sent through the ALE general discussion list.
See http://www.ale.org/mailing-lists.shtml for more info. Problems should be 
sent to listmaster at ale dot org.