[MPIR-279] Wrong hyperlinks on index and modules page

* Logic adapted from the DefaultSiteTool which builds <menu ref="modules" />
  The behavior now completely resembles the menu and the breadcrumb links
* Thanks to Stuart McCulloch and Grzegorz Slowikowski for helping out and testing

git-svn-id: https://svn.apache.org/repos/asf/maven/plugins/trunk@1639526 13f79535-47bb-0310-9956-ffa450edef68