A framework for translating web DOMs from template translations