1) correct url resolution for local files
2) escapoed lmeasure command