That was too easy :)
Vit Rozkovec wrote:
Try this:
public class ExternalImage extends WebComponent
{
/**
* Construct.
*
* @param id
* @param url
*/
public ExternalImage(String id, String url)
{
this(id, new Model(url));
}
/**
* Construct.
*
* @param id
* @param model
*/
public ExternalImage(String id, IModel model)
{
super(id, model);
}
@Override
protected void onComponentTag(ComponentTag tag)
{
super.onComponentTag(tag);
checkComponentTag(tag, "img");
tag.put("src", getModelObjectAsString());
}
}
Vitek
Prag wrote:
I have a DB table that contains plain URL's in text like
http://someExternalServer/blabla/1.jpg.
How can I put this plain text URL in a HTML IMG elements' SRC attribute
without Wicket making modifications to the URL?
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org