texの罠その1 Referencesの中のURL
罠ってほどではないけどハマったとこをメモ
Referencesの中でURLを書くときに気をつけること
- '/'は\slashに直す
- URL を構成する他の文字は{}で区切る
- '~'や'_'のまえにも\を付ける
以下具体例
\begin{thebibliography}{40} \bibitem{1} hohogehogehoge hogehoge hoge https://www.owasp.org/index.php/Cross-site_Scripting_(XSS) \end{thebibliography}
が
\begin{thebibliography}{40} \bibitem{1} hohogehogehoge hogehoge hage https:\slash\slash{}www.owasp.\slash{}index.php\slash{}Cross-site\_Scripting\_(XSS) \end{thebibliography}
てなぐあい。特に、アンダースコアは分かりづらいし、pdfにしたときの被害がでかい。