Fix: Mark DocumentationSearch::get_index_location() as static
Fix: Search error on autoregistered entities

Error: [Warning] array_combine() [function.array-combine]: Both
parameters should have at least 1 element

HandleRequest for submitted forms returns before the automatic
registration of modules is performed, so no entities can be found.
Fixed by moving  DocumentationService::load_automatic_registration();
to the top of the function
Fix: Search returns no results for auto-registered modules

Automatic registration sets the version to '' (empty). This breaks the
search as Lucene Search will return an Empty query object if a subquery
has an empty key.

Fix: register the modules as 'current' instead of ''. Setting the
version title to 'current' in DocumentViewer->getVersions() is now no
longer necessary.
Minor: add whitespace after comma in module/entity summary
Fix: no search results found on documentation homepage

On the homepage there are no searchedEntities nor searchedVersions
defined, so the searchForm creates empty hiddenfields. PerformSeach
creates subqueries for thes empty values resulting in the return of an
'Empty' query object.

Solution: do not create these fields when there are no entities/versions
Enhancement: allow for enabling/disabling advanced search

The advanced searchbox only really functions properly for multiple
entities if they all have similar versions. If not, it will let you
search on entity-version combinations that might not even exist, which
can get confusing..

In such cases optionally disabling it could be a solution, waiting for
a better solution (possibly
Fix: failing unit test (DocumentationViewerTest)

In testGetModulePagesShort() and testGetEntityPages() the pages in the
array are (getEntityPages() doesn't include index nor _images):
0 -> Sort
1 -> Submenu
2 -> Test
Revert "Fix: failing unit test (DocumentationViewerTest)"

This reverts commit aacc16c9793c7047cb154d1e553add2eb32a0d3c.
This fix was based  on using docsviewer with framework 3.1-dev and
fails on 3.0.3 stable
Fixing functions called statically to be declared as such
Improve default template of DocumentationViewer

class "container" was missing, so a bunch of CSS wasn't being applied.
The layout of the default docsviewer checkout now looks more like the
one on doc.silverstripe.org.
BUG Fixing search not working when no specific versions of docs
Merge pull request #21 from Martimiz/search-20130107
If no versions registered for a module, don't show empty versions in template