11-25-2011 02:18 AM
The case is that a http request is something like www.ni.com?uid=12345.
Since the case involve OAuth, the TCP vis are used instead of HTTP vis.
And my problem is where to put the "uid=12345" info. in the http header string?
-----------------------
ahunter
11-25-2011 06:20 AM - edited 11-25-2011 06:24 AM
If you use the TCP functions you have to do everything on your own. Your URI needs to be parsed and seperated into its various components, such as scheme, autority, host, port, query etc. The host and port part is needed for the TCP Open function, then you construct a HTTP text string that builds the correct HTTP protocol elements using all of the sub parts you got from parsing the UTI. It's anything but trivial to really get this all right but it is doable.
Your ?uid=12345 is the query component and would have to be added to the path of the HTTP GET request in the formatted HTTP message that you write to the TCP socket using the TCP Write primitive.