Probably best to mount the resource in your app init method so that it
has a static path and then use that in your CSS.
That, or you can use the text templating to inject the dynamic URL
into templated CSS. Then you could just use urlFor to get the URL.
--
Jeremy Thomerson
See (Buffered)DynamicImageResource.
Pass this resource to RequestCycle.urlFor(), this will return a context
relative path to the resource.
To pass that path to the .css you could use
org.apache.wicket.util.template.CssTemplate
Note: The path to the image in the .css must be relative to the .css
yup! works great
actually I had to use e.getCause() instanceof...
thanks (as usual) for the excellent help!
ryan
On Jun 23, 2009, at 11:19 PM, Igor Vaynberg wrote:
have you tried
class myrequestcycle extends webrequestcycle {
onruntimeexception(e) {
if (e instanceof
Thanks Igor.
-Original Message-
From: Igor Vaynberg [mailto:igor.vaynb...@gmail.com]
Sent: Friday, June 26, 2009 5:09 PM
To: users@wicket.apache.org
Subject: Re: Using validators to validate page parameters
Validatable v=new Validatable(value);
new FooValidator().validate(v);
Hi Wicketians,
i have a problem with AjaxSelfUpdatingTimerBehavior.
I have added an AjaxSelfUpdatingTimerBehavior to a page, because of a
background-thread running very long and the
page checks (an AjaxSelfUpdatingTimerBehavior with 10 sec interval added at
thread start to page) for the
Am 29.06.2009 um 10:22 schrieb Tokalak Ahmet:
Hi Wicketians,
i have a problem with AjaxSelfUpdatingTimerBehavior.
I have added an AjaxSelfUpdatingTimerBehavior to a page, because of
a background-thread running very long and the
page checks (an AjaxSelfUpdatingTimerBehavior with 10 sec
Thanks for that hint.
Do you know how many images wicket-slides/SmoothGallery support? I will
have galleries with thousands of pictures...
Regards,
Johannes
francisco treacy wrote:
Once you have your images sorted you may want to have a look at:
http://code.google.com/p/wicket-slides/
Thank you Martin for your quick answer.
I think the problem is caused by the background-thread.
I do start the thread with a low priority and as daemon but the application
seems still waiting for the termination of the started thread.
Very strange
Von:
Figured this one out, thanks Igor.
Our pages extended from a base page that was manually injecting
services -- I'm not sure why -- so the components were getting the
proxy and pages were getting the direct instance. I fixed this and
things work perfectly now.
Thanks for your help.
On Fri, Jun
Igor,
Can you give me some direction on how to go about getting the e.
In my own RequestCycle I've done the following:
@Override
protected void logRuntimeException(RuntimeException e) {
super.logRuntimeException(e);
log.error(e);
}
Which doesn't help because I'm just
you can set up another appender that writes to a file and get it out
by name and write into it. alternatively you can print the stacktrace
into a buffer and email the whole thing manually.
usually smtp appenders should buffer X lines or Y seconds and send
that out, maybe you can just tweak the
Hi all,
Using 1.3.6, I've recently been simplifying some of my wicket code by using
LoadableDetachableModels and PropertyModels instead of trying to manage
static models in various ways.
I had a strange and subtle bug caused by the fact that a form button update
call into the next layer would
If you simply call log.error(e), your log will only contain e.toString(),
which does not include the stack trace. You need to use the 2-arg version of
log.error() if you want the full trace.
Try this:
log.error(An uncaught runtime exception occurred, e);
jelevy wrote:
Igor,
Can you give
log.runtimeexception is already doing log.error(e.getMessage(), e);
and he is still not seeing the stacktrace...
-igor
On Mon, Jun 29, 2009 at 9:41 AM, mbrictsonm...@55minutes.com wrote:
If you simply call log.error(e), your log will only contain e.toString(),
which does not include the stack
This id is used for event handling. When I moved the setMarkupId statement
into onBeforeRender method, the handler no longer work.
myCom.setMarkupId (getLocalizer().getString (handle, MyPanel.this, new
Model (handleId)));
igor.vaynberg wrote:
set it in onbeforerender
-igor
On Fri, Jun
hello everybody,i am wondering how to invoke refresh of a component with
ajax.
the situation:
i have a listener listening for incoming messages. if a message is fetched,
a method is executed, and I add the message text into a List object.
I then want to refresh the ListView (or the parent
probably because you call getmarkupid() before you call setmarkupid() ?
-igor
On Mon, Jun 29, 2009 at 10:43 AM, OjOfang...@washington.edu wrote:
This id is used for event handling. When I moved the setMarkupId statement
into onBeforeRender method, the handler no longer work.
Likely the message or stacktrace(s) (the actual cause) is throwing the
nullpointer, in which case that is all you can see when logging. You
might wanna try: log.error(whatever here,e.getCause()), generally
the latter is what you're interested in anyway. You might also try:
@Override
protected
Here is another more complex case:
LinkSelection.properties:
edit_label=Edit
done_label=Hide Edit...
linkId=toggle_link_{id}
onclick=toggleEdit('{id}'); return(false);
divId=toggle_div_{id}
LinkSelection.java has the following in the constructor:
@Override
protected void
I wonder if it is possible to simply make getString work for retrieving
localized string in constructor in the next patch. The code would be much
cleaner without the new ResourceModel or getLocalizer().getString
igor.vaynberg wrote:
i just committed a patch for WICKET-1103 which greatly
even if the exception was not being chained it should have still had
some sort of a stacktrace.
-igor
On Mon, Jun 29, 2009 at 11:39 AM, Martijn
Reuversmartijn.reuv...@gmail.com wrote:
Likely the message or stacktrace(s) (the actual cause) is throwing the
nullpointer, in which case that is all
the property files are made for i18n, you are really abusing them. if
you want these things externalized then load them from an external
resource yourself.
-igor
On Mon, Jun 29, 2009 at 12:14 PM, OjOfang...@washington.edu wrote:
Here is another more complex case:
LinkSelection.properties:
no. i18n resources depend on the component hierarchy which is not
known in a constructor of a component.
-igor
On Mon, Jun 29, 2009 at 12:40 PM, OjOfang...@washington.edu wrote:
I wonder if it is possible to simply make getString work for retrieving
localized string in constructor in the next
Hello,
I have implemented Carlo's approach in my base page and wrapped methods
around it to create page parameters and redirect to the previous page. Thank
you for this contribution.
Everything works just fine, but there are some voices on my team that think
that this approach is unnecessary
Sorry, I did not mean to abuse them. I am seeking the right way of getting
String properties associated with a panel class. What do you mean by
externalized? What is an external resource?
igor.vaynberg wrote:
the property files are made for i18n, you are really abusing them. if
you want
i believe page reference has been backported to 1.3 trunk
-igor
On Mon, Jun 29, 2009 at 2:59 PM, kar...@sfkar...@users.sf.net wrote:
Hello,
I have implemented Carlo's approach in my base page and wrapped methods
around it to create page parameters and redirect to the previous page. Thank
Just copy PageReference. That's what we did.
On Mon, Jun 29, 2009 at 5:59 PM, kar...@sfkar...@users.sf.net wrote:
Hello,
I have implemented Carlo's approach in my base page and wrapped methods
around it to create page parameters and redirect to the previous page. Thank
you for this
an external resource can be any file that is not javacode.
eg inside your panel you can do
Properties props=new Properties();
props.load(getClassLoader().getResourceAsStream(getClass().getName().replace(.,/)+.external.properties));
and have a MyPanel.external.properties file next to your
Hi all,
I have recently upgraded my application to wicket 1.4-rc5, and now I
have some troubles with the localization.
With the previous 1.3.6 release I was capable to restrict a localization
message for a validation to only one wicket id e.g. :
in foobar.java
RequiredTextField nameTF = new
OjO,
Ideally, strings or text that users actually see and interact with are
candidates for i18n.
javascript, markup ids, onclick attributes and the like need not be i18n.
This kind of text can strictly be considered part of your codebase.
Remember, strings exist in the i18n properties files to
Hi,
I have quite the same problem using Eclipse WTP and Tomcat : a
NoClassDefFoundError on my template page class, after Tomcat restart or
reload. It works when I manually Clean the module work directory, but it's
boring to do this each time I modify the source code.
Did you finally find a
open a jira issue with a quickstart attached.
-igor
2009/6/29 Major Péter majorpe...@sch.bme.hu:
Hi all,
I have recently upgraded my application to wicket 1.4-rc5, and now I have
some troubles with the localization.
With the previous 1.3.6 release I was capable to restrict a localization
Can't anyone help me with my problem?
Many thanks in advance ! Marieke
Marieke Vandamme-2 wrote:
Hello,
I'm using the following setup with markup inheritance
ParentPage.java extends WebPage
ChildPage.java extends ParentPage.java
In the constructor of my ParentPage I want the
add(new webmarkupcontainer(body) { istransparentresolver() { return
true; } oncomponenttag(tag) { tag.put(id,foo); }});
htmlbody wicket:id=body.../body/html
-igor
On Mon, Jun 29, 2009 at 10:47 PM, Marieke Vandammema...@tvh.be wrote:
Can't anyone help me with my problem?
Many thanks in
34 matches
Mail list logo