Implemented support to load jQuery via AMD

Loading jQuery directly causes issues when combined with applications
that use an AMD implementation like RequireJS. To avoid this we check if
amd is defined and if so load jQuery via require. For continued support
of the existing implementation we also assign the jQuery variable
directly to jQueryMP when loaded through AMD.