One of my students is writing a book in latex with book class. Everything is finished, but now he wants to insert two images in jpeg format as front and back covers, I am not able to insert these.
In my opinion you can create a new cover.tex file and put inside there the jpeg picture with the \includegraphics[scale=1]{.jpeg} command. Then at the main .tex file after \begin{document} you can put \input{cover.tex}.
I am sure it is another way also but this one is going to work.
@Prasanth: if you are only interested in getting the final PDF document with the front and back cover, you can always generate them as single pages (also with LaTeX or any other program), and then merge the three PDF documents (front cover - book content - back cover).
If you use George's solution, you have to be careful with page numbering.
Correct. In order to fix the page numbering you can use \pagenumbering{gobble} which remove the pagenumbering and reset also the numbering. But the solution of @Didac is also good....
@Prasant: pdftk is the one I use in Linux. In MacOS there is pdfjoin and you can also do it with the Preview application (cutting and pasting pages from one doc to another).
You can also use the pdfpages latex package (http://www.ctan.org/pkg/pdfpages) to insert external PDF documents in latex. Though I have never used it so I don't know how it deals with page numbering (you might need to do what @George mentioned).
@Prasanth: The first thing you should do is to convert the images to PDF. You can do this through several ways: (1) with Latex creating a document with one page that simply inserts the image you want, or (2) by "printing" the image to PDF (which many image viewers allow, or (3) using the "convert" tool to convert jpeg to pdf; just to name a few. Then you can merge the resulting PDFs.
@Prasanth, it seems my experience is a bit outdated. I found that now the most simple way to do what you want is to use the recently created package "pdfpages", see http://www.ctan.org/tex-archive/macros/latex/contrib/pdfpages/
I successfully added an EPS image as a cover background using the "eso-pic" package (http://www.ctan.org/pkg/eso-pic). You create a new command where title.eps is your background image (I made mine in Gimp to match the paper size):
Do NOT convert the image. If it's Jpeg it will stay Jpeg and not magically become a vector format just by throwing a PDF mantle around it. Every extra step has the potential to mess things up.
A cover is not part of the book (the title pages are). It is cardboard, not paper, has rather a different size including the spine and is best done as a separate file. It can be done in LaTeX of course, but in many cases a graphics program may be the better bet.
Even if not using them, the pages of e.g. "book on demand" offer good explanations of the niceties.