Javascript-generated Table of Contents

worgtsone @ hush.com, 30.08.2011



please stand by while generating table of contents...

What's this?

Work in progress.

I found that pdfs are not totally satisfying if you want to distribute text and pictures for nothing over the web. Most people dunno how pictures are stolen easily; most people (me included) run in fear if they see that my pdflatex cuts every Umlaut into a letter and the umlaut dots.

So, its better to provide files as html, with some drawbacks:

How use it?

  1. Copy this file and rename it.
  2. Change title (between <title> and </title>).
  3. Change title (between <font size=+6> and </font>).
  4. Change address and date, between <font size=+4> and </font>).
  5. Erase old content, between <div id=content> and </div> <body>.
  6. Decide if you wish the hint ''toc -- top'' after each chapter. If not so, disable it in the first line of the script.
  7. Write new content.
    Do use h1 to h6 to break down the chapters.
    Do use pictures and tables as usual.
    DO NOT use <hr>. NOWHERE. The javascript at the end is confused by that.
  8. Upload file and pictures.
    Hint : If you called the file 'myfile.html', you may like to call the pictures myfile0001.jpg, myfile0002.jpg, myfile0003.jpg to avoid naming trouble on your webserver.

Further action

If you prefer to improve it, distribute it, change it, put it into a separate file or re-write it in any browser-compatible language : do so and enjoy.

end of document

To show off with its capabilites.