Thank youfor your solution. It works very well. I just need to convert all my images which is now in pdf files to eps since I do not have them in eps format.
I found number of ways to do this at this post: http://tex.stackexchange.com/questions/20883/how-to-convert-pdf-to-eps And it worked very well. thanks again for your help --Nasser On 5/16/2015 3:27 AM, Radhakrishnan CV wrote:
On Sat, May 16, 2015 at 6:55 AM, Nasser M. Abbasi <[email protected]> wrote:Currently I use svg graphics for all images since it looks better than png on the web. Here is a typical latex file. I use pdf version of the image for pdflatex and use the svg version for htlatex. I convert the pdf to svg using the program pdf2svg which works much better thank inkscape I found. ------------------------------- \documentclass[12pt]{article} \usepackage{graphicx} \begin{document} \ifdefined\HCode \includegraphics[width=0.5\paperwidth]{p.svg} \else \includegraphics[width=0.5\paperwidth]{p.pdf} \fi \end{document} ---------------------------You may kindly change the above to the following: documentclass[12pt]{article} \usepackage{graphicx} \begin{document} \makeatletter \Configure{graphics*} {eps} {\Picture[pict]{\csname Gin@base\endcsname.svg width="\expandafter\the\csname Gin@req@width\endcsname" height="\expandafter\the\csname Gin@req@height\endcsname" }% } \makeatother \ifdefined\HCode \includegraphics[width=0.5\paperwidth]{gr1.eps} \else \includegraphics[width=0.5\paperwidth]{gr1.pdf} \fi \end{document} I got the following output for graphics inclusion part: <p class="noindent"> <img src="gr1.svg" alt="pict" width="307.14749pt" height="307.26057pt" > </p> Hope this is what you have been looking for. TeX4ht needs .eps format of the figure since it works with dvips graphics driver and hence cannot accept any other graphics file format. Best regards
