Updates for Legacy compatibility and 1 minor bug change.

Now use getConnection for Doctrine connection and getDatabaseConnection
for legacy connection.  Converted XMF assignments for this and added
global $xoopsDB to search.php
Small change to define legacy $xoopsDB global in installer when needed.
Convert to schema, fix several issues.

Install failing as table is also defined in system module, schema mechanism is more tolerant.
Move language out of sql file and into modinfo language file.
Move install inserts out of sql file and into install script.