[TASK] Refactor Javascript loading

Somehow the YAHOO.util.Event.onDOMReady event
was not fired. This patch changes the event listener.

Tested on Chrome, FF and Safari

Releases: 6.2

Change-Id: I08e95bf8237aa48a31c73e271e0c2e53cc5b431d
Reviewed-on: https://review.typo3.org/29688
Reviewed-by: Oliver Klee
Reviewed-by: Nico de Haen
Tested-by: Nico de Haen