improved regex for compatibility with mediawiki-systems