Re: [U2] Using the PUT method in an HTTP connection in UniBasic

2013-03-12 Thread Jeff Schasny
I use Curl for this sort of stuff. I have a generic http/https send/get 
routine you can get here:


http://www.schasny.com/bp/HTTP.TRANSFER

jim.sto...@esc.edu wrote:

Hello everyone,

We have been playing around with the UniBasic commands createRequest and 
submitRequest for use with some web services provided by our external 
vendors.  Unfortunately, one of the web services requires updates to 
existing data records to be submitted using the PUT method, instead of 
POST.  According to the UniBasic Commands Reference for both UniData 7.2 
and 7.3, the PUT method appears to not be supported for the createRequest 
command.  That struck me as a little odd, so just to be sure, we tried it 
and couldn't get it to work.


Does anyone know of an alternative way to create http requests in UniBasic 
that would support the PUT method?  We have UniData 7.2 running on HP-UX. 
Most of my programming experience is on other platforms, typically on 
Windows, so my normal solution to this problem would be to make use of 
Microsoft's WinHTTP object (or one of its equivalent siblings) to handle 
the http request.  Is there a way to do something equivalent to that in 
UniBasic on HP-UX? 


Thanks in advance for any suggestions you can give me!
Jim Stoner
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users

  


--

Jeff Schasny - Denver, Co, USA
jschasny at gmail dot com

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


[U2] Using the PUT method in an HTTP connection in UniBasic

2013-03-11 Thread Jim . Stoner
Hello everyone,

We have been playing around with the UniBasic commands createRequest and 
submitRequest for use with some web services provided by our external 
vendors.  Unfortunately, one of the web services requires updates to 
existing data records to be submitted using the PUT method, instead of 
POST.  According to the UniBasic Commands Reference for both UniData 7.2 
and 7.3, the PUT method appears to not be supported for the createRequest 
command.  That struck me as a little odd, so just to be sure, we tried it 
and couldn't get it to work.

Does anyone know of an alternative way to create http requests in UniBasic 
that would support the PUT method?  We have UniData 7.2 running on HP-UX. 
Most of my programming experience is on other platforms, typically on 
Windows, so my normal solution to this problem would be to make use of 
Microsoft's WinHTTP object (or one of its equivalent siblings) to handle 
the http request.  Is there a way to do something equivalent to that in 
UniBasic on HP-UX? 

Thanks in advance for any suggestions you can give me!
Jim Stoner
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] Using the PUT method in an HTTP connection in UniBasic

2013-03-11 Thread Symeon Breen
Use the *nix curl command - it can do any verb and any payload.

Or just use the sockets api - http is just a simple socket conversation.






-Original Message-
From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of
jim.sto...@esc.edu
Sent: 11 March 2013 20:21
To: U2 Users List
Subject: [U2] Using the PUT method in an HTTP connection in UniBasic

Hello everyone,

We have been playing around with the UniBasic commands createRequest and
submitRequest for use with some web services provided by our external
vendors.  Unfortunately, one of the web services requires updates to
existing data records to be submitted using the PUT method, instead of POST.
According to the UniBasic Commands Reference for both UniData 7.2 and 7.3,
the PUT method appears to not be supported for the createRequest command.
That struck me as a little odd, so just to be sure, we tried it and couldn't
get it to work.

Does anyone know of an alternative way to create http requests in UniBasic
that would support the PUT method?  We have UniData 7.2 running on HP-UX. 
Most of my programming experience is on other platforms, typically on
Windows, so my normal solution to this problem would be to make use of
Microsoft's WinHTTP object (or one of its equivalent siblings) to handle the
http request.  Is there a way to do something equivalent to that in UniBasic
on HP-UX? 

Thanks in advance for any suggestions you can give me!
Jim Stoner
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users