#!/bin/sh

CGI_DIR="/home/www/cern/server/scripts"

if [ "$REQUEST_METHOD" = POST ] ; then
      eval `$CGI_DIR/cgiparse -init`
fi

eval `$CGI_DIR/cgiparse -form`

res=`expr "$FORM_op1" "$FORM_op" "$FORM_op2"`

echo "Content-Type: text/html"
echo ""
echo "<HTML>"
echo "<H1>Calculadora b&aacute;sica</H1>"
echo "<B>Resultado:</B>"
echo "$FORM_op1 $FORM_op $FORM_op2 = $res<p>"
echo "<A HREF=/form.html>CONTINUAR</A>"
echo "</HTML>"
