View previous topic :: View next topic |
Author |
Message |
The_Duck(1) Guest
|
Posted: Thu Nov 07, 2002 5:50 pm Post subject: CGI program will not execute :( |
|
|
I have created a simple CGI program using ADA 95.
WITH Cgi; USE Cgi;
PROCEDURE Control IS
BEGIN
Put_Html_Head("cgi");
Put_Html_Tail;
END Control;
It returns the following
<HTML><HEAD><TITLE>cgi</TITLE></HEAD><BODY></BODY></HTML>
I complie the program using GNAT (I think it creates a 16bit executable)
However on creating a link to the cgi program the server reports an internal error :(
Any suggestions as to what is going on.
btw i reg but this forum will not let me log in ?!? |
|
Back to top |
|
|
aprelium -
Joined: 22 Mar 2002 Posts: 6800
|
Posted: Thu Nov 07, 2002 6:55 pm Post subject: Re: CGI program will not execute :( |
|
|
The_Duck(1) wrote: | I have created a simple CGI program using ADA 95.
WITH Cgi; USE Cgi;
PROCEDURE Control IS
BEGIN
Put_Html_Head("cgi");
Put_Html_Tail;
END Control;
It returns the following
<HTML><HEAD><TITLE>cgi</TITLE></HEAD><BODY></BODY></HTML>
I complie the program using GNAT (I think it creates a 16bit executable)
However on creating a link to the cgi program the server reports an internal error :(
Any suggestions as to what is going on.
|
Abyss Web Server X1 runs 16 bit executable so that won't be the problem.
Your program send only the HTML output. It should also send at the beginning at least a status header to be conforming to CGI.
All you have to do is to add a single line at the beginning:
Code: |
WITH Cgi; USE Cgi;
PROCEDURE Control IS
BEGIN
Put_CGI_Header;
Put_Html_Head("cgi");
Put_Html_Tail;
END Control;
|
The Ada CGI library documentation is available at http://www.cs.uofs.edu/~beidler/Ada/cgi/cgi.html .
The_Duck(1) wrote: | btw i reg but this forum will not let me log in ?!? |
Have you enabled cookies ? _________________ Support Team
Aprelium - http://www.aprelium.com |
|
Back to top |
|
|
The_Duck -
Joined: 07 Nov 2002 Posts: 7
|
Posted: Thu Nov 07, 2002 11:01 pm Post subject: |
|
|
omg :0)
I not done cgi in ada for a while and I can't belive i missed CGI_Header; Sry if you had to do any resarch to look that up and ty for doing it :) Saved me a few hrs work :D
Forum now longs me in strange. Perhaps there was a delay in database update ??
Anyway ty again :D |
|
Back to top |
|
|
aprelium -
Joined: 22 Mar 2002 Posts: 6800
|
Posted: Thu Nov 07, 2002 11:53 pm Post subject: |
|
|
The_Duck wrote: | omg :0)
I not done cgi in ada for a while and I can't belive i missed CGI_Header; Sry if you had to do any resarch to look that up and ty for doing it :) Saved me a few hrs work :D
Forum now longs me in strange. Perhaps there was a delay in database update ??
Anyway ty again :D |
Do not apologize, that was a great occasion for us to have some ADA knowledge. :D _________________ Support Team
Aprelium - http://www.aprelium.com |
|
Back to top |
|
|
|