Add URL replacement function.
Fix bugs on matching subtitle.