[Tex/LaTex] How to put keywords into abstract in elsarticle

elsarticlekeywords

I am really new to LaTeX. I am preparing a journal article in Tex Studio. I downloaded TexLive as well and am using it. Problem is \begin{keywords) returns unrecognized command.

\end{abstract}
\begin{keywords}
\end{keywords}
\end{frontmatter}
\maketitle
\date{today}
\newpage

How do I go about sorting this out? Thanks.

Best Answer

You can proceed using the keyword (not keywords) environment:

\documentclass[5p,number,preprint,times]{elsarticle}
% include here any package you may need
\begin{document}

\begin{abstract}
My wonderful abstract
\end{abstract}

\begin{keyword}Something \sep%
    Something else
\end{keyword}

\begin{frontmatter}
\title{The title of my beautiful article}

\author[unilu]{My name\corref{cor1}}
\ead{my.name@tex.sx}

\cortext[cor1]{Corresponding author. Tel.: (+111) 11 11 11.}
\address[myuni]{University of Somewhere}

\date{Received: date / Accepted: date}
% The correct dates will be entered by the editor
\end{frontmatter}


% == == == == == == == == == == == == == == ==
% Introduction
% == == == == == == == == == == == == == == ==
\section{Introduction}
\label{sec:intro}

\end{document}

The result:

enter image description here