Re: Multi-line string extension

Bill Janssen (janssen@parc.xerox.com)
Mon, 2 May 1994 16:37:23 PDT

Excerpts from ext.python: 18-Apr-94 Re: Multi-line string exten..
"Steven D. Majewski"@elv (4033)

> Maybe better that either of those, would be to make Python
> "html-smart". Define a tag for python code, and if the file
> begins with a bracketed html code, skip to the python-code
> section. However, this doesn't work with unix
> "#!/usr/local/bin/python" executables.

More in like with the WWW philosophy would be to new MIME (RFC 1521)
types, say MULTIPART/PYTHON and APPLICATION/PYTHON. The
MULTIPART/PYTHON would contain both APPLICATION/PYTHON and other parts,
such as APPLICATION/POSTSCRIPT (already defined).

Or instead of MULTIPART/PYTHON, use MULTIPART/ALTERNATIVE along with
APPLICATION/PYTHON.

The python interpreter would look at the first line (second line if the
first is #!/something/python), and if it was ``Content-Type:
MULTIPART/ALTERNATIVE'', would then scan looking for instances of
APPLICATION/PYTHON, and executing them. Viewers such as Xmosaic could
also present the file properly, presenting the HTML or Postscript part
of the document.

Bill