I was experimenting around a little with various viewers. OHIF is a little tricky to integrate sometimes if one has various reverse proxies already configured, and there are sometimes CORS issues as well.
I am just curious if anyone has tried hosting the OHIF package using the ServerFolders feature within Orthanc. I tried that using the localhost setup with a URL like:
http://localhost:8042/OHIF/index.html/?StudyInstanceUID
and it at least loads the page, but I get an error loading the “workbox-window.dev.mjs” file. The MIME type says “application/octet-stream”, but I think it should be “application/javascript” ?
“Loading module from “http://localhost:8042/OHIF/third_party/workbox/workbox-v5.1.4/workbox-window.dev.mjs” was blocked because of a disallowed MIME type (“application/octet-stream”).”
I also get an error:
Sorry, this page does not exist.
Go back to the Study List
and after clicking on that I see the study list, and then when I click on a study it does actually display in OHIF, with no other apparent errors.
The performance isn’t bad in my dev setup. The OHIF package was built with npm and yarn from the GitHub repo and then the dist folder is mapped to a ServeFolders folder.
Just wondering how feasible it is to host OHIF that way ? Does CivetWeb have a config for MIME types for the .mjs and .js files ? Can it handle Cookies and ENV variables somehow. I presume that the Civet web server is also used for Explorer2, Stone, etc.
Might be that these are not included because it is embedded and not standalone ?
src/third_party/* (third party components, mainly used for the standalone server)
src/mod_*.inl (modules to access third party components from civetweb)
One other issues I’ve noted with OHIF is that multipage embedded PDF’s do not scroll to the “last page”, but when they are downloaded the whole document downloads. That might be an OHIF issue or related to the format of the embedded PDF.
Stephen D. Scotti