Finalized code for index page

This is the final code ( so far anyway, changes can always happen).