I am trying to write a CGI Program which is invoked from a HTML page . The CGI code snippet is as follows:
#!/bin/bash
echo "Content-type: text/html"
echo "<html>"
echo "<body>"
echo "Hi"
echo "</body>"
echo "</html>"
But after executing the script I can see the 500:Internal Server Error
in browser page. .
Following can be seen in error log file
[Wed Apr 09 18:36:59 2014] [error] [client 127.0.0.1] malformed header
from script. Bad header=<html>: image.sh
[Wed Apr 09 18:37:14 2014] [error] [client 127.0.0.1] malformed header
from script. Bad header=<html>: image.sh