Corrected query and matrix parameter parsing

If no parameters were present, the whole segment was put in the
parameter variables. Still no proper parsing of the parameters though.
Factored out the code to respond with a static file to
bc_serve_static_file. Added a test subresource script.