True. $name =~ s/\[No C-D\]\s*$//g; Only strips off the [No C-D] and any following white space at the end of line.
But, just think of the problems if there is a clan called [No C-D] :)
--agenthh
Blaine Kahle wrote:
On Sun, Mar 02, 2003 at 07:50:11PM -0800, agenthh wrote:
Works fine. But, no white space in front and no extra junk in back is also good. $name =~ s/\s*\[No C-D\].*\n//g; does the trick. e.g. "This is a dumb name [No C-D] blah!" would be shortened to "This is a dumb name".
The [No C-D] tag is prepended to the existing name, with no whitespace added. The substitution below is correct, assuming "[No C-D]" isn't part of someone's name; strip off the "g" at the end to be safe :)
_______________________________________________ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux

