fix url substr