> I have a java applet that posting some data to my cold fusion 
> template. But I can't seem to access the data. It doesn't appear 
> to be showing up in a FORM post, more of a raw-socket post as 
> far as I can tell from the documentation. When I output the CGI 
> structure seen by the webserver via the Cold Fusion Template, 
> I get the list attached at the bottom.
> 
> As you can see, 46K of some data is being detected but I don't 
> know how to access this data. I also notice the request method 
> is now set to POST instead of GET. Even though I loop from the 
> form structure and the variable fieldnames it doesn't see any 
> named variables. The java applet also has the ability to transmit 
> a header before the post, is there a way I can fake a form header 
> so this data does show up as a form field?

If you're using CF 5, you can use the GetHTTPRequestData function to
retrieve the raw HTTP request body, which is what you want. If not, there's
no way of which I'm aware within CF to get the request body directly.

If you can change what the Java applet sends, you might be able to simply
add something like this at the very beginning of your HTTP request body:

myvar=

Then, everything else within the body will be in the variable Form.myvar
within your CF action page. This assumes that the Java applet is posting
with the standard POST MIME type of application/x-www-form-urlencoded; if
it's formatting the data some other way, you might have problems.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/
voice: (202) 797-5496
fax: (202) 797-5444
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Get the mailserver that powers this list at http://www.coolfusion.com
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to