Fix external URLs in templates