#!/bin/sh FILE=ipaddrs echo Content-type: text/plain echo if grep -s $REMOTE_ADDR $FILE > /dev/null 2>&1 then echo Computer $REMOTE_ADDR has requested this URL previously. else echo $REMOTE_ADDR >> $FILE echo This is the first contact from computer $REMOTE_ADDR. fi