6 messages in org.python.python-listhow to display an HTML <img scr> tag ...| From | Sent On | Attachments |
|---|---|---|
| Jay | 11 Feb 2003 09:42 | |
| Peter Hansen | 11 Feb 2003 09:51 | |
| Jay | 12 Feb 2003 04:23 | |
| Peter Hansen | 12 Feb 2003 05:58 | |
| Jose Galvez | 12 Feb 2003 08:56 | |
| Peter Hansen | 12 Feb 2003 09:12 |
| Subject: | how to display an HTML <img scr> tag using Python...![]() |
|---|---|
| From: | Jose Galvez (jjga...@ucdavis.edu) |
| Date: | 02/12/2003 08:56:07 AM |
| List: | org.python.python-list |
Take a look at webware
Jose "Peter Hansen" <peter at engcorp.com> wrote in message news:3E4A531F.B1B00106 at engcorp.com...
Jay wrote:
using
print '<html tags here>'
you can use html tags that can be displayed on screen. But when using print '<img src"file.jpg">'
Correction: you are missing an equal sign after the attribute name.
print '<img src="file.jpg">'
Now the key question is this: where is file.jpg? I suspect it needs to be in the same place as the script is, but that might not be allowed by the server configuration. Therefore you might want to point to it in a different way. I'd suggest experimenting with the location of the file and trying multiple links like "../file.jpg" and "../images/file.jpg" and "/file.jpg" and "/~youruserid/file.jpg" or whatever until you get it right.
Sorry about being too ambigous, I'm new at this groups thing..
More information is always better when you're new. Just picture what information we don't have and try to fill us in. What's the name of the script, how are you referencing it from the original HTML file, what directory structure do you have, etc... not that all or any of these specific questions are necessarily useful in this case.
Also try always to show the *exact* code you are trying to run (though perhaps not all of it... don't post more than twenty lines if fewer is enough to get the point across). Otherwise we are stuck trying to interpret stuff that might not actually have the problem because you mistyped it. For example, did you really leave out the "=" in the original, or was it just a typo here?
-Peter




