in reply to Regex not working
Why do you use the 'g' modifier on the regex? In scalar context this remembers the last search in that variable and continues from there. Useful for searching multiple occurences of a regex pattern, not useful if you want to have the same result each time you search.
|
|---|