I have a link to a URL looking like this
http://www.abc.de/~doo/bar/foobar.htm
As you can see, it contains a ~. I tried changing the link to
http://www.abc.de/\~doo/bar/foobar.htm
However, the ~ goes over the d, something like ñ. How can I display the tilde properly?
That is the file entry
@webpage{rajapakse2008,
Author = {Rajapakse, Damith C.},
Date-Added = {2018-01-25 14:31:33 +0000},
Date-Modified = {2018-05-03 21:05:13 +0000},
Lastchecked = {25.01.2018},
Month = {04},
Title = {Fragmentation of Mobile Applications},
Url = {http://www.comp.nus.edu.sg/\~damithch/df/device-fragmentation.htm},
Year = {2008},
Bdsk-Url-1 = {http://www.comp.nus.edu.sg/~damithch/df/device-fragmentation.htm}}
.bibentry? If you indeed usebiblatex, you should use theurlfield, that field is a special verbatim field where special characters need not (and should not!) be escaped. If you use BibTeX and must resort tonoteorhowpublishedyou should look into wrapping your URLs in\url{...}. – moewe May 03 '18 at 21:15cite,natbib,biblatex, ...) and which style you use. The handling of URLs differs betweenbiblatex(where things are largely handled uniformly) and BibTeX styles (with vastly varying degrees of support for URLs). Please consider adding a full MWE/MWEB that shows this. – moewe May 03 '18 at 21:21natbibwith a modifiedagsm, namely this one: https://gist.github.com/moewew/6c65c256c9420d64f3b264c0a78774c0 its yours :) – four-eyes May 03 '18 at 21:26\renewcommand{\harvardurl}[1]{\textbf{URL:} \url{#1}}(https://tex.stackexchange.com/q/9445/35864) – moewe May 03 '18 at 21:29\renewcommand{\harvardurl}[1]{[Online] URL: \textit{#1}}– four-eyes May 03 '18 at 21:32\renewcommand{\harvardurl}[1]{[Online] URL: \url{#1}}then (if that produces an error you may have to load thehyperreforurlpackage - depending on whether you like links in general or not). – moewe May 03 '18 at 21:36\urlin there. I use\textasciitildeas suggested by Phelype Oleinik - that does the trick somewhat – four-eyes May 03 '18 at 21:44\url? That command really is the simplest way to tell LaTeX that you are typesetting a URL. URLs require special treatment, so LaTeX normally botches them badly unless specifically told to handle it otherwise. If you don't like the fact thaturl/hyperrefprint URLs in typewriter font by default you can use\urlstyleto change that. – moewe May 03 '18 at 21:49