encode URL

Encoding special characters in the "loc" element to correct the EntityRef: expecting ';' problem