?Rev CGI Linux Engine won't POST or GET http

boring too tooboring_2000 at yahoo.com
Fri Jul 16 12:08:40 EDT 2004


Summary: Rev CGI won't poll another http process with
'get url' or 'post ... to url'

Revolution problem:

I'm running Revolution as a cgi on a nearby ISP's
Linux Box.

My script needs to poll another server (via http POST)
and get about 100 bytes of data, and then include that
in the response to my web user's request.

Unfortunately, POST is immediately returning with ""
(i.e. empty).

So, I simplified the script to just a 'get url
<someurl>' - with the same results - empty.

Here's the simplified script:
-------------------------------------------------------------------------
#!revolution

on startup
    
  put "Content-Type: text/plain" & cr & cr

  put "Hello World!" && $REMOTE_ADDR && "The time is:"
&& the time & cr
  
  put the ticks into t0
  
  
  get url "http://www.apple.com"
  put it into temp
  
  put the result & cr & cr  
  put "*" & temp & "*" -- bracket the html with
asterisks
  
  put the ticks into t1
  put (t1-t0) && "ticks"
end startup
-------------------------------------------------------------------------

Invoking it at the Linux Shell prompt gives this
result...
-----------------------------------
/cgi-bin % getapple.cgi
-----------------------------------
Content-Type: text/plain

Hello World!  The time is: 10:17 PM


**
0 ticks
/cgi-bin %
-----------------------------------

The HTML of www.apple.com _should_ have been between
the asterisks.  No error was returned in 'the result'.


Per some other discussions on this list, I _did_ check
for Link Dependencies using ldd.

-------------------------------------------------------------------------
/cgi-bin % ldd revolution   <-- this was for Rev 2.1.2

        libXext.so.6 => /usr/X11R6/lib/libXext.so.6
(0x4001e000)
        libX11.so.6 => /usr/X11R6/lib/libX11.so.6
(0x4002c000)
        libstdc++.so.5 => /usr/lib/libstdc++.so.5
(0x400f3000)
        libm.so.6 => /lib/libm.so.6 (0x401ad000)
        libgcc_s.so.1 => /lib/libgcc_s.so.1
(0x401cf000)
        libc.so.6 => /lib/libc.so.6 (0x401d7000)
        libdl.so.2 => /lib/libdl.so.2 (0x4030a000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2
(0x40000000)
-------------------------------------------------------------------------
/cgi-bin % ldd revolution    <-- this was for the
current Version of Rev
        libXext.so.6 => /usr/X11R6/lib/libXext.so.6
(0x4001e000)
        libX11.so.6 => /usr/X11R6/lib/libX11.so.6
(0x4002c000)
        libm.so.6 => /lib/libm.so.6 (0x400f3000)
        libc.so.6 => /lib/libc.so.6 (0x40116000)
        libdl.so.2 => /lib/libdl.so.2 (0x40249000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2
(0x40000000)
-------------------------------------------------------------------------


I downloaded the most recent engine, and I downloaded
Rev 2.1.2, and got the same results from scripts.


Then I downloaded the 1.0 engine (really MetaCard
2.3.2).
With it, the 'get url' worked ok, but the 'post ... to
url' failed with Signal 11 error in the shell...
------------------
/cgi-bin % doPost.cgi
revolution exiting on signal 11
------------------


Is there some switch that is turned off?  This ISP is
_very_ lenient, I doubt they have locked up outgoing
TCP/IP traffic from my CGI, or removed necessary
libraries.

So what might I be missing?

I don't know how to put my serial number into any of
the Linux Engines, is it necessary? I thought that
they were "free to use as servers", and didn't need my
serial number?

tia for any help...



George


		
__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - Send 10MB messages!
http://promotions.yahoo.com/new_mail 


More information about the use-livecode mailing list