Dynamic LaTeX with CodeCogs

Elisha Peterson, United States Military Academy

Abstract: This note describes how to generate LaTeX images in an html document using a web service… all it takes is inserting the LaTeX into an image link.

Sometimes when writing your own webpages, it's quite a pain to get LaTeX to show up on your website. There are a number of ways to do this. (On this Wikidot site, the LaTeX is generated from the wiki markup.) Without that option, using the http://www.codecogs.com web service is one of the easiest and quickest techniques I have used.

Example: $2^nx^i$ is generated by linking to the image http://www.codecogs.com/gif.latex?2^nx^i, which in html looks like

````<image src="http://www.codecogs.com/gif.latex?2^nx^i"></image>`
```

This also works to generate .png, .swf, and .pdf images. Here is the flash example (.swf), which can be resized beautifully:
``````<embed width="600" height="100" src="http://www.codecogs.com/swf.latex?1+sin(x)" quality="high"
pluginspage="http://www.macromedia.com/go/getflashplayer" align="top" scale="showall" wmode="window" devicefont="false"