=================================================================== RCS file: /home/cvs/OpenXM/src/kan96xx/Doc/httpd-asir.sm1,v retrieving revision 1.14 retrieving revision 1.19 diff -u -p -r1.14 -r1.19 --- OpenXM/src/kan96xx/Doc/httpd-asir.sm1 2001/08/23 02:08:41 1.14 +++ OpenXM/src/kan96xx/Doc/httpd-asir.sm1 2002/01/16 09:20:00 1.19 @@ -1,15 +1,15 @@ -%% $OpenXM: OpenXM/src/kan96xx/Doc/httpd-asir.sm1,v 1.13 2001/08/23 00:49:00 takayama Exp $ +%% $OpenXM: OpenXM/src/kan96xx/Doc/httpd-asir.sm1,v 1.18 2002/01/13 06:57:43 takayama Exp $ %% http server by sm1 [(parse) (httpd.sm1) pushfile] extension pop /httpd.port 1200 def /httpd.image.name (kobeuniv2.jpg) def -/httpd.image.type (jpeg) def /httpd.initialization %% Put initialization codes here. [ + (XM_debug=0; ctrl("debug_window",0);) ("Asirweb version 0.80. "+ " Risa/Asir oxasir version "+rtostr(version());) ] cat @@ -34,9 +34,27 @@ def /httpd.port 1200 rrr add def httpd.port message - [(sleep 3; netscape -geometry 800x500 http://localhost:) - httpd.port toString - ( &)] cat system + %%[(sleep 3; netscape -geometry 800x500 http://localhost:) + %% httpd.port toString + %% ( &)] cat system + [(ostype)] extension 0 get + (windows) eq { + %% On windows. + [(forkExec) + [ + %%(c:\windows\command\start) + (start) + (iexplore) %% Starting internet explorer (TM). + [(http://localhost:) httpd.port toString] cat + ] + [ ] + 3] extension + }{ + %% On unix. + [(sleep 3 ; netscape http://localhost:) httpd.port toString ( & ) ] cat + system + } ifelse + httpd ; ] pop popVariables @@ -241,13 +259,19 @@ def msg2 0 get (httpdAsirMeta) eq msg2 1 get (Pretty) eq and { + httpd.image.type null eq { + send-page-warning-image + /skip-image goto + } { } ifelse + + msg2 2 get . (integer) dc /nn set %% Reformat the "nn"-th result by tex and send it. %% BUG: index is out of bound. httpd.result.history nn get message oxasir.ccc - [$print_gif_form(Oxserver_history_variable_$ + [$print_$ httpd.image.type $_form(Oxserver_history_variable_$ nn toString $);$ ] cat @@ -256,13 +280,14 @@ def dup 0 get /err set 1 get /fn set err [ ] eq { - fn 0 get (gif) send-image + fn 0 get httpd.image.type send-image } { [err preformatHTML] cat send-page-3 } ifelse %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + /skip-image /result 0 def } { } ifelse }{ } ifelse