...
> If I have a JLabel or a JTextEditor component with the following
> caption
> <html><img src=http://192.168.1.1/image.jpg></html>
the src needs to be inside quotes to be valid HTML,
<html><img src='http://192.168.1.1/image.jpg'></html>
..and from memory, it needs a <body> element..
<html><body><img src='http://192.168.1.1/image.jpg'></body></html>
> is there any way I control the http connection that will do the loading
> of the image from the webserver?
> I would like to add a cookie for session tracking purposes to the
> automatically created connection.
You can send parameters to the server inside the URL.
src='http://192.168.1.1/image.jpg?compression=9&size=800'
( I am not sure if that answers your question,
I am not entirely clear what you mean. )
Andrew T.
Yar - 03 Aug 2006 22:14 GMT
Thanks Andrew,
What i was looking for was to override the standard behavior for
downloading the images from HTML based Swing Text components.
I found my answer: the ImageView class does the work. By overriding it
I can do what i want, and authenticating to the webserver if necessary,
inserting session tracking cookies if necessary.
Need also to override the HTMLEditorKit for it to return the correct
ImageView class
Aron
> ...
> > If I have a JLabel or a JTextEditor component with the following
[quoted text clipped - 22 lines]
>
> Andrew T.