I occurs to me that you could be trying to form URLs. In that situation, the url deal can take treatment of almost everything for you: More info on LaTeX packages can be found at the end of this tutorial inside the part Getting and applying LaTeX deals. Captions, labels http://latexonline.vefblog.net