#!/bin/sh

#simple script to return the values of environment variables.

echo Content-Type: text/html

echo

#simple header info

echo "<TITLE>env_vars.sh</TITLE>"

echo "<H1>env_vars.sh</H1>"

echo "Below are the values of environment variables that were set"

echo "when this script was launched.<b><HR><LISTING>"

#were there any command-line arguments?

echo number of args: $# 

echo value of args: $*

echo

#now the variables

echo SERVER_SOFTWARE: 	$SERVER_SOFTWARE

echo SERVER_NAME:		$SERVER_NAME

echo GATEWAY_INTERFACE:	$GATEWAY_INTERFACE

echo SERVER_PROTOCOL:	$SERVER_PROTOCOL

echo SERVER_PORT:		$SERVER_PORT

echo REQUEST_METHOD:		$REQUEST_METHOD

echo PATH_INFO:		$PATH_INFO

echo PATH_TRANSLATED:	$PATH_TRANSLATED

echo SCRIPT_NAME:		$SCRIPT_NAME

echo QUERY_STRING:		$QUERY_STRING

echo REMOTE_HOST:		$REMOTE_HOST

echo REMOTE_ADDR:		$REMOTE_ADDR

echo AUTH_TYPE:		$AUTH_TYPE

echo REMOTE_USER:		$REMOTE_USER

echo REMOTE_IDENT:		$REMOTE_IDENT

echo CONTENT_TYPE:		$CONTENT_TYPE

echo CONTENT_LENGTH:		$CONTENT_LENGTH

echo HTTP_ACCEPT:		$HTTP_ACCEPT

echo HTTP_USER_AGENT:	$HTTP_USER_AGENT



