I don't know about automatically documenting a script, but if you document your code with POD there are all sorts of utilities that can convert it into HTML code for you.
You can find out more about it here and get more detailed info about it here.
Don't think there's anything that works in quite the same way though..
Comment