Yes, as Richard rightly (and promptly, thanks Richard!) explained it, this is the expected behavior.
The directory /gwan/.../csp/script.c
is used to store servlets that must be run while /gwan/.../www/script.c
is used to store files intended to be served as an HTTP resource.
The corresponding URLs are GET /?script.c
and GET /script.c
.
Any sub-directory used in the /csp
or /www
folders is reflected accordingly in the HTTP request: GET /folder/?script.c
for dynamic contents and GET /folder/script.c
for static contents.
The choice of moving the '?'
query character (which can be replaced by other characters) from the old GET /csp?/folder/script.c
form to the new GET /folder/?script.c
form was motivated by the need to:
- distinguish
servlet
names from folder
names (requests can lack the servlet extension for the defined 'default' programming language, which is C if nothing is defined)
- allow any number of
sub-directories
in HTTP requests
- allow any number of
query arguments
in HTTP queries
- distinguish between
folders
and query arguments
in HTTP requests
- make it possible to have
RESTFUL
requests in all the above cases.
It took us a while to find the proper mix of features with the minimal verbosity but experience has shown that this works well.
Here is an example of a RESTFUL query having both a sub-folder and query arguments:
GET /folder/?script/arg1/value1/arg2/value2/arg3/value3
By default, this is a C script, unless another language (among the 15 available for scripting) has been defined as the 'default' language.
Note that the 50+ script examples provided in the download archive illustrate this scheme which is also presented on the developers page.