allow viewdocs.io style links in an index.md (which don't have the extension) which can also work inside the wiki using the file-extension attribute; also fix relative links when viewing a folder or the index.md/readme.md file; remove the file if it has an extension inside if we're linking to a relative link