TEAM-ADA Archives

Team Ada: Ada Programming Language Advocacy

TEAM-ADA@LISTSERV.ACM.ORG

Options: Use Forum View

Use Monospaced Font
Show Text Part by Default
Condense Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Sender:
"Team Ada: Ada Advocacy Issues (83 & 95)" <[log in to unmask]>
Date:
Sun, 5 Dec 1999 13:17:49 +0100
Reply-To:
Jacob Sparre Andersen <[log in to unmask]>
Content-Transfer-Encoding:
8bit
Subject:
From:
Jacob Sparre Andersen <[log in to unmask]>
Content-Type:
text/plain; charset=ISO-8859-1
In-Reply-To:
<[log in to unmask]> from "Robert C. Leif, Ph.D." at Dec 4, 99 02:58:27 pm
Organization:
CATS, Niels Bohr Institute, University of Copenhagen, Denmark.
MIME-Version:
1.0
Parts/Attachments:
text/plain (66 lines)
Robert:

> To: Readers of Comp.Lang.Ada and Team-Ada

Is there an easy way to post to Comp.Lang.Ada through SMTP (e-mail)?

> Disclaimer: Although, I had this problem with an ObjectAda compiler, it is
> neither a bug or a design error. It is an Ada problem and therefore relevant
> to these forums.

I am afraid it probably is an operating system "design
error". Or maybe a HTTP "design error".

> <FORM method="Get" action="file:///C:\Ada_Work/com_line.exe"> is a
> reasonable key to this problem. It produces a Command_Line string and does
> invoke the com_line program shown below. Unfortunately,
> Command_Line.Argument_Count does not work with the Command_Line string.
> The Get method concatenates a '?' directly after the program name.

Yes.

> I have included a very simple HTML Form (Com_Line_Small) below. It produces
> the equivalent of "C:\Ada_Work\com_line.exe?TEST=Hello".
> I proved under Windows that this did not work with a Com_line.Bat batch
> program with the line above as its only text. However, the simple insertion
> of a space between the program and the '?' works.
> C:\Ada_Work\com_line.exe ?TEST=Hello

That is because MSW (and DOS, OS/2, Linux, etc.) uses a
space to separate the name of a command from it's
parameters.

> The output of my com_line_small.Bat is as follows:
>
> C:\Ada_Work\com_line_Small.exe?TEST=Hello
> The DOS Window shows: Bad command or file name

Yup. It looks for a command named
"C:\Ada_Work\com_line_Small.exe?TEST=Hello" (which
apparently doesn't exist on your machine).

Since the URL RFC (can't remember the number) says that
space and newline characters in URL's should be removed from
an URL before it is used, it is actually only due to a bug
in your browser that the appended space in the "action"
attribute fixes the problem.

But I like the idea of having the option of compiling an Ada
program with either a plain command line "command line"
interface or with a CGI "command line" interface.

I still believe that the proper solution presently is to
launch your program as a HTTP daemon. If we want to write
plain CGI programs, then we have to wait until "everybody"
has a HTTP daemon on their machine (or write one in Ada and
distribute it with our software).

Greetings,

Jacob

    ---------------------------------------------------
    --  E-mail:         [log in to unmask]           --
    --  Web...: <URL:http://hugin.ldraw.org/Jacob/>  --
    ---------------------------------------------------

ATOM RSS1 RSS2