Closed will-moore closed 4 years ago
When you create URLs such as '/omero_3dscript/startRendering', in the JavaScript code, you should base this on a Django-generated URL, e.g:
var BASE_3DSCRIPT_URL = "{% url '3Dscript_index' %}";
See example at https://github.com/ome/omero-figure/blob/master/omero_figure/templates/figure/index.html#L42 then use this global variable to create URLs.
This will include any web URL 'prefix' (see https://docs.openmicroscopy.org/omero/5.6.1/sysadmins/unix/install-web.html#customizing-your-omero-web-installation ) e.g. If using an 'omero' prefix as in the docs example, BASE_3DSCRIPT_URL will be /omero/omero_3dscript/.
BASE_3DSCRIPT_URL
/omero/omero_3dscript/
When you create URLs such as '/omero_3dscript/startRendering', in the JavaScript code, you should base this on a Django-generated URL, e.g:
See example at https://github.com/ome/omero-figure/blob/master/omero_figure/templates/figure/index.html#L42 then use this global variable to create URLs.
This will include any web URL 'prefix' (see https://docs.openmicroscopy.org/omero/5.6.1/sysadmins/unix/install-web.html#customizing-your-omero-web-installation ) e.g. If using an 'omero' prefix as in the docs example,
BASE_3DSCRIPT_URL
will be/omero/omero_3dscript/
.