Re: Displaying Images in MultiLineLabel

2008-09-09 Thread Johannes Dorn

Thanks for your answer.
I have adjusted the src to point back to the application.
It is pointing to this class:

public class ViewImg extends WebPage {

private static final long serialVersionUID = 1L;

public ViewImg(final PageParameters parameters) {
String siteId = parameters.getString("id");
		String url = Settings.getInstance().getSvnURL() + "/" + "graphiken/"  
+ siteId;

StaticImage image = new StaticImage("image", new Model(url));
add(image);
}
}

ViewImg loads and displays the image correctly, if i open the WebPage  
directly. However, it does not embed the image in the output of the  
MultiLineLabel. I am very new to Wicket, so i don't know how to use  
servlets or a wicket resource. Any hints, how i would use them?


Greetings
Johannes Dorn

Am 09.09.2008 um 15:47 schrieb <[EMAIL PROTECTED]>:

You could adjust the src attribute on rendering, so it points back  
to your web application.
You can use a servlet or a wicket resource to load the image date  
from your svn and serve its contents to the browser.


Sven

Johannes Dorn schrieb:


Hello,
i have a problem with my wicket application.
It loads files containing wiki-syntax from a svn repository. The wiki-
syntax is then converted into HTML and displayed by the application by
a MultilineLabel.
The wiki-syntax can reference images, which are also stored in the svn
repository. After converting the wiki-text to html, i get an  
<img>

tag. Its src references the correct file in the svn repository.
The problem is, that the img tag is handled by the clients browser,
which does not have access to the svn repository.
So, the clients browser will ask for login information. I changed the
wiki-converting method so that it adds the svn username and password
to the img tag. However, now the browser will ask for confirmation for
opening an url with a username. Also, Firefox will display the
username and password in the images properties, which should be hidden
from the user.
The question is, how can i let the application handle the image  
loading?


Greetings
Johannes Dorn

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Displaying Images in MultiLineLabel

2008-09-09 Thread Johannes Dorn

Hello,
i have a problem with my wicket application.
It loads files containing wiki-syntax from a svn repository. The wiki- 
syntax is then converted into HTML and displayed by the application by  
a MultilineLabel.
The wiki-syntax can reference images, which are also stored in the svn  
repository. After converting the wiki-text to html, i get an   
tag. Its src references the correct file in the svn repository.
The problem is, that the img tag is handled by the clients browser,  
which does not have access to the svn repository.
So, the clients browser will ask for login information. I changed the  
wiki-converting method so that it adds the svn username and password  
to the img tag. However, now the browser will ask for confirmation for  
opening an url with a username. Also, Firefox will display the  
username and password in the images properties, which should be hidden  
from the user.

The question is, how can i let the application handle the image loading?

Greetings
Johannes Dorn

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]