basexhttp and static content
Thursday, 17 November 2011 · 1 message
CG
Christian Grün17 Nov 2011 23:36 #
Leigh,
thanks for the patches; be sure we'll have a look at it (probably tomorrow). As a side note: the http directory (specified by the HTTPPATH option of BaseX [1]) could be a possible existing destination for static resources.
Keeping you tuned,
Christian
[1] http://docs.basex.org/wiki/Options#HTTPPATH
Quoted text · Jr. · 36 lines
On Thu, Nov 17, 2011 at 11:32 PM, Leigh L. Klotz, Jr. <klotz at graflex.org> wrote: > Thank you Michael and Christian. > > db:retrieve and the XQuery framework look quite interesting and I see how > they could work. > > I had in mind something more lightweight. I've done some examples using > BaseX with AgenceXML XSLTForms, which is a 100% in-browser implementation > of XForms that needs to be served up as static content. > > Here's what I mean: > > 1. Change BaseXHTTPServer so that it tells Jetty about a directory for > static resources; Jetty already knows how to handle this. > 2. Create an "xsltforms" directory and unzip XSLTForms into it. > 3. Create an application directory, and put the XHTML+XForms XML file (and > associated CSS) into that directory. > > I've attached a couple of git patches that enable #1 above, just as an > example of what I mean. They enable the command-line option "-x > <directory>" and provide help text for it. > > I've tried this and it works great with the current git version of basex, > after applying the two attached patches to basex and basex-api: > cd basex > mkdir static > cd static > mkdir xsltforms; pushd xsltforms; unzip /path/to/xsltforms.zip; popd > mkdir mypage; pushd mypage; cp /path/to/mypage/index.xml .; popd > ./bin/basexhttp -x static & > > Please consider adding a quick deploy test facility like this to the > BaseXHTTPServer. > > Leigh. >
Written for BaseX 7.0. BaseX may have changed since: please check the current documentation.
⚡Generated with XQuery