$! Simple demonstration that even DCL procedure, vanilla-CGI scripts $! can use the CGIplus callout mechanism. $! 19-APR-2008 MGD add WATCH: callout $! 03-JUN-2000 MGD less sloppy CGI, add header! $! 06-SEP-1999 MGD initial $! $ say = "write sys$output" $ open /read CgiPlusIn CGIPLUSIN $! $ say "Content-Type: text/plain" $ say "" $! $ say "CGI variable symbols:" $ say "" $ show symbol www_* $! $ say "" $ say "CGI(plus) callout example:" $ say "" $! $ if f$type(WWW_WATCH_SCRIPT) .nes. "" $ then $ say f$trnlnm("CGIPLUSESC") $ say "WATCH: WATCHing ... " + f$environment("PROCEDURE") $ read CgiPlusIn /end=EndRequestLoop Response $ acute_e[0,8] = 233 $ say "!WATCH: 8-bit ... R" + acute_e + "ponse" $ say f$trnlnm("CGIPLUSEOT") $ endif $! $ PathPtr = WWW_PATH_INFO $ say "Map '" + PathPtr + "' using the following callout request ..." $ say "" $ say " ""MAP-FILE: " + PathPtr + """" $ say "" $! $!(this block is the actual callout) $ say f$trnlnm("CGIPLUSESC") $ say "MAP-PATH: " + PathPtr $ read CgiPlusIn /end=EndRequestLoop Response $ say f$trnlnm("CGIPLUSEOT") $! $ say "Server response was ..." $ say "" $ say " """ + Response + """" $ say "" $ if f$extract(0,1,Response) .eqs. "2" $ then $ say "Yielding a file specification of ..." $ say "" $ say " " + f$extract(4,999,Response) $ else $ say "The response indicated an error." $ say "(try adding a path to the script URL)" $ endif