If you want to run a bash script as a CGI and get this message:
[Sun Feb 07 19:51:59.424071 2016] [cgi:error] [pid 4265] [client x.x.x.x:50952] malformed header from script 'weather.sh': Bad header: Searching via name..
Make sure to put an additional echo in your script after the content type
echo "Content-type: text/html"
Thanks for reading this post!
Did you find an issue in this article?
- click on the following Github link
- log into Github with your account
- click on the line number containing the error
- click on the "..." button
- choose "Reference in new issue"
- add a title and your comment
- click "Submit new issue"
Your feedback is much appreciated! 🤜🏼🤛🏼
You can also drop me a line below!