This is a searchable gopher index. Enter search keywords below
' \
"
.*?") fi #See if there's an error is403=$(echo "$precontent" | head -n1 | grep "Error: Access denied!") is404=$(echo "$precontent" | head -n1 | grep "Error: File or directory not found!") #Respond to any errors if [ -n "$is403" ] ; then printf '%s\15\12' 'HTTP/1.0 403 Forbidden' && iserror="true" fi if [ -n "$is404" ] ; then printf '%s\15\12' 'HTTP/1.0 404 Not Found' && iserror="true" fi if [ -n "$iserror" ] ; then if [ "$isdumb" = "true" ] ; then printf '%s\15\12' "Content-Type: text/plain" \ '%s\15\12' "Server: gopher to http gateway at $fqdn" \ '' \ "$precontent" else printf '%s\15\12' "Content-Type: text/html" \ '%s\15\12' "Server: gopher to http gateway at $fqdn" \ '' \ '' \ "$xyzzy" fi exit fi #If no errors, then we go here printf '%s\15\12' 'HTTP/1.0 200 OK' \ "$mimetype" \ "Server: gopher to http gateway at $fqdn" \ '' if [ "$mimetype" = "Content-Type: text/html" ]; then echo '' fi if [ "$isdumb" = "true" ] ; then echo "$xyzzy" | base64 -d else echo "$xyzzy" fi echo ""