www-apache-bugdb mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marc Slemko <ma...@znep.com>
Subject Re: general/1362: CGI script using UNIX shell script "expr" command produces no output (fwd)
Date Mon, 10 Nov 1997 16:00:01 GMT
The following reply was made to PR general/1362; it has been noted by GNATS.

From: Marc Slemko <marcs@znep.com>
To: Apache bugs database <apbugs@apache.org>
Cc:  Subject: Re: general/1362: CGI script using UNIX shell script "expr"  command produces
no output (fwd)
Date: Mon, 10 Nov 1997 08:59:10 -0700 (MST)

 ---------- Forwarded message ----------
 Date: Mon, 10 Nov 97 06:53:00 GMT
 From: "Ferrell, Lance P            EA" <FERRELLL@IHUB.EA.unisys.com>
 To: "apache-bugdb@apache.org" <apache-bugdb@apache.org>,
     "ferrelll@ihub.ea.unisys.com" <ferrelll@IHUB.EA.unisys.com>,
     "marc@apache.org" <marc@apache.org>,
     "marc@hyperreal.org" <marc@hyperreal.org>
 Subject: Re: general/1362: CGI script using UNIX shell script "expr"  command produces no
output
 
 
 I sent a response to this request for further information, a few days ago. 
  I am resending to make sure that you go it.   Here is the example you 
 requested.
 
 ____________________________________________________________________________  
 _________________________________
 #! /bin/sh
 echo "Content-type: text/html"               # begin WEB Page initialization
 echo ""
 echo "<HTML><HEAD>"                          # begin header
 echo "<META HTTP-EQUIV="Refresh" CONTENT=300>"  # refresh the Page every 300 
 seconds, (5 minutes)
 echo "<TITLE>Port Statuses</TITLE>"  # set the "TITLE" label
 echo "</HEAD><BODY>"                         # end of header, begin page 
 body
 echo "<b><FONT SIZE=4>DEVICE <FONT COLOR="red" SIZE=3>Port Statuses 
 </FONT></b><br>"  # add page heading
 ctr=0
 echo "Counter at $ctr<br>"
 ctr=`expr $ctr + 1`                          # add 1 to variable counter
 echo "Counter at $ctr<br>"
 echo "</BODY></HTML>"
 
 ____________________________________________________________________________  
 __________________________________k
 
 I have also noticed that the "sort" command seems to produce the same 
 results.  That is, a variable contains nothing after being run through a 
 standard sort.  When a command is piped through a sort, the variable is 
 empty.  If the sort is removed and the rest of the command is left the same, 
 the output is normal.  This behavior is not noted when the script is run 
 under a normal shell in UNIX.
 
 Thanks for your help.
  ----------
 From: marc@hyperreal.org
 To: apache-bugdb@apache.org; ferrelll@ihub.ea.unisys.com; marc@apache.org
 Subject: Re: general/1362: CGI script using UNIX shell script "expr" command 
 produces no output
 Date: Wednesday, November 05, 1997 3:41PM
 
 Synopsis: CGI script using UNIX shell script "expr" command produces no 
 output
 
 State-Changed-From-To: open-analyzed
 State-Changed-By: marc
 State-Changed-When: Wed Nov  5 07:41:49 PST 1997
 State-Changed-Why:
 Please give a full example of the most basic shell script
 that doesn't work as you think it should.  It is _very_
 unlikely that this has anything to do with Apache.
 

Mime
View raw message