I am using the package breakurl to avoid the urls to be out of the document. I am using TexMaker under GNU/Linux (concretely Debian wheezy), and generating a PDF file.
The package works quite well except in two cases:
In the first case, the call to the \burl command is in a \footnote, in the second one, in a list in an appendix. The problem seems to be with the issue of hyphens not being interpreted as break points. I followed the instructions at http://texdoc.net/texmf-dist/doc/latex/breakurl/breakurl.pdf and try with the option \usepackage[hyphenbreaks]{breakurl}, but it does not work. I also tried the option hyphenbreaks, but it doesn't work neither (and it breaks the format in other places). Do you have any idea why this could be happening?
Thank you very much,
David
P.S: Here is a Minimum Working Example, as suggested by @Mico:
\documentclass[a4paper,12pt]{report}
\usepackage[margin=2.5cm]{geometry}
\usepackage[british]{babel}
\usepackage[utf8]{inputenc}
\usepackage[usenames,dvipsnames]{color}
\usepackage{setspace}
\usepackage{titlepic}
\usepackage{graphicx}
\usepackage[nodayofweek]{datetime}
\usepackage{float}
\usepackage{booktabs}
\usepackage{tablefootnote}
\usepackage{multirow}
\usepackage{titlesec}
\setcounter{secnumdepth}{4}
\titleformat{\paragraph}
{\normalfont\normalsize\bfseries}{\theparagraph}{1em}{}
\titlespacing*{\paragraph}
{0pt}{3.25ex plus 1ex minus .2ex}{1.5ex plus .2ex}
\usepackage{csquotes}
\usepackage[style=apa, backend=biber]{biblatex}
\DeclareLanguageMapping{british}{british-apa}
\addbibresource{bibliography.bib}
% Added for long urls
\usepackage{hyperref}
%\usepackage[hyphens]{url}
\usepackage[hyphenbreaks]{breakurl}
\usepackage[super]{nth}
\usepackage[gen]{eurosym}
\begin{document}
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis commodo leo quis gravida tempor. Suspendisse convallis nibh in nisl ultrices porttitor. Etiam mattis mauris eget lectus ultricies, ut laoreet leo aliquet. Sed justo quam, ornare nec ex eget, consequat feugiat purus. Donec ultricies metus quis fermentum feugiat. Proin vehicula eu ex vel laoreet. Nullam nec dictum ante\footnote{\label{footnote-dcne2014} \url{http://camp.drupalne.org/session/drupal-case-commons-based-peer-production}} \footnote{\url{https://amsterdam2014.drupal.org/bof/study-drupal-community-academia-what-has-been-said-and-what-can-we-learn}}.
\newpage
%% Appendixes
\appendix
\chapter{List of modules, published materials and presentations}
\begin{itemize}
\item Presentations:
\begin{itemize}
\item ``Drupal as a case of Commons-based Peer Production", DrupalCamp North East (Sunderland, 25/07/2014 - \url{http://camp.drupalne.org/session/drupal-case-commons-based-peer-production}). Slides available at \url{http://www.slideshare.net/drozas/drupal-cbpp-dcne14}
\end{itemize}
\end{itemize}
\end{document}
P.S.2: Here is the MWE with the changes suggested by @egreg. In this case, there seems to be a clash with the packages: ! LaTeX Error: Option clash for package url.
\documentclass[a4paper,12pt]{report}
\usepackage[margin=2.5cm]{geometry}
\usepackage[british]{babel}
\usepackage[utf8]{inputenc}
\usepackage[usenames,dvipsnames]{color}
\usepackage{setspace}
\usepackage{titlepic}
\usepackage{graphicx}
\usepackage[nodayofweek]{datetime}
\usepackage{float}
\usepackage{booktabs}
\usepackage{tablefootnote}
\usepackage{multirow}
\usepackage{titlesec}
\setcounter{secnumdepth}{4}
\titleformat{\paragraph}
{\normalfont\normalsize\bfseries}{\theparagraph}{1em}{}
\titlespacing*{\paragraph}
{0pt}{3.25ex plus 1ex minus .2ex}{1.5ex plus .2ex}
\usepackage{csquotes}
\usepackage[style=apa, backend=biber]{biblatex}
\DeclareLanguageMapping{british}{british-apa}
\addbibresource{bibliography.bib}
% Added for long urls
\usepackage[hyphens]{url}
\usepackage{hyperref}
%\usepackage[hyphenbreaks]{breakurl}
\usepackage[super]{nth}
\usepackage[gen]{eurosym}
\begin{document}
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis commodo leo quis gravida tempor. Suspendisse convallis nibh in nisl ultrices porttitor. Etiam mattis mauris eget lectus ultricies, ut laoreet leo aliquet. Sed justo quam, ornare nec ex eget, consequat feugiat purus. Donec ultricies metus quis fermentum feugiat. Proin vehicula eu ex vel laoreet. Nullam nec dictum ante\footnote{\label{footnote-dcne2014} \url{http://camp.drupalne.org/session/drupal-case-commons-based-peer-production}} \footnote{\url{https://amsterdam2014.drupal.org/bof/study-drupal-community-academia-what-has-been-said-and-what-can-we-learn}}.
\newpage
%% Appendixes
\appendix
\chapter{List of modules, published materials and presentations}
\begin{itemize}
\item Presentations:
\begin{itemize}
\item ``Drupal as a case of Commons-based Peer Production", DrupalCamp North East (Sunderland, 25/07/2014 - \url{http://camp.drupalne.org/session/drupal-case-commons-based-peer-production}). Slides available at \url{http://www.slideshare.net/drozas/drupal-cbpp-dcne14}
\end{itemize}
\end{itemize}
\end{document}
Best Answer
The first thing to note is that
breakurl
is useful only if the document is processed withlatex+dvips+ps2pdf
in order to produce a PDF file. Ifpdflatex
is used, there's no point in loadingbreakurl
instead ofurl
.Second: the package
hyperref
requiresurl
, so this package should be loaded beforehyperref
if we want to add options to it.Third: also
biblatex
requiresurl
; so, again,url
must be called beforebiblatex
if options are to be passed to it.Fourth:
biblatex
, for unknown reasons, changes the default URL style.Here's the minimal example which you can base your document on:
I'm not really sure whether long URLs in footnotes are really useful for the reader. A list of URLs at the end of the document might be better, leaving in the footnote just a pointer (that can still become a hyperlink).