RegEx inside parseURLs method is executed only once instead of two times : fixes first match not found where there is only one match.
Better string cleanup html/xml entities as suggested by markoscalderon.