JohannaMos
10-15-2004, 04:24 AM
Hello everybody!
I have a problem concerning servlets:
I want to display a chart (*.jpeg) and HTML-tags (a table filled with values) one a servlet.
The problem is (at least I think this is the problem): you can't use response.setContentType("text/html") and response.setContentType("image/jpeg") together. Is this right?
So how would I get the image into the page?
I thought of something like creating one servlet with content type "image" and one servlet with content type "text" which calls the chart-servlet.
Would this work?
And what would the html-tag to call the image be? Is it the <img> tag?
Thanks in advance, Johanna
I have a problem concerning servlets:
I want to display a chart (*.jpeg) and HTML-tags (a table filled with values) one a servlet.
The problem is (at least I think this is the problem): you can't use response.setContentType("text/html") and response.setContentType("image/jpeg") together. Is this right?
So how would I get the image into the page?
I thought of something like creating one servlet with content type "image" and one servlet with content type "text" which calls the chart-servlet.
Would this work?
And what would the html-tag to call the image be? Is it the <img> tag?
Thanks in advance, Johanna