wallg
11-02-2007, 09:03 PM
Using-
Apache 2.x
HP-UX 11.11
CGI script written in ksh
gnuplot 4.0
ppmtogif
Getting a broken image (red X) displayed in browser instead of the on-the-fly generated image.
ksh CGI script-
...
echo "Content-type: image/gif\n\n"
ppmtogif file.ppm 2>/dev/null
HTML file-
<html>
<body>
<h4>Text</h4>
<IMG SRC="http://server.com:8888/cgi-bin/script.ksh" alt="Alt text" BORDER=0>
</body>
</html>
Is there something else the CGI script should be sending?
Added these 2 lines to the Apache httpd.conf-
AddHandler cgi-script .ksh
AddType image/gif .gif
Are there other modifications to the httpd.conf that I should make?
The script works on the command line, successfully generating the GIF file.
Any ideas or tips would be greatly appreciated.
Thanks.
Apache 2.x
HP-UX 11.11
CGI script written in ksh
gnuplot 4.0
ppmtogif
Getting a broken image (red X) displayed in browser instead of the on-the-fly generated image.
ksh CGI script-
...
echo "Content-type: image/gif\n\n"
ppmtogif file.ppm 2>/dev/null
HTML file-
<html>
<body>
<h4>Text</h4>
<IMG SRC="http://server.com:8888/cgi-bin/script.ksh" alt="Alt text" BORDER=0>
</body>
</html>
Is there something else the CGI script should be sending?
Added these 2 lines to the Apache httpd.conf-
AddHandler cgi-script .ksh
AddType image/gif .gif
Are there other modifications to the httpd.conf that I should make?
The script works on the command line, successfully generating the GIF file.
Any ideas or tips would be greatly appreciated.
Thanks.