[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: FW: HTTPAPI



Hi Ron,

> Hello I am trying the examples and trying to get to our servlet
> When I do this I get the following response back
> Project file is required

This message is coming from the Servlet, not HTTPAPI!   I'm not familiar 
with your servlet, what does "Project file is required" mean?  Is there a 
parameter that you're supposed to pass that contains the name of a project 
file?


> When I check the parameters received at the servlet I get none

How does the servlet expect to receive it's parameters?  Using GET?  POST? 
How does it expect them to be encoded?  URL encoding? Base64? XML? MIME?


> I am using the code like EXAMPLE5
> I am using the encoder and the following
>
> eval      rc=http_url_post_raw(
>                'http://localhost:8000/linomax'
>             +  '/servlets/runProjectCommand'
>           :myPointer
>           :dataSize
>           :30
>           :%paddr('INCOMING')
>           )

I don't see anything wrong with that, as long as the servlet expects the 
parameters to be sent in this manner.

> SetError() #13: HTTP/1.1 100 Continue
> senddoc(): entered
> projectLocation=Test_101.xml&priority=5&mode=interactive

The above data is what you're sending to the servlet in POST fashion. Note 
that it's 3 parameters that are URL encoded.  If the servlet doesn't 
expect the data to be sent via the POST method, or doesn't expect them to 
be URL encoded, or expects them to have different names or capitalized 
differently, then you need to change your code accordingly.

But, clearly, HTTPAPI is sending them the way you told it to. :)

Here's the data you're getting back from the servlet:

> jobNumber=-1
> message=Project file is required

It's just data sent by the server.  HTTPAPI does nothing but relay it back 
to your program.
-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------