Replace template with plain string