Added case insensitivity in preg calls