[fix] Implemented replacement of http protocol if current connection is https. Fixes #994
[imp] Changed conditional to make it easier to read.. Fixes #1839
[imp] Remove dependencies on document types. Fixes #488

Remove dependencies on document types in web.config
Merge remote-tracking branch 'joomla/staging' into 3.4-dev
Merge remote-tracking branch 'joomla/3.4-dev' into 3.4-dev