Custom Component

2010-12-16 Thread Dieter Bogdoll
Hello Wicket users,

I have a question about custom components. I need some more interactive
behaviour for this component
and decided to use a java applet for this. The user of the component
shouldn't be aware of that
fact. This component should display some data using JFreeChart. After the
applet is started it should
load some data via an input stream and display this data.

My idea was that the user has to overwrite a method in my custom component
which delivers this stream.
But how can I access now this stream from the applet, e.g. how can I create
an URL which points to
my component so that this method of the user is called? Thats my real
question: how to get a URL which
downloads a stream.

I think the principle would be like the image wicket tag. Where the image
wicket component provides an url
for the browser to download the image data. I tried to understand how it
works, but I didn't found much of
documentation for this? Perhaps there is some documentation and I only need
some pointer to them?

Best regards,
Dieter


Re: Custom Component

2010-12-16 Thread Ernesto Reinaldo Barreiro
Dieter,

Maybe you could use a technique similar to the one shown at [1]. That
is,  make something on your page implement IResourceListener an use
that as a context to serve your data.

Regards,

Ernesto

1-https://cwiki.apache.org/WICKET/displaying-content-eg-pdf-excel-word-in-an-iframe.html

On Thu, Dec 16, 2010 at 9:31 AM, Dieter Bogdoll bogd...@googlemail.com wrote:
 Hello Wicket users,

 I have a question about custom components. I need some more interactive
 behaviour for this component
 and decided to use a java applet for this. The user of the component
 shouldn't be aware of that
 fact. This component should display some data using JFreeChart. After the
 applet is started it should
 load some data via an input stream and display this data.

 My idea was that the user has to overwrite a method in my custom component
 which delivers this stream.
 But how can I access now this stream from the applet, e.g. how can I create
 an URL which points to
 my component so that this method of the user is called? Thats my real
 question: how to get a URL which
 downloads a stream.

 I think the principle would be like the image wicket tag. Where the image
 wicket component provides an url
 for the browser to download the image data. I tried to understand how it
 works, but I didn't found much of
 documentation for this? Perhaps there is some documentation and I only need
 some pointer to them?

 Best regards,
 Dieter


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Datatable/Dataview filtering problem

2010-12-16 Thread saschaleier

Hi all,

i have a problem implementing filters to my datatable.
What i want is a filter reacting on changes in the filter textfields.  
Let me call it 'live-filter'. So when you type, the table is filtered  
via dataprovider.


I implemented the filter from the phonebook example, but this method  
just reacts on form submit.


The next thing i tried is using a dataview instead of a datatable so i  
can reach directly the filter textfields. Then i added a  
AjaxOnUpdateBehavior to them, which submits the filterform via  
'AjaxRequestTarget'.appendJavascript(document.formxy.submit();).


The problem resulting: too many database queries in too short  
intervals. Sometimes he ignored letters from the textfield when you  
type a little bit faster.


so i tried implementing java.util.Timer with a little delay. So my  
thought was that you type sth and after the delay it begins to call  
the database filtering with everything you typed so far.


But when i schedule a timertask, nothing ever happens. The interesting  
thing is that logs from within the timertask's run() method are  
displayed to the console.


It seems that only the formsubmit(appendjavascript) is ignored.

Could it be that it does nothing because of the extra thread started  
for the Timer?


Do you know any solutions?

Or do you know any 'normal' and better ways to implement such a 'live'filter?


Thanks

Sascha


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: help me please!!! Wicket/Spring/Hibernate configuration woes

2010-12-16 Thread adam.gibbons

Yes, at both the Service and DAO level. It's in the code I posted! :)


On 15 December 2010 20:15, James Carman [via Apache Wicket] 
ml-node+3089806-1760738882-201...@n4.nabble.comml-node%2b3089806-1760738882-201...@n4.nabble.com
 wrote:

 You also need to make sure you've set up your transactions properly.
 Are you using the @Transactional annotations?

 On Wed, Dec 15, 2010 at 11:40 AM, adam.gibbons [hidden 
 email]http://user/SendEmail.jtp?type=nodenode=3089806i=0
 wrote:

 
  Hi Hielke,
 
  Thank you for the helpful reply. :) But I think I already have those in
 my
  applicationConext.xml...:
 
 
  ?xml version=1.0 encoding=UTF-8?
  beans
 xmlns=http://www.springframework.org/schema/beans;
 xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
 xmlns:aop=http://www.springframework.org/schema/aop;
 xmlns:tx=http://www.springframework.org/schema/tx;
 xmlns:context=http://www.springframework.org/schema/context;
 xsi:schemaLocation=
 http://www.springframework.org/schema/beans
  http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
 http://www.springframework.org/schema/aop
  http://www.springframework.org/schema/aop/spring-aop-2.5.xsd
 http://www.springframework.org/schema/tx
  http://www.springframework.org/schema/tx/spring-tx-2.5.xsd
 http://www.springframework.org/schema/context
  http://www.springframework.org/schema/context/spring-context-2.5.xsd
 
 default-autowire=byType
 default-lazy-init=false
 
 bean id=wicketApplication
  class=uk.co.company.product.presentation.wicket.app.WicketApplication
 /
 
 bean id=placeholderConfigurer
 
 class=org.springframework.beans.factory.config.PropertyPlaceholderConfigurer

  autowire=byName
 property name=ignoreUnresolvablePlaceholders value=false /
 property name=systemPropertiesModeName
  value=SYSTEM_PROPERTIES_MODE_OVERRIDE /
 property name=ignoreResourceNotFound value=false /
 property name=locationslist
 valueclasspath*:/application.properties/value
 /list/property
 /bean
 
 bean id=dataSource
  class=org.springframework.jdbc.datasource.DriverManagerDataSource
  autowire=byName
 property
  name=driverClassNamevalue${jdbc.driver}/value/property
 property name=urlvalue${jdbc.url}/value/property
 property
 name=usernamevalue${jdbc.username}/value/property
 property
 name=passwordvalue${jdbc.password}/value/property
 /bean
 
 tx:annotation-driven transaction-manager=txManager /
 
 bean id=txManager
  class=org.springframework.orm.hibernate3.HibernateTransactionManager
  autowire=byName
 property name=sessionFactory ref=sessionFactory /
 /bean
 
 !--bean id=interceptor
  class=com.mycompany.hibernate.HibernateInterceptor
 /bean--
 
 bean id=sessionFactory
 
 class=org.springframework.orm.hibernate3.annotation.AnnotationSessionFactoryBean

  autowire=byName
 property name=dataSource ref=dataSource /
 property name=hibernateProperties
 props
 !-- GENERAL --
 prop key=hibernate.dialect${hibernate.dialect}/prop
 prop key=hibernate.show_sqltrue/prop
 prop key=hibernate.show_sqlhibernate.format_sql/prop

 prop key=hibernate.default_schemazen_template/prop
 prop key=hibernate.max_fetch_depth2/prop
 !-- prop
  key=hibernate.default_batch_fetch_size16/prop --
 prop key=hibernate.default_entity_modepojo/prop
 prop key=hibernate.order_updatestrue/prop
 prop key=hibernate.generate_statisticstrue/prop
 prop key=hibernate.use_identifier_rollbacktrue/prop
 prop
  key=hibernate.current_session_context_classthread/prop
 prop key=hibernate.use_outer_jointrue/prop
 !-- JDBC --
 !-- prop key=hibernate.jdbc.batch_size20/prop --
 !-- prop
  key=hibernate.jdbc.batch_versioned_datatrue/prop --
 prop
  key=hibernate.jdbc.use_streams_for_binarytrue/prop
 prop
  key=hibernate.jdbc.use_get_generated_keystrue/prop
 !-- CONNECTION --
 prop key=hibernate.connection.isolation8/prop!--
  TRANSACTION_SERIALIZABLE --
 prop key=hibernate.connection.autocommitfalse/prop
 prop key=hibernate.connection.pool_size5/prop
 !-- CACHE --
 !-- prop
 
 key=hibernate.cache.provider_classorg.hibernate.cache.EhCacheProvider/prop

  --
 !-- prop
  key=hibernate.cache.use_minimal_putstrue/prop --
 !-- prop
 key=hibernate.cache.use_query_cachetrue/prop
  --
  !-- MISCELLANEOUS --
  prop
  key=hibernate.bytecode.use_reflection_optimizertrue/prop
 prop
  key=hibernate.cglib.use_reflection_optimizertrue/prop
  

Re: Wicket resources (css, js and images)?

2010-12-16 Thread Martin Grigorov
I believe the latest changes by Jeremy added functionality for this.

Jeremy can you please explain how the
new org.apache.wicket.markup.html.IHeaderResponseDecorator can be used (is
being used by your customer) ?


On Wed, Dec 15, 2010 at 9:05 PM, Alex Objelean alex.objel...@gmail.comwrote:


 Though this topic is quite old, I think it is still actual. Since the 1.5
 release is not far away, did anybody thought if the (at least) js resource
 merging should occur?

 This is very useful when you have a page with a large number of components,
 each loading a large number of small resources. Having a single resource
 (js
 and/or css) as a result of page rendering could have a dramatic page
 loading
 time improvement.

 Thanks!
 Alex Objelean
 --
 View this message in context:
 http://apache-wicket.1842946.n4.nabble.com/Wicket-resources-css-js-and-images-tp1868800p3089781.html
 Sent from the Users forum mailing list archive at Nabble.com.

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




Re: jquery ui dialog and ajax component updating

2010-12-16 Thread jensiator

Thanks. Now I got it working. 
I got a panel that contains an test ajaxlink and a dialog(also in a panel). 
My problem was that when the outer panel got ajax updated, then the
dialogpanel could not find the javascript in the headerpart. And if I added
the javascript in pResponse.renderOnDomReadyJavascript I got the multiple
dialog divs. This code solves that problem. Thanks for the 'destroy' hint 
In my dialog panel:
@Override
public void renderHead(IHeaderResponse pResponse) {
pResponse.renderJavascript($('#+Dialog.this.getMarkupId(true)+').dialog('destroy').remove();,
null);
pResponse.renderOnDomReadyJavascript($(function() {$(
'#+Dialog.this.getMarkupId(true)+' ).dialog({autoOpen:
false,width:'auto',height:'auto',resizable: false});}));


}

-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/jquery-ui-dialog-and-ajax-component-updating-tp1857058p3090654.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Apache Wicket : Please Help.

2010-12-16 Thread Samaporn Ch.
Please help me to solve this problem.

 

App server : Websphere   DB : db2   IDE : eClipe

 

12/2/10 15:54:28:415 ICT] 0023 WebAppE   [Servlet Error]-[Error
while finishing the connection]: java.lang.OutOfMemoryError

at
java.io.ByteArrayOutputStream.write(ByteArrayOutputStream.java:116)

at
java.io.ObjectOutputStream$BlockDataOutputStream.drain(ObjectOutputStream.ja
va:1791)

at
java.io.ObjectOutputStream$BlockDataOutputStream.flush(ObjectOutputStream.ja
va:1736)

at java.io.ObjectOutputStream.flush(ObjectOutputStream.java:706)

at java.io.ObjectOutputStream.close(ObjectOutputStream.java:727)

at
org.apache.wicket.util.io.IObjectStreamFactory$2.close(IObjectStreamFactory.
java:146)

at
org.apache.wicket.util.lang.Objects.objectToByteArray(Objects.java:1097)

at
org.apache.wicket.protocol.http.pagestore.AbstractPageStore.serializePage(Ab
stractPageStore.java:197)

at
org.apache.wicket.protocol.http.pagestore.DiskPageStore.prepareForSerializat
ion(DiskPageStore.java:1156)

at
org.apache.wicket.protocol.http.SecondLevelCacheSessionStore$SecondLevelCach
ePageMap.writeObject(SecondLevelCacheSessionStore.java:382)

at sun.reflect.GeneratedMethodAccessor615.invoke(Unknown Source)

at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
.java:43)

at java.lang.reflect.Method.invoke(Method.java:618)

at
java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:1007)

at
java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1445)

at
java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1396)

at
java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1125)

at
java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:342)

at java.util.Hashtable.writeObject(Hashtable.java:763)

at java.util.Hashtable.writeObject(Hashtable.java:748)

at sun.reflect.GeneratedMethodAccessor11.invoke(Unknown Source)

at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
.java:43)

at java.lang.reflect.Method.invoke(Method.java:618)

at
java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:1007)

at
java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1445)

at
java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1396)

at
java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1125)

at
java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:342)

at
com.ibm.ws.webcontainer.httpsession.BackedHashtable.commonSetup(BackedHashta
ble.java:2231)

at
com.ibm.ws.webcontainer.httpsession.BackedHashtable.persistSession(BackedHas
htable.java:2435)

at
com.ibm.ws.webcontainer.httpsession.BackedHashtable.ejbStore(BackedHashtable
.java:2643)

at
com.ibm.ws.webcontainer.httpsession.BackedHashtable.storeSession(BackedHasht
able.java:2276)

at
com.ibm.ws.webcontainer.httpsession.BackedHashtable.put(BackedHashtable.java
:2915)

at
com.ibm.ws.webcontainer.httpsession.DatabaseSessionContext.sync(DatabaseSess
ionContext.java:158)

at
com.ibm.ws.webcontainer.httpsession.SessionData.releaseSession(SessionData.j
ava:301)

at
com.ibm.ws.webcontainer.httpsession.SessionContext.sessionPostInvoke(Session
Context.java:3066)

at
com.ibm.ws.webcontainer.srt.SRTRequestContext.finish(SRTRequestContext.java:
105)

at
com.ibm.ws.webcontainer.srt.SRTServletRequest.finish(SRTServletRequest.java:
2067)

at
com.ibm.ws.webcontainer.srt.SRTConnectionContext.finishConnection(SRTConnect
ionContext.java:68)

at
com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:912)

at
com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1478)

at
com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:133)

at
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(Ht
tpInboundLink.java:458)

at
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(Ht
tpInboundLink.java:387)

at
com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLRea
dCallback.java:102)

at
com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioRea
dCompletionListener.java:165)

at
com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java
:217)

at
com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture
.java:161)

at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)

at

SV: Apache Wicket : Please Help.

2010-12-16 Thread Wilhelmsen Tor Iver
 12/2/10 15:54:28:415 ICT] 0023 WebAppE   [Servlet Error]-[Error
 while finishing the connection]: java.lang.OutOfMemoryError

Increase heap using the -Xmx parameter, or if that does not help look for 
common causes for runaway page stores like having Page pointers in other Pages 
instead of PageReferences.


- Tor Iver


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: jquery ui dialog and ajax component updating

2010-12-16 Thread jensiator

Even better
IRequestTarget target = RequestCycle.get().getRequestTarget();
 if(target instanceof AjaxRequestTarget) {

pResponse.renderJavascript($('#+Dialog.this.getMarkupId(true)+').dialog('destroy').remove();,
null);
 }
pResponse.renderOnDomReadyJavascript($(function() {$( '# +
Dialog.this.getMarkupId(true)
+ ' ).dialog({autoOpen: 
false,width:'auto',height:'auto',resizable:
false});}));
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/jquery-ui-dialog-and-ajax-component-updating-tp1857058p3090717.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket resources (css, js and images)?

2010-12-16 Thread Jeremy Thomerson
Yes, I will do a good writeup of what we are able to accomplish now.  I'll
try to get that sent out tomorrow.

-- 
Jeremy Thomerson
http://wickettraining.com
*Need a CMS for Wicket?  Use Brix! http://brixcms.org*


On Thu, Dec 16, 2010 at 4:36 AM, Martin Grigorov mgrigo...@apache.orgwrote:

 I believe the latest changes by Jeremy added functionality for this.

 Jeremy can you please explain how the
 new org.apache.wicket.markup.html.IHeaderResponseDecorator can be used (is
 being used by your customer) ?


 On Wed, Dec 15, 2010 at 9:05 PM, Alex Objelean alex.objel...@gmail.comwrote:


 Though this topic is quite old, I think it is still actual. Since the 1.5
 release is not far away, did anybody thought if the (at least) js resource
 merging should occur?

 This is very useful when you have a page with a large number of
 components,
 each loading a large number of small resources. Having a single resource
 (js
 and/or css) as a result of page rendering could have a dramatic page
 loading
 time improvement.

 Thanks!
 Alex Objelean
 --
 View this message in context:
 http://apache-wicket.1842946.n4.nabble.com/Wicket-resources-css-js-and-images-tp1868800p3089781.html
 Sent from the Users forum mailing list archive at Nabble.com.

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org





Re: Page mounting

2010-12-16 Thread Pedro Santos
you can mount AdminLogin to some Login.class extension like
class AdminLogin extends Login{
   constructor(){
  super(someParameters);
   }
}

On Wed, Dec 15, 2010 at 9:42 PM, Jeffrey Schneller 
jeffrey.schnel...@envisa.com wrote:

 I think this was discussed here but I can't seems to find it so I will
 ask again.



 I would like to mount a page Login to Login.class.  I know how to do
 this and have it working.



 Now I would like to mount a page called AdminLogin to Login.class but
 also pass a parameter to Login.class so that I can change the login form
 but still use the same page.



 Is this possible?  How would I do this?



 Thanks.








-- 
Pedro Henrique Oliveira dos Santos


problem with changing css while application is running

2010-12-16 Thread Sam Zilverberg
In my app I have a single css file in my webapp directory(the one that
contains WEB-INF, possible libs and so on).

In my BasePage I contribute this css like this:
   add(CSSPackageResource.getHeaderContribution(urs.css));
If I want to edit this css and change some stuff while the application is
running I get a write error.

If I move the css file into on the the packages and contribute it like this:

add(CSSPackageResource.getHeaderContribution(WicketApplication.class,urs.css));
I can edit the css while the application is running.

What can I do to be able to edit it while still keeping it in the webapp
directory?


URL coding strategies

2010-12-16 Thread Henrique Boregio
Hello, I am mounting my URLs so I can list product items like so:
http://www.mysite.com/item/id/0
http://www.mysite.com/item/id/1

and so on...then I user this id param to fetch the data from the database.

I am not accesing this page directly. I have another page where the
items are fully listed (the item's title, description, price, etc) and
when the user click on each item, they are redirected to this /item/id
page.

Is there a way to avoid exposing the item's id, but send it behind
the scenes to the next page, so I would have something like:
http://www.mysite.com/item/ITEM_TITLE
eg. http://www.mysite.com/item/Ford-Ranger-Model-2005

In other words, I'm still using the item's id to fetch it from the
database, but the URL shows an SEO friendly version.

Thanks.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Keep focus in ModalWindow

2010-12-16 Thread Frank Klein Koerkamp
Hi all,

currently having a ModalWindow with some tab sequence inside.
But when i 'tab' out of last component inside ModalWindow it goes to the
page, but i like it to start again inside ModalWindow.
I'm missing something or is this possible with some kind of behavior or not
at all?

Kind regards,

Frank Klein Koerkamp


Re: jquery ui dialog and ajax component updating

2010-12-16 Thread Jeremy Thomerson
On Thu, Dec 16, 2010 at 6:04 AM, jensiator jens.alen...@megasol.se wrote:

 Even better
 IRequestTarget target = RequestCycle.get().getRequestTarget();
 if(target instanceof AjaxRequestTarget) {



The easier way to do this is to say:

if (AjaxRequestTarget.get() != null)

-- 
Jeremy Thomerson
http://wickettraining.com
*Need a CMS for Wicket?  Use Brix! http://brixcms.org*


How to emulate an ajax-response with Wicket?

2010-12-16 Thread f a v
Hi.

Is there a way to answer an ajax-response XML asked from a Wicket
application from another?
Let me explain, I have an ajax filled DropDownChoice just like the
example one [1], but it's filled from another webapp generating the
ajax-response XML with a JSP.
Now I need to emulate the ajax-response from another Wicket
application and I wanted to use Wicket instead of JSP. I made a Page
that answers the ajax-response XML. The Page works ok when it's
invoked pasting the URL in a browser. But, when the DropDownChoice
invokes the Page it's redirected to the wrong webapp.
In other words, I have a DropDownChoice in webapp A
(http://example.com/a/dropDownPage), a Page that answers an
ajax-response XML in webapp B (http://example.com/b/AjaxResponsePage,
pasting this URL in a browser works) and when /a/dropDownPage asks for
/b/AjaxResponsePage the browser it's redirected to /a/AjaxResponsePage
(note that it's redirected to /a and not /b) and fails.

Debuging I've found that WebRequestCycle.isRedirect() returns true
when WebRequest.isAjax() is true and that triggers a redirect to
AjaxResponsePage (a relative URL, so the browser is changing the base
URL, not Wicket).
Maybe I'm taking the wrong approach and there is a better way to do it
or there is a simple way to bypass this mechanism and make it work.

[1] http://goo.gl/H7jlG

Thanks!

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: problem with changing css while application is running

2010-12-16 Thread Martin Grigorov
what kind of error do you experience ?

On Thu, Dec 16, 2010 at 3:59 PM, Sam Zilverberg samzilverb...@gmail.comwrote:

 In my app I have a single css file in my webapp directory(the one that
 contains WEB-INF, possible libs and so on).

 In my BasePage I contribute this css like this:
   add(CSSPackageResource.getHeaderContribution(urs.css));
 If I want to edit this css and change some stuff while the application is
 running I get a write error.

 If I move the css file into on the the packages and contribute it like
 this:


 add(CSSPackageResource.getHeaderContribution(WicketApplication.class,urs.css));
 I can edit the css while the application is running.

 What can I do to be able to edit it while still keeping it in the webapp
 directory?



Re: Keep focus in ModalWindow

2010-12-16 Thread Martin Grigorov
it should work out-of-the-box with modalwindow backed by a page
for modalwindow backed by a panel my only idea is to register onkeydown
listener to the last focusable element and set the focus manually to the
first

On Thu, Dec 16, 2010 at 4:12 PM, Frank Klein Koerkamp 
fkleinkoerk...@educator.eu wrote:

 Hi all,

 currently having a ModalWindow with some tab sequence inside.
 But when i 'tab' out of last component inside ModalWindow it goes to the
 page, but i like it to start again inside ModalWindow.
 I'm missing something or is this possible with some kind of behavior or not
 at all?

 Kind regards,

 Frank Klein Koerkamp



Re: problem with changing css while application is running

2010-12-16 Thread Sam Zilverberg
Sorry, I should have been more clear.
I don't get any error on the application side.
I get the error in eclipse. It can't save the css file while the application
is running.
It is pretty annoying because I like making changes to design and then press
refresh in application window to see them.


Re: problem with changing css while application is running

2010-12-16 Thread Matthias Gasser
Do you know firebug, or the safari / chrome developer tools?

Especially firebug is quite convenient, changing styles on the fly...



Am 16.12.2010 um 16:43 schrieb Sam Zilverberg:

 Sorry, I should have been more clear.
 I don't get any error on the application side.
 I get the error in eclipse. It can't save the css file while the application
 is running.
 It is pretty annoying because I like making changes to design and then press
 refresh in application window to see them.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Wicket.Ajax.registerPreCallHandler

2010-12-16 Thread fachhoch

in this precall handler can I retrieve the dom elements which is sending the
request ?
in this precall I handler I call showbusysign function   to  mask page while
ajax request is in process , now for some components I  donot want to call
showbusysign , please advice me is there any way I can mark the component
beofre making request and retieve in this precallhandler and do necessary 
?Please help me , I am  still a child with java script .

-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-Ajax-registerPreCallHandler-tp3091091p3091091.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket.Ajax.registerPreCallHandler

2010-12-16 Thread Alexander Morozov

checkout artifactory sources and check AjaxIndicator implementation.
http://www.jfrog.org/community.php
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-Ajax-registerPreCallHandler-tp3091091p3091105.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: problem with changing css while application is running

2010-12-16 Thread Martin Grigorov
I guess you are running Windows and there is an open file handle to this
file by some process ...
Use Process Explorer to find who is to blame.

On Thu, Dec 16, 2010 at 4:43 PM, Sam Zilverberg samzilverb...@gmail.comwrote:

 Sorry, I should have been more clear.
 I don't get any error on the application side.
 I get the error in eclipse. It can't save the css file while the
 application
 is running.
 It is pretty annoying because I like making changes to design and then
 press
 refresh in application window to see them.



Re: problem with changing css while application is running

2010-12-16 Thread Sam Zilverberg
Matthias:

Yes I use firebug too, but it doesnt save the changes to the original css
file.
So after I make a few tweaks I need to retrace what I've changed and
copy-paste to the original css.

Martin:

When I put the css file inside some package and contribute it like this

add(CSSPackageResource.getHeaderContribution(WicketApplication.class,my.css));
I don't have any problems editing the css from eclipse while the app is
running.

So I'm wondering if there is some way to have the css in the webapp
directory, contribute it without any class or package scope and still be
able to edit it while the app is running.


Re: URL coding strategies

2010-12-16 Thread Andrea Del Bene

Hi Henrique,

are you using a custom WebRequestCodingStrategy implementation? This 
class should let you encode visible URL as you prefer.

Hello, I am mounting my URLs so I can list product items like so:
http://www.mysite.com/item/id/0
http://www.mysite.com/item/id/1

and so on...then I user this id param to fetch the data from the database.

I am not accesing this page directly. I have another page where the
items are fully listed (the item's title, description, price, etc) and
when the user click on each item, they are redirected to this /item/id
page.

Is there a way to avoid exposing the item's id, but send it behind
the scenes to the next page, so I would have something like:
http://www.mysite.com/item/ITEM_TITLE
eg. http://www.mysite.com/item/Ford-Ranger-Model-2005

In other words, I'm still using the item's id to fetch it from the
database, but the URL shows an SEO friendly version.

Thanks.

-
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



Re: URL coding strategies

2010-12-16 Thread Bas Gooren

There are two ways to achieve what you are looking for:

1) store a stable, unique textual identifier per product (e.g. 
Ford-Ranger-Model-2005), and lookup the product from this identifier
2) store a textual identifier - ID mapping in your session and do the 
lookup when the page is accessed; of course this mapping needs to be created 
at some point in time so the product page can lookup the proper product ID.


Option (2) is rather clumsy as it requires a session for a url that looks 
stateless/bookmarkable. Also, you cannot get around the fact that you need 
to be able to identify the product somehow.


I'd suggest you take a close look at option (1).

In general sending it behind the scenes is impossible in the way you are 
thinking about it. How would you handle the case that the user bookmarks 
said item-url, and instead of going to your list page goes to the product 
page directly? That way the only contextual information you have is what is 
in the url.


Good luck.

Bas

- Original Message - 
From: Henrique Boregio hbore...@gmail.com

To: users@wicket.apache.org
Sent: Thursday, December 16, 2010 4:05 PM
Subject: URL coding strategies



Hello, I am mounting my URLs so I can list product items like so:
http://www.mysite.com/item/id/0
http://www.mysite.com/item/id/1

and so on...then I user this id param to fetch the data from the database.

I am not accesing this page directly. I have another page where the
items are fully listed (the item's title, description, price, etc) and
when the user click on each item, they are redirected to this /item/id
page.

Is there a way to avoid exposing the item's id, but send it behind
the scenes to the next page, so I would have something like:
http://www.mysite.com/item/ITEM_TITLE
eg. http://www.mysite.com/item/Ford-Ranger-Model-2005

In other words, I'm still using the item's id to fetch it from the
database, but the URL shows an SEO friendly version.

Thanks.

-
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



How to tackle field labels when using CompoundPropertyModels?

2010-12-16 Thread Matthias Keller

Hi

This is an issue I frequently run into and I haven't found a good 
solution yet:

I've got a Form using a CompoundPropertyModel and having lots of fields.
The easy way to do these fields is:
form.add(new RequiredTextFieldString(name));

The model object has a getter and setter for name, so all works well.
Unfortunately, when the user doesn't enter a valid value, the Required 
error message shows up saying something like Field 'name' is required.
I could have a resource key name in my translations but this has the 
limitation, that all name fields in my whole app are translated the 
same way. Maybe one name is a human name, the other one is a machine 
name which have different translations...
Is there an easy way to tackle this problem? For example have a prefix 
prepended to the field name or something else? One thing I want to avoid 
is to set an explicit label model for every field and if possible I'm 
hoping to avoid having to create different TextField subclasses for all 
my pages just prepending that string


How do you do this for large applications?
Currently, we're reverting to
form.add(new RequiredTextFieldString(somepage.name, new 
PropertyModelString(model, name)));

which kinda defeats the whole CompoundPropertyModel stuff

Thanks a lot

Matt



smime.p7s
Description: S/MIME Cryptographic Signature


Re: How to tackle field labels when using CompoundPropertyModels?

2010-12-16 Thread James Carman
You can use page or component scoped messages.

On Thu, Dec 16, 2010 at 11:48 AM, Matthias Keller
matthias.kel...@ergon.ch wrote:
 Hi

 This is an issue I frequently run into and I haven't found a good solution
 yet:
 I've got a Form using a CompoundPropertyModel and having lots of fields.
 The easy way to do these fields is:
 form.add(new RequiredTextFieldString(name));

 The model object has a getter and setter for name, so all works well.
 Unfortunately, when the user doesn't enter a valid value, the Required error
 message shows up saying something like Field 'name' is required.
 I could have a resource key name in my translations but this has the
 limitation, that all name fields in my whole app are translated the same
 way. Maybe one name is a human name, the other one is a machine name which
 have different translations...
 Is there an easy way to tackle this problem? For example have a prefix
 prepended to the field name or something else? One thing I want to avoid is
 to set an explicit label model for every field and if possible I'm hoping to
 avoid having to create different TextField subclasses for all my pages just
 prepending that string

 How do you do this for large applications?
 Currently, we're reverting to
 form.add(new RequiredTextFieldString(somepage.name, new
 PropertyModelString(model, name)));
 which kinda defeats the whole CompoundPropertyModel stuff

 Thanks a lot

 Matt



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: How to tackle field labels when using CompoundPropertyModels?

2010-12-16 Thread Matthias Keller

Hi James

Do you mean page or component scoped message properties files? Like 
MyPage.properties?
Unfortunately I don't see that as a solution because this would produce 
hundreds or properties files which would be a real nightmare to maintain 
(our customer wants *very* frequent text changes which are way easier to 
do if all translations are in one big file and also enables us to just 
send the customer one file for translation instead of hundreds).

Or is there another way to specify a prefix for a given component?

Thanks

Matt

On 2010-12-16 17:51, James Carman wrote:

You can use page or component scoped messages.

On Thu, Dec 16, 2010 at 11:48 AM, Matthias Keller
matthias.kel...@ergon.ch  wrote:

Hi

This is an issue I frequently run into and I haven't found a good solution
yet:
I've got a Form using a CompoundPropertyModel and having lots of fields.
The easy way to do these fields is:
form.add(new RequiredTextFieldString(name));

The model object has a getter and setter for name, so all works well.
Unfortunately, when the user doesn't enter a valid value, the Required error
message shows up saying something like Field 'name' is required.
I could have a resource key name in my translations but this has the
limitation, that all name fields in my whole app are translated the same
way. Maybe one name is a human name, the other one is a machine name which
have different translations...
Is there an easy way to tackle this problem? For example have a prefix
prepended to the field name or something else? One thing I want to avoid is
to set an explicit label model for every field and if possible I'm hoping to
avoid having to create different TextField subclasses for all my pages just
prepending that string

How do you do this for large applications?
Currently, we're reverting to
form.add(new RequiredTextFieldString(somepage.name, new
PropertyModelString(model, name)));
which kinda defeats the whole CompoundPropertyModel stuff

Thanks a lot

Matt







smime.p7s
Description: S/MIME Cryptographic Signature


Re: How to tackle field labels when using CompoundPropertyModels?

2010-12-16 Thread Bas Gooren

Hi Matthias,

There are several options, but most importantly: there is special handling 
for this on FormComponent (see LabeledWebMarkupContainer).
You could either scope the fields by setting translations per page/panel, 
but this can get rather tedious.


Another option is to create specialized label models for your form 
components, which lookup the type of object in the CompoundPropertyModel and 
use it as a prefix when looking up a translation.


E.g.

new CompoundPropertyModelX(...)
new FormComponent(name) under this CPM.

Such a label model would then detect the CPM and use a translation key of 
X.name;


You could even implement this transparantly by either using a visitor on the 
form or a component instantiation listener.


Hope this helps.

Bas

- Original Message - 
From: Matthias Keller matthias.kel...@ergon.ch

To: Wicket List users@wicket.apache.org
Sent: Thursday, December 16, 2010 5:48 PM
Subject: How to tackle field labels when using CompoundPropertyModels?


Hi

This is an issue I frequently run into and I haven't found a good
solution yet:
I've got a Form using a CompoundPropertyModel and having lots of fields.
The easy way to do these fields is:
form.add(new RequiredTextFieldString(name));

The model object has a getter and setter for name, so all works well.
Unfortunately, when the user doesn't enter a valid value, the Required
error message shows up saying something like Field 'name' is required.
I could have a resource key name in my translations but this has the
limitation, that all name fields in my whole app are translated the
same way. Maybe one name is a human name, the other one is a machine
name which have different translations...
Is there an easy way to tackle this problem? For example have a prefix
prepended to the field name or something else? One thing I want to avoid
is to set an explicit label model for every field and if possible I'm
hoping to avoid having to create different TextField subclasses for all
my pages just prepending that string

How do you do this for large applications?
Currently, we're reverting to
form.add(new RequiredTextFieldString(somepage.name, new
PropertyModelString(model, name)));
which kinda defeats the whole CompoundPropertyModel stuff

Thanks a lot

Matt



smime.p7s
Description: S/MIME cryptographic signature


Re: How to tackle field labels when using CompoundPropertyModels?

2010-12-16 Thread James Carman
You could use a class-qualified key
(com.myco.domain.entity.Person.name=My Name).

On Thu, Dec 16, 2010 at 11:55 AM, Matthias Keller
matthias.kel...@ergon.ch wrote:
 Hi James

 Do you mean page or component scoped message properties files? Like
 MyPage.properties?
 Unfortunately I don't see that as a solution because this would produce
 hundreds or properties files which would be a real nightmare to maintain
 (our customer wants *very* frequent text changes which are way easier to do
 if all translations are in one big file and also enables us to just send the
 customer one file for translation instead of hundreds).
 Or is there another way to specify a prefix for a given component?

 Thanks

 Matt

 On 2010-12-16 17:51, James Carman wrote:

 You can use page or component scoped messages.

 On Thu, Dec 16, 2010 at 11:48 AM, Matthias Keller
 matthias.kel...@ergon.ch  wrote:

 Hi

 This is an issue I frequently run into and I haven't found a good
 solution
 yet:
 I've got a Form using a CompoundPropertyModel and having lots of fields.
 The easy way to do these fields is:
 form.add(new RequiredTextFieldString(name));

 The model object has a getter and setter for name, so all works well.
 Unfortunately, when the user doesn't enter a valid value, the Required
 error
 message shows up saying something like Field 'name' is required.
 I could have a resource key name in my translations but this has the
 limitation, that all name fields in my whole app are translated the
 same
 way. Maybe one name is a human name, the other one is a machine name
 which
 have different translations...
 Is there an easy way to tackle this problem? For example have a prefix
 prepended to the field name or something else? One thing I want to avoid
 is
 to set an explicit label model for every field and if possible I'm hoping
 to
 avoid having to create different TextField subclasses for all my pages
 just
 prepending that string

 How do you do this for large applications?
 Currently, we're reverting to
 form.add(new RequiredTextFieldString(somepage.name, new
 PropertyModelString(model, name)));
 which kinda defeats the whole CompoundPropertyModel stuff

 Thanks a lot

 Matt






-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: URL coding strategies

2010-12-16 Thread Henrique Boregio
Hey Bas, you're right, I hadn't thought of it that way.

In option 1, how would I go about using a unique textual identifier?
Say there are 2 items with the name Ford Ranger Model 2005 but each
one is posted by different users, the URL would still be:
http://www.mysite.com/item/Ford-Ranger-Model-2005

..since no reference is made to the user, just to the item itself.

Is there a workaround this issue or do I need to make some kind of
reference to difference among items with the same title?
http://www.mysite.com/item/1-Ford-Ranger-Model-2005
http://www.mysite.com/item/2-Ford-Ranger-Model-2005
http://www.mysite.com/item/3-Ford-Ranger-Model-2005

Thanks.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: URL coding strategies

2010-12-16 Thread Bas Gooren
Well, look at it this way: when the user enters your application without any 
known state (session or other), how can you differentiate? Only by what you 
know/get from the url.


So yes, if the name itself is not enough input to make a textual identifier 
unique, you'll have to include more information in the identifier.


Bas

- Original Message - 
From: Henrique Boregio hbore...@gmail.com

To: users@wicket.apache.org
Sent: Thursday, December 16, 2010 6:06 PM
Subject: Re: URL coding strategies



Hey Bas, you're right, I hadn't thought of it that way.

In option 1, how would I go about using a unique textual identifier?
Say there are 2 items with the name Ford Ranger Model 2005 but each
one is posted by different users, the URL would still be:
http://www.mysite.com/item/Ford-Ranger-Model-2005

..since no reference is made to the user, just to the item itself.

Is there a workaround this issue or do I need to make some kind of
reference to difference among items with the same title?
http://www.mysite.com/item/1-Ford-Ranger-Model-2005
http://www.mysite.com/item/2-Ford-Ranger-Model-2005
http://www.mysite.com/item/3-Ford-Ranger-Model-2005

Thanks.

-
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



Re: How to tackle field labels when using CompoundPropertyModels?

2010-12-16 Thread James Carman
You could also look at the way Wicketopia does what you're talking about:

https://wicketopia.svn.sourceforge.net/svnroot/wicketopia/trunk/wicketopia/src/main/java/org/wicketopia/model/label/PropertyLabelModel.java

It's a metadata-driven approach.

On Thu, Dec 16, 2010 at 11:58 AM, James Carman
ja...@carmanconsulting.com wrote:
 You could use a class-qualified key
 (com.myco.domain.entity.Person.name=My Name).

 On Thu, Dec 16, 2010 at 11:55 AM, Matthias Keller
 matthias.kel...@ergon.ch wrote:
 Hi James

 Do you mean page or component scoped message properties files? Like
 MyPage.properties?
 Unfortunately I don't see that as a solution because this would produce
 hundreds or properties files which would be a real nightmare to maintain
 (our customer wants *very* frequent text changes which are way easier to do
 if all translations are in one big file and also enables us to just send the
 customer one file for translation instead of hundreds).
 Or is there another way to specify a prefix for a given component?

 Thanks

 Matt

 On 2010-12-16 17:51, James Carman wrote:

 You can use page or component scoped messages.

 On Thu, Dec 16, 2010 at 11:48 AM, Matthias Keller
 matthias.kel...@ergon.ch  wrote:

 Hi

 This is an issue I frequently run into and I haven't found a good
 solution
 yet:
 I've got a Form using a CompoundPropertyModel and having lots of fields.
 The easy way to do these fields is:
 form.add(new RequiredTextFieldString(name));

 The model object has a getter and setter for name, so all works well.
 Unfortunately, when the user doesn't enter a valid value, the Required
 error
 message shows up saying something like Field 'name' is required.
 I could have a resource key name in my translations but this has the
 limitation, that all name fields in my whole app are translated the
 same
 way. Maybe one name is a human name, the other one is a machine name
 which
 have different translations...
 Is there an easy way to tackle this problem? For example have a prefix
 prepended to the field name or something else? One thing I want to avoid
 is
 to set an explicit label model for every field and if possible I'm hoping
 to
 avoid having to create different TextField subclasses for all my pages
 just
 prepending that string

 How do you do this for large applications?
 Currently, we're reverting to
 form.add(new RequiredTextFieldString(somepage.name, new
 PropertyModelString(model, name)));
 which kinda defeats the whole CompoundPropertyModel stuff

 Thanks a lot

 Matt







-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Datatable/Dataview filtering problem

2010-12-16 Thread Benedikt Schlegel
Try to implement the delay on client side. Instead of submitting the
form directly, call a function with an internal timer.
Something like:

function delayedSubmit(form) {
if (form._delayedSubmit != null)
clearTimeout(form._delayedSubmit);

form._delayedSubmit = setTimeout(function() {
form.submit();
}, 500);
}

Didnt run this code but i think it should work. At least the concept
should be clear :

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Detach() explanation

2010-12-16 Thread Eelco Hillenius
This also applies to models, which you should use if you can over
doing this directly in components. Also, besides serialization, the
default configuration in Wicket keeps the current page in memory
between requests. If you properly 'detach' (deflate might have been a
good alternative word), you drastically cut down on the memory you use
per session.

Eelco

On Wed, Dec 15, 2010 at 12:33 AM, Martin Grigorov mgrigo...@apache.org wrote:
 hi,

 each page with all its components is being serialized and stored somewhere
 (session, disk) at the end of a request.
 This is needed to be able to support stateful pages and to be able to return
 to previous page or version of a page with the browser back button.

 Each component and model has detach() method in which it can null-ify any
 member variable that is not needed to be stored, i.e. the value of this
 variable is either not important or can be restored by other means.

 On Sat, Dec 11, 2010 at 7:26 PM, kumar ku...@mailinator.com wrote:


 Hi everyone,

 can I get an example how to implement the detach() method ? can someone
 please post a detailed example ?
 why and in which cases implementing detach() is important ?

 thanks.
 --
 View this message in context:
 http://apache-wicket.1842946.n4.nabble.com/Detach-explanation-tp3083568p3083568.html
 Sent from the Users forum mailing list archive at Nabble.com.

 -
 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



Modify Attribute on DataView HTML Element

2010-12-16 Thread Matt Schmidt
I'm trying to modify an attribute on the HTML element that goes with my
DataView:

HTML
div wicket:id=dataview id=dynamic
   span wicket:id=myLabel /
/div

JAVA
new DataViewPOJO(dataview, dataProvider) {
   protected void populateItem(ItemPOJO item) {
  item.add(new Label(myLabel, item.getModelObject().getValue()));
   }
   protected void onComponentTag(ComponentTag tag) {
  super.onComponentTag(tag);
  tag.put(id, dynamicValue);
   }
}

I thought this would do it, but I never even hit DataView.onComponentTag().
Any other suggestions?

-Matt


Re: Modify Attribute on DataView HTML Element

2010-12-16 Thread Martijn Dashorst
item.add(new AttributeModifier(attr, true, value));

dataview#oncomponenttag doesn't do anything since the dataview repeats
its markup with a listitem. the list item#oncomponenttag actually
receives the markup tag.

Martijn

On Thu, Dec 16, 2010 at 10:04 PM, Matt Schmidt mschmid...@gmail.com wrote:
 I'm trying to modify an attribute on the HTML element that goes with my
 DataView:

 HTML
 div wicket:id=dataview id=dynamic
   span wicket:id=myLabel /
 /div

 JAVA
 new DataViewPOJO(dataview, dataProvider) {
   protected void populateItem(ItemPOJO item) {
      item.add(new Label(myLabel, item.getModelObject().getValue()));
   }
   protected void onComponentTag(ComponentTag tag) {
      super.onComponentTag(tag);
      tag.put(id, dynamicValue);
   }
 }

 I thought this would do it, but I never even hit DataView.onComponentTag().
 Any other suggestions?

 -Matt




-- 
Become a Wicket expert, learn from the best: http://wicketinaction.com

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: How to emulate an ajax-response with Wicket?

2010-12-16 Thread Bruno Borges
Could you provide a wicket quickstart application with such case?


Bruno Borges
www.brunoborges.com.br
+55 21 76727099

The glory of great men should always be
measured by the means they have used to
acquire it.
 - Francois de La Rochefoucauld



On Thu, Dec 16, 2010 at 1:19 PM, f a v fav...@gmail.com wrote:

 Hi.

 Is there a way to answer an ajax-response XML asked from a Wicket
 application from another?
 Let me explain, I have an ajax filled DropDownChoice just like the
 example one [1], but it's filled from another webapp generating the
 ajax-response XML with a JSP.
 Now I need to emulate the ajax-response from another Wicket
 application and I wanted to use Wicket instead of JSP. I made a Page
 that answers the ajax-response XML. The Page works ok when it's
 invoked pasting the URL in a browser. But, when the DropDownChoice
 invokes the Page it's redirected to the wrong webapp.
 In other words, I have a DropDownChoice in webapp A
 (http://example.com/a/dropDownPage), a Page that answers an
 ajax-response XML in webapp B (http://example.com/b/AjaxResponsePage,
 pasting this URL in a browser works) and when /a/dropDownPage asks for
 /b/AjaxResponsePage the browser it's redirected to /a/AjaxResponsePage
 (note that it's redirected to /a and not /b) and fails.

 Debuging I've found that WebRequestCycle.isRedirect() returns true
 when WebRequest.isAjax() is true and that triggers a redirect to
 AjaxResponsePage (a relative URL, so the browser is changing the base
 URL, not Wicket).
 Maybe I'm taking the wrong approach and there is a better way to do it
 or there is a simple way to bypass this mechanism and make it work.

 [1] http://goo.gl/H7jlG

 Thanks!

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




Re: Custom Component

2010-12-16 Thread Benedikt Schlegel
Hi Dieter,
i think you might want to have a look at the following:

https://cwiki.apache.org/WICKET/jfreechart-and-wicket-example.html

So long,
Benedikt

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Reload modal page

2010-12-16 Thread Alec Swan
Hello,

I have a modal page which allows the user to clone a tab.

I would like to reload the modal page after this. Is there an exception I
can throw to cause the modal page to get reloaded?

Thanks,

Alec


Re: How to listen for CHILD ajax form submits

2010-12-16 Thread guydog28

Ernesto,

I had thought of that.  I was hoping to avoid the custom button/link route,
but seeing as I haven't heard anything more elegant yet, I decided to go
with it for now.  Thanks for your input!
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/How-to-listen-for-CHILD-ajax-form-submits-tp3086439p3092111.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org