When using hyperref
's pagebackref
, the same page is listed multiple times, if the reference appears on that particular page more than once.
e.g.:
A. Hindle, M. Godfrey, and R. Holt. Software process recovery using
recovered unified process views. In Software Maintenance (ICSM), 2010
IEEE International Conference on, pages 1–10. IEEE, 2010. doi:
10.1109/ICSM.2010.5609670. (pages 3, 3, 6, 6, 6, 6).
How do I remove double entries from the list?
SIDENOTE:
As you might have spotted, I applied a "page"/"pages" addition (from here) which comes down to:
\renewcommand*{\backreflastsep}{, }
\renewcommand*{\backreftwosep}{, }
\renewcommand*{\backref}[1]{}
\renewcommand*{\backrefalt}[4]{%
\ifcase #1 %
No citations.% use \relax if you do not want the "No citations" message
\or
(page #4).%
\else
(pages #4).%
\fi%
}
Without this addition, citations also appear multiple times.
Best Answer
Simply replace
#4
with#2
in your redefinition of the\backrefalt
macro: As the backref manual explains,\backrefalt
takes four arguments:So
#2
is exactly what you need.Minimal test case: