I am following Jon Paris's article:
http://www.ibmsystemsmag.com/ibmi/developer/rpg/web_service_rest/.
I have success with the name/value pair like this:
myas400:8076/PHIL/B01?in_state=OH
but I get an error when I try it this way:
myas400:8076/PHIL/B01/OH
It can't find the program so I think it thinks that OH is the program
instead of an argument.
My httpd.conf file has a ScriptAliasMatch to map anything following
PHIL to /qsys.lib/phil.lib:
ScriptAliasMatch ^/PHIL/(.*) /qsys.lib/phil.lib/$1.pgm
I found in the archives that Jon Paris also had a problem, and I think
his last post said he used ScriptAlias instead of ScriptAliasMatch.
Looking at it, it looks like it maps one url directory to one program
only:
ScriptAlias /restsrv1 /qsys.lib/partner400.lib/restsrv1.pgm
So I added it below the ScriptAliasMatch directive:
ScriptAlias /rest /qsys.lib/phil.lib/b02.pgm
and that works. However, I wouldn't want to have to add another
ScriptAlias directory for every webservice.
Is that the only way to do it? Am I missing something?
Thanks,
Phil
As an Amazon Associate we earn from qualifying purchases.