apache cgi problem
I have configured apache to run cgi scrips. They run, but they are displayed in mozilla as text (as in when you view the page source) and not as html. I have verified this behavior from only 2 different redhat 8.0 hosts.
However, the scripts work perfectly when viewed from IE from the apache server. Pages, images, links everything is happy in IE.
Also, the scripts work perfectly in mozilla and IE when the same scripts are run a micro$oft IIS web server.
Anybody got ideas? I wonder if it is my header?
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<LINK REL="SHORTCUT ICON" href="">
What are you sending back as the Content-Type?
Never mind. I found the prob (and, you are correct).
I needed to put "Content-type:text/html\n\n" right at the very start, nothing in front of it.
This is my second day using Apache. I am surprised at how many things I had to change in the scripts to get them running on apache. Not just the obvious stuff like the above omission, but even some obscure, arcane things too. For instance $variable = $cgi->url() does not produce the same results from IIS as it does on Apache. Case sensitivity has gotten me a few times.
I'm not done with all of the websites (8 of them), but I think all the hard stuff is over with.
|All times are GMT -5. The time now is 02:28 AM.|