Quote:
Originally Posted by Ginnia
Thanks for responding, Manichean. If I could understand what the ".+" and the "[^_]+" means, it would help me noodle thru this I think.
|
".+" means "one or more of any character". "[^_]+" means "one or more of anything except an underscore."
Decoding this, the + means "one or more of the pattern preceding it". In the first case the pattern is ".", which means any character. In the second case the pattern is "[^_]", which is a "character class" pattern meaning "any character that is not an underscore". If you leave the "^" out of the character class, then it would mean "any character that is an underscore", or exactly the same as "_+".
The tutorial gives more information on character classes.