in reply to Re^4: Stripping HTML tags efficiently
in thread Stripping HTML tags efficiently
perl -le '$d = "<moose>elk</moose>"; $p = qr/<.*?>/; $d =~ s/$p/" " x length $1/ge; print $d'
The is even simpler than what I suggested previously:
But once again, one of the HTML parsers may do a better job at this.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^6: Stripping HTML tags efficiently
by agynr (Acolyte) on Dec 11, 2004 at 10:53 UTC |