WebUI: use `filepatharg` in `onload` path.

Fixes #3296.
WebUI: Cleanup.
coverity.bat: Prefer 7-Zip for packages.
WebUI: only make available to global scope the functions we need to access.