0

I have a table which contains footnotes. I want these footnotes to appear at the end of the page, but nothing is displaying. However footnote numbers are there in the table. I have tried doing this but it didn't work for me.

This is my table code:

\documentclass{book}                                                                                                 

\usepackage{booktabs}                                                                                                

\usepackage{url}                                                                                                     
\usepackage{tabularx}                                                                                                
\usepackage{ragged2e}                                                                                                
\usepackage{makecell}                                                                                                

\begin{document}                                                                                                     

\begin{table}[hbtp]                                                                                                  
    \centering                                                                                                       
    \begin{tabularx}{\textwidth}{ c >{\RaggedRight}X }                                                               
        \toprule                                                                                                     
        \textbf{$e_\#$} & \makecell[cc]{\textbf{Description}} \\                                                     
        \midrule                                                                                                     
        1 & Cathedral of Notre Dame fire during restorations work\footnote{https://www.nytimes.com/es/2019/04/15/not\
re-dame-incendio/}.  \\ \addlinespace                                                                                
        2 & Beginning of `Semana Santa' vacances in Madrid\footnote{https://www.abc.es/espana/madrid/abci-semana-san\
ta-2019-procesiones-madrid-recorrido-horario-y-programa-201904110105\_noticia.html}. \\ \addlinespace                
        3 & World Art Day\footnote{http://www.aimdigital.com.ar/15-de-abril-dia-mundial-del-arte/}. \\ \addlinespace 
        4 & Max Pradera, an Spanish journalist, posted an unfortunate comment about Almudena Cathedral and Notre Dam\
e\footnote{https://www.abc.es/internacional/abci-pradera-pudiendose-haber-quemado-almudena-y-quema-notre-dame-201904\
160310\_noticia.html}. \\ \addlinespace                                                                              
        5 & Premiere of the last season of Game of Thrones\footnote{https://www.elmundo.es/television/2019/04/09/5ca\
c665ffc6c8393168b46eb.html}. \\                                                                                      
        \bottomrule                                                                                                  
    \end{tabularx}                                                                                                   
   \caption{April 15th 2019 most important events}                                                                   
    \label{tab:april-events}                                                                                         
\end{table}                                                                                                          

\end{document}
7
  • What packages and documentclass do you use? Just including tabularx does not let me compile your table. Could you include a minimal working example (MWE)?
    – Taunch
    May 24, 2019 at 9:11
  • @Taunch Sorry, I didn't know what to post so I updated my question with my whole main.tex
    – Luiscri
    May 24, 2019 at 9:35
  • OK, that was a bit too much ;) I've edited your question so that the example remains "minimal", meaning that only things related to your question (= the table) remain. (The code would have also not compiled, since you seem to use a custom ´thesis.sty´)
    – Taunch
    May 24, 2019 at 9:50
  • @Taunch Right, I also added it to the question (I may have provided again too much)
    – Luiscri
    May 24, 2019 at 9:57
  • Ah, you really don't need that now, the new MWE does not rely on it anymore and compiles just fine on its own.
    – Taunch
    May 24, 2019 at 10:03

2 Answers 2

1

You could use the footnote package and exploit its \makesavenoteenv:

\documentclass{book}
\usepackage{booktabs}
\usepackage[hyphens]{url}
\usepackage{tabularx}
\usepackage{ragged2e}

\usepackage{footnote}
\makesavenoteenv{table}
\newcounter{step}
\newcommand\step{\stepcounter{step}\thestep}
\begin{document}

\begin{table}
  \centering  
  \caption{April 15th 2019 most important events}
  \label{tab:april-events}
  \begin{tabularx}{\textwidth}{ c >{\RaggedRight}X }
    \toprule
      \textbf{$e_\#$} & \centering\textbf{Description} \tabularnewline
    \midrule
      \step & Cathedral of Notre Dame fire during restorations
      work\footnote{\url{https://www.nytimes.com/es/2019/04/15/notre-dame-incendio/}}. \\
    \addlinespace
      \step & Beginning of `Semana Santa' vacances in
      Madrid\footnote{\url{https://www.abc.es/espana/madrid/abci-semana-santa-2019-procesiones-madrid-recorrido-horario-y-programa-201904110105_noticia.html}}. \\
    \addlinespace
      \step & World Art Day\footnote{\url{http://www.aimdigital.com.ar/15-de-abril-dia-mundial-del-arte/}}. \\
    \addlinespace
      \step & Max Pradera, an Spanish journalist, posted an unfortunate comment
      about Almudena Cathedral and Notre
      Dame\footnote{\url{https://www.abc.es/internacional/abci-pradera-pudiendose-haber-quemado-almudena-y-quema-notre-dame-201904160310_noticia.html}}. \\
    \addlinespace
      \step & Premiere of the last season of Game of Thrones\footnote{\url{https://www.elmundo.es/television/2019/04/09/5cac665ffc6c8393168b46eb.html}}. \\
    \bottomrule
  \end{tabularx}
\end{table}
  
\end{document}

enter image description here

0

So, I've played around a bit and the quick fix seems to be using parnotes and a dirty hack to create new lines. It's not the most elegant solution, but it hopefully does what you want it to do.

\documentclass{book}                                                                                                 

\usepackage{booktabs}                                                                                                
\usepackage{tabularx}                                                                                                
\usepackage{ragged2e}                                                                                                
\usepackage{makecell}                                                                                                

\usepackage{parnotes} % for footnotes in tables                                                                      

\begin{document}                                                                                                     

\begin{table}[hbtp]                                                                                                  
    \centering                                                                                                       
    \begin{tabularx}{\textwidth}{ c >{\RaggedRight}X }                                                               
      \toprule                                                                                                       
      \textbf{$e_\#$} & \makecell[cc]{\textbf{Description}} \\                                                       
      \midrule                                                                                                       
      1 & Cathedral of Notre Dame fire during restorations work\parnote{https://www.nytimes.com/es/2019/04/15/notre-\
dame-incendio/\newline % <--- dirty hack for new lines                                                               
      }.  \\ \addlinespace                                                                                           
      2 & Beginning of `Semana Santa' vacances in Madrid\parnote{https://www.abc.es/espana/madrid/abci-semana-santa-\
2019-procesiones-madrid-recorrido-horario-y-programa-201904110105\_noticia.html\newline}. \\ \addlinespace           
      3 & World Art Day\parnote{http://www.aimdigital.com.ar/15-de-abril-dia-mundial-del-arte/\newline}. \\ \addline\
space                                                                                                                
      4 & Max Pradera, an Spanish journalist, posted an unfortunate comment about Almudena Cathedral and Notre Dame\\
parnote{https://www.abc.es/internacional/abci-pradera-pudiendose-haber-quemado-almudena-y-quema-notre-dame-201904160\
310\_noticia.html\newline}. \\ \addlinespace                                                                         
      5 & Premiere of the last season of Game of Thrones\parnote{https://www.elmundo.es/television/2019/04/09/5cac66\
5ffc6c8393168b46eb.html}. \\                                                                                         
      \bottomrule                                                                                                    
    \end{tabularx}                                                                                                   
    \caption{April 15th 2019 most important events}                                                                  
    \label{tab:april-events}                                                                                         
  \end{table}                                                                                                        
  \parnotes % actually create the footnotes, can also be placed inside table, but behaviour different                

\end{document} 

Output

It would also be possible to create a \newcommand to encompass the \newlines, depending on how often you need this.

1
  • Unfortunately your solution (also after removing errors in table's code) doesn't work as OP expected. Footnotes aren't on the bottom of page but below table. However, it works in tabularx correctly what \footnote doesn't.
    – Zarko
    Jun 18, 2020 at 6:47

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .