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

Re: IDL sockets




George  wrote:

>>> Has any one used the SOCKET function successfully?

>>> I have tried the Craig Markwardt suggestion from an earlier
>>> post without any success.

>>>> socket, unit, 'cow.physics.wisc.edu', 80, /get_lun
>>>> printf, unit, 'GET http://cow.physics.wisc.edu/~craigm/idl/idl.html'
>>>> text = ''
>>>> while eof(unit) EQ 0 do begin
>>>> readf, unit, text
>>>> print, text
>>>> endwhile
>>>> free_lun, unit

Mark wrote:

>>> I didn't bother trying to connect directly to Craig's site because we
are
>>> behind a firewall. Are you? If you are, then the HTTP queries have to be

>>> sent to your proxy server and formulated a bit differently.


George wrote:
>> I tried it on our own web server and I am getting an error response from
>> the server:  -ERROR-(501):  Gateway function not available,
>> but at least the socket connection has worked.
>> All I have to do now is undertand Error-501 on our type of web server.


Craig wrote:

> It looks like I've gotten myself into a bit of a mess here.  It turns
> out that the code I posted in *not* the official way to operate the
> HTTP protocol.  I think it works because many web servers can act as
> gateways or redirectors which will essentially execute the protocol
> for you and return the results.  My web site server does this, but
> some others do not.

I tried the example *again* on our own WEB server, but this time taking
into account the Gateway issues raised earlier and it worked fine. thanks!
I can now possibly use this to access data on the server without needing
the extra layer imposed by dataminer and ODBC support.

IDL V5.5 support for TCPIP protocols would be nice, but it will compete
directly with ION and DataMiner. I hope RSI don't see this as a problem.



email:  GeorgeC@mhl.nsw.gov.au
http://www.mhl.nsw.gov.au