Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm new to StackExchange!

I have this document:

\documentclass[a4paper,12pt,oneside,italian]{book}
\usepackage[utf8]{inputenc}
\usepackage{url}

\begin{document}

Questa è una citazione \cite{Citation}.

\bibliographystyle{plain}
\bibliography{biblio}
\end{document}

And this bibliography:

@misc{Citation,
author = "Daniele Vietri and Francesca Castelli",
title = "M-commerce in Italia",
howpublished = {\url{http://www.dblog.it/ecommerce/}},
year = {2012},
note = {[accesso: Marzo 2013]}
}

Why do I get the following output? It's making me crazy...

enter image description here

I would like to have a comma in place of "and".

And why the first letter of the word "Italia" in the title becomes lower-case?

share|improve this question
    
Welcome to TeX.sx! –  Torbjørn T. Apr 11 '13 at 11:22
2  
For the last question, add braces around the I ({I}talia), see tex.stackexchange.com/questions/10772/… –  Torbjørn T. Apr 11 '13 at 11:24
    
@Torbjørn I did not expect an answer so quickly, thank you! Your solution for the title works perfectly. –  Danielitos Apr 11 '13 at 12:47

3 Answers 3

up vote 2 down vote accepted

You are specifying

\bibliographystyle{plain}

which in turn specifies that lists of names should be formatted by this readable bit of code:

FUNCTION {format.names}
{ 's :=
  #1 'nameptr :=
  s num.names$ 'numnames :=
  numnames 'namesleft :=
    { namesleft #0 > }
    { s nameptr "{ff~}{vv~}{ll}{, jj}" format.name$ 't :=
      nameptr #1 >
        { namesleft #1 >
            { ", " * t * }
            { numnames #2 >
                { "," * }
                'skip$
              if$
              t "others" =
                { " et~al." * }
                { " and " * t * }
              if$
            }
          if$
        }
        't
      if$
      nameptr #1 + 'nameptr :=
      namesleft #1 - 'namesleft :=
    }
  while$
}

somewhere in the middle of that you will see it adds , or and or et al depending on the number of names left in the list.

You could tinker with that, although you should not change the default file, or more easily find another bibtex style that does what you want. (perhaps use the makebst package to make one). You need to decide what you want to do for lists of length 0,1,2,3 and more than N for some N.

You want a, b not a and b but what do you want for a list of three, the normal choices are either a, b, and c or a, b and c but perhaps you want a, b, c (If you do want that you can just change and in a copy of the above to , I think.

share|improve this answer
    
I finally solved using a different style (ama.bst) which does exactly what I wanted, even with more than 2 names (a, b, c). Thank you very much for the tip! –  Danielitos Apr 11 '13 at 13:01

My answer is based on a previous question and answer, and it uses at its core the biblatex package (which provides a powerful replacement to the classic LaTeX and bibTeX duo).

\documentclass[a4paper,12pt,oneside,italian]{article}
\usepackage[utf8]{inputenc}
\usepackage{biblatex}
\usepackage{hyperref}

\addbibresource{biblio}
\renewcommand*{\finalnamedelim}{\addcomma\space}

\begin{document}

Questa è una citazione \cite{Citation}.

\printbibliography

\end{document}

Additional stuff. Together with the babel and csquotes packages you should get a decent support for Italian conventions. For example, if you comment the line where we redefine the \finalnamedelim command, you will get the Italian "e" in place of the English "and". Also, the command \printbibliography automatically prints a heading for the bibliography which is language dependent, in this case "Riferimenti bibliograci", but you can give it the argument [heading={text}] to choose whatever you need.

Also, I used the hyperref package instead of the url package, because it creates actual hyperlinks (I think it loads the url package automatically).

share|improve this answer
1  
I had never used before biblatex so I preferred to simply try another style. Thanks anyway for your solution. –  Danielitos Apr 11 '13 at 13:14

Is there a good reason to want a, b instead of a and b (which is the standard)?

If so, you should find either a style that does that or make one yourself like David Carlise says, though there should be a really good reason to do that (and not just "I just like it that way"). Things in LaTeX are done for a very good reason, most of the times following what standards dictates.

A few comments on your bib entry:

  • Authors should be written Lastname, Names, i.e.:

    author = {Vietri, Daniele and Castelli, Francesca and Mozart, Wolfgang Amadeus}

  • Depending on the style, it will manage titles in different ways (i.e. capitalizing all letters, the first letter of a word, etc.). You should write the titltes in a consistent way. If you know that some word must have some capitalization (like Italy, IEEE, etc) you can force it like this:

    title = {M-commerce in {I}talia},

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.