How to do a menu
where __TOC__ is standard MediaWiki code to get the standard table of contents. This could be anything. The div is just ot hide the "[hide]" button that is usually displayed with MediaWIki TOCs.
Most of the content below is created by transcluding the page(like using a template, but requires a leading : to work).
Try making the page smaller to see what happens.