|
From: Murray, G. <gre...@pt...> - 2025-01-09 04:48:04
|
Hello, I’m attempting to create my first RESTXQ web application. I’m unable to figure out how to make use of static files such as images, CSS, and JavaScript files in a RESTXQ context in eXist. Where should such files reside on the filesystem, and how are they referenced in relative URLs? For example, let’s say I’ve got my XQuery modules in /db/apps/my-app/ in which controller.xqm acts as the MVC controller and contains RESTXQ resource functions. Meanwhile the directory /db/apps/my-app/css/ contains CSS files. Other XQuery modules contain MVC views that return HTML to the browser. When including a CSS file in the HTML <head>, what path should be used to refer to a CSS file? I was assuming that something like <link type="text/css" rel="stylesheet" href="css/my.css"/> would suffice, since it is relative to the location of controller.xqm, but that seems to be incorrect. Thanks, Greg |