Interactive web image using Python
Markus Schaber
markus at schabi.de
Tue Sep 25 14:12:27 EDT 2001
Hamish Lawson <hamish_lawson at yahoo.co.uk> schrub:
> Paul Boddie wrote:
>
>> The last thing could, I suppose, be done by either saving the image
>> somewhere which is accessible from the user's browser (so that the
>> "img" tag can pick the generated image up from a static resource), by
>> generating the image independently of the Web page (and imagemap) (so
>> that the image is only generated when the browser attempts to load
>> the "src" of the "img" tag), or by sending the image with the Web
>> page to the browser. I must admit that I haven't looked too much into
>> the latter, but it might be an elegant solution.
>
> Paul, I've used the first two techniques you mention before; in each
> case the IMG tag in the generated page specifies the URL of a resource
> that the browser makes a separate request for. However I'm intrigued
> by your third option, namely "sending the image with the Web page". By
> this, do you mean sending back a multipart message that includes both
> the HTML page and the generated image?
May be he talks about the data: URL scheme. It is described in RFC 2397
at your favourite RFC mirror (e. G.
http://www.ics.uci.edu/pub/ietf/uri/rfc2397.txt or any other).
This URL scheme allows direct inclusion of the ressource into the URL.
An Example can be seen at
http://www.delegate.org/delegate/sample/data-url.html
Note, I don't know any serious usage of this scheme, and my favourite
Browser Opera does not (yet) support it. :-(
So I wouldn't advise any web designer to use it, but for some special
applications it may be an appropriate possibility.
markus
--
"The strength of the Constitution lies entirely in the determination of
each citizen to defend it. Only if every single citizen feels duty
bound to do his share in this defense are the constitutional rights
secure." -- Albert Einstein
More information about the Python-list
mailing list