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.

So I'm trying out this code from here, but I keep getting this image: enter image description here What is happening? I copy-and-pasted the code.

share|improve this question
    
Please be more specific. Which code did you copy and paste? The string hrule (in lowercase) doesn't appear on the linked site. –  Caramdir Apr 2 '11 at 5:09
    
@Caramdir -- sorry, I changed it to hrule because it wasn't working. But I copy and pasted the "University of Beer" stuff –  wrongusername Apr 2 '11 at 5:10

1 Answer 1

up vote 4 down vote accepted

You forgot the third line

\documentclass[pdftex,12pt,a4paper]{report}
\usepackage[pdftex]{graphicx}
\newcommand{\HRule}{\rule{\linewidth}{0.5mm}}
\begin{document}
\begin{titlepage}

\begin{center}
%\includegraphics[width=0.15\textwidth]{./logo}\\[1cm]    

\textsc{\LARGE University of Beer}\\[1.5cm]
\textsc{\Large Final year project}\\[0.5cm]

% Title
\HRule \\[0.4cm]
{ \huge \bfseries Lager brewing techniques}\\[0.4cm]

\HRule \\[1.5cm]

% Author and supervisor
\begin{minipage}{0.4\textwidth}
\begin{flushleft} \large
\emph{Author:}\\
John \textsc{Smith}
\end{flushleft}
\end{minipage}
\begin{minipage}{0.4\textwidth}
\begin{flushright} \large
\emph{Supervisor:} \\
Dr.~Mark \textsc{Brown}
\end{flushright}
\end{minipage}

\vfill
% Bottom of the page
{\large \today}
\end{center}
\end{titlepage} 

\end{document} 

enter image description here

share|improve this answer
    
The option pdftex to \documentclass and to the graphicx package is unnecessary. To say it more clearly, it must never be given, with an up-to-date TeX environment. –  egreg Apr 2 '11 at 9:31
1  
@egreg I keep the OP's code intact from the link but I agree with you –  Alain Matthes Apr 2 '11 at 9:42

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.