remove [if endif] from text