How to write regex to handle multiple spaces? -


i need regex name of label. labels this:

lbl labelname 

the regex need return labelname. manged make this:

(?<=\slbl\s).+?(?=\s) 

this works fine long there 1 character between "lbl" , "labelname". if add 2 spaces or more spaces return spaces.

i tried (?<=\slbl\s+).+?(?=\s) doesn't work either.

does following regular expression work you?

lbl\s+([^\s]+) 

Comments

Popular posts from this blog

linux - Using a Cron Job to check if my mod_wsgi / apache server is running and restart -

actionscript 3 - TweenLite does not work with object -

jQuery Ajax Render Fragments OR Whole Page -