Adapt elements2textnl to accept replacement string