Update index.php

More automatization on which file type system do you want!! In main files and thumbnails.
**Note: Will fix the problem with including only one file type in application.