Re: HybridURLCodingStrategies vs others

2008-02-04 Thread mfs

Actually my last post was in context of BookmarkableURLCodingStrategy which
doesnt preserve the url once any action on that page is called, my argument
is why not, i mean if the pageid is there with those actions (i.e.
links/button) why cant the same page be shown and offcourse on top of why
cant the same bookmarkable url be preserved..


Johan Compagner wrote:
 
 i am not sure what you are trying to say but it looks like you are exactly
 describing
 how wicket already works from day 1.
 
 The pageid in normal links are ofcourse used to lookup the page and call
 the
 listener
 and if you don't set a different response page that page is used also for
 rendering.
 
 johan
 
 
 
 On Feb 4, 2008 9:21 AM, mfs [EMAIL PROTECTED] wrote:
 

 Your point certainly makes sense for ajax based behavior (where one would
 loose the state) BUT lets say a a page just has normal links/button
 (which
 would have pageIds encoded in them) why cant in that case (i.e. on
 invocation of listeners on button/link click)...the response be
 redirected
 to the page associated with pageId which is part of links/buttons url..



 Martijn Dashorst wrote:
 
  If you use ajax components to update page state, this will not modify
 the
  URL in the BUCS strategy. Refresh or go back to that URL and you loose
  your
  state because the URL invokes a bookmarkable page request.
  Martijn
 
  On 1/31/08, mfs [EMAIL PROTECTED] wrote:
 
 
  Thanks for the follow up Matej, it does clarify certain things..but
  commenting on your last point, as you said earlier..the links/buttons
  (bind
  to any event) have the pageId in them irrespective of whether the page
 is
  loaded through BUCS or HUCS, so even in case of BUCS we still would
 have
  the
  pageId on an event-invocation, so why cant the page (in session be
  retrieved
  based on the pageId with those links) and be forward to..
 
 
 
 
 
  Matej Knopp-2 wrote:
  
   On Jan 30, 2008 1:36 AM, mfs [EMAIL PROTECTED] wrote:
  
   When u say  it attempts to reuse existing page instance (when
 pageid
  in
   session matches the class specified by mount point). - you mean
 the
   pageid
   in the URL (and not session) matches the class specified by the
 mount
   path ?
   No. The pageId in url is of course used to retrieve page instance
 from
   session which is then tested to match the mount point.
  
  
   - So other strategies are there to provide relatively clean-er url
 ?
   (i.e.
   without pageId and version info) what other reasons would be there
 to
  use
   the non-HUCS, i wonder what happens to existing the page instances
 ?
   Nothing new page instance is created, that doesn't affect the old
 page
   instances at all.
  
   - Creating a new page-instance for every call, doesnt that break
 the
  back
   button support ? arent we compromising the wicket functionality of
   maintaining page-history by creating a new page instance every time
  and
   not
   using the existing ones ?
   What do you mean by every call? New page instance is created on
   every request with regular bookmarkable URL. That doesn't affect
 back
   button at all becaue all page instance relative urls (listener
   interface, e.g. clicking a link on page) are not bookmarkable and
   contain the page instance id. Only when you refresh the page (while
   still having the bookmarkable url in url bar) new page instance is
   created.
  
   - Last but not the least when i read that all other strategies
 other
  than
   HUCS doesnt preserve the mount path after a listener is invoked on
  that
   page
   sounded like a bug to me, i mean why cant the mount path be
 preserved
   using
   the same strategy ?, with that a person is bound to use HUCS
 although
  he
   prefers to keep to BookMarkableUCS since its more clean in terms of
   displayed url.
   That's the point. The regular URL conding strategies don't insert
 page
   instance in URL. So after clicking a link there is no way to
 redirect
   to bookmarkable URL while still displaying the same page. That's the
   whole reason for hybridurlcodingstrategy.
  
   -Matej
  
  
  
  
  
   Matej Knopp-2 wrote:
   
Hi,
   
the other strategies always create new page instance. The
 difference
   with
hybridurlcodingstrategy is that it attempts to reuse existing
 page
instance
(when pageid in session matches the class specified by mount
 point).
   
-Matej
   
On Jan 29, 2008 11:36 PM, mfs [EMAIL PROTECTED] wrote:
   
   
Guys,
   
I believe its just the HybridURLCodingStrategy and its
 subclasses
(IndexHUCS) which encodes the mount point, page parameters and
 page
instance
information into the URL whereas others strategies DO have the
mount-point

page-param in them (encoded in a different way) BUT the
  page-instance
info
(i.e. page-id/version) is not contained in the URL.  I wonder
 why
  is
   this
page-info not required by other strategies, wouldnt it be need
 to
   locate
the
older pages AND IF NOT 

Re: HybridURLCodingStrategies vs others

2008-02-04 Thread Johan Compagner
i am not sure what you are trying to say but it looks like you are exactly
describing
how wicket already works from day 1.

The pageid in normal links are ofcourse used to lookup the page and call the
listener
and if you don't set a different response page that page is used also for
rendering.

johan



On Feb 4, 2008 9:21 AM, mfs [EMAIL PROTECTED] wrote:


 Your point certainly makes sense for ajax based behavior (where one would
 loose the state) BUT lets say a a page just has normal links/button (which
 would have pageIds encoded in them) why cant in that case (i.e. on
 invocation of listeners on button/link click)...the response be redirected
 to the page associated with pageId which is part of links/buttons url..



 Martijn Dashorst wrote:
 
  If you use ajax components to update page state, this will not modify
 the
  URL in the BUCS strategy. Refresh or go back to that URL and you loose
  your
  state because the URL invokes a bookmarkable page request.
  Martijn
 
  On 1/31/08, mfs [EMAIL PROTECTED] wrote:
 
 
  Thanks for the follow up Matej, it does clarify certain things..but
  commenting on your last point, as you said earlier..the links/buttons
  (bind
  to any event) have the pageId in them irrespective of whether the page
 is
  loaded through BUCS or HUCS, so even in case of BUCS we still would
 have
  the
  pageId on an event-invocation, so why cant the page (in session be
  retrieved
  based on the pageId with those links) and be forward to..
 
 
 
 
 
  Matej Knopp-2 wrote:
  
   On Jan 30, 2008 1:36 AM, mfs [EMAIL PROTECTED] wrote:
  
   When u say  it attempts to reuse existing page instance (when
 pageid
  in
   session matches the class specified by mount point). - you mean the
   pageid
   in the URL (and not session) matches the class specified by the
 mount
   path ?
   No. The pageId in url is of course used to retrieve page instance
 from
   session which is then tested to match the mount point.
  
  
   - So other strategies are there to provide relatively clean-er url ?
   (i.e.
   without pageId and version info) what other reasons would be there
 to
  use
   the non-HUCS, i wonder what happens to existing the page instances ?
   Nothing new page instance is created, that doesn't affect the old
 page
   instances at all.
  
   - Creating a new page-instance for every call, doesnt that break the
  back
   button support ? arent we compromising the wicket functionality of
   maintaining page-history by creating a new page instance every time
  and
   not
   using the existing ones ?
   What do you mean by every call? New page instance is created on
   every request with regular bookmarkable URL. That doesn't affect back
   button at all becaue all page instance relative urls (listener
   interface, e.g. clicking a link on page) are not bookmarkable and
   contain the page instance id. Only when you refresh the page (while
   still having the bookmarkable url in url bar) new page instance is
   created.
  
   - Last but not the least when i read that all other strategies other
  than
   HUCS doesnt preserve the mount path after a listener is invoked on
  that
   page
   sounded like a bug to me, i mean why cant the mount path be
 preserved
   using
   the same strategy ?, with that a person is bound to use HUCS
 although
  he
   prefers to keep to BookMarkableUCS since its more clean in terms of
   displayed url.
   That's the point. The regular URL conding strategies don't insert
 page
   instance in URL. So after clicking a link there is no way to redirect
   to bookmarkable URL while still displaying the same page. That's the
   whole reason for hybridurlcodingstrategy.
  
   -Matej
  
  
  
  
  
   Matej Knopp-2 wrote:
   
Hi,
   
the other strategies always create new page instance. The
 difference
   with
hybridurlcodingstrategy is that it attempts to reuse existing page
instance
(when pageid in session matches the class specified by mount
 point).
   
-Matej
   
On Jan 29, 2008 11:36 PM, mfs [EMAIL PROTECTED] wrote:
   
   
Guys,
   
I believe its just the HybridURLCodingStrategy and its
 subclasses
(IndexHUCS) which encodes the mount point, page parameters and
 page
instance
information into the URL whereas others strategies DO have the
mount-point

page-param in them (encoded in a different way) BUT the
  page-instance
info
(i.e. page-id/version) is not contained in the URL.  I wonder why
  is
   this
page-info not required by other strategies, wouldnt it be need to
   locate
the
older pages AND IF NOT how does it work for them...cant it work
 in
  a
similar
way for HUCS where we dont have those numbers in the url...
   
Thanks in advance
   
   
   
   
--
View this message in context:
   
  
 
 http://www.nabble.com/HybridURLCodingStrategies-vs-others-tp15171137p15171137.html
Sent from the Wicket - User mailing list archive at 
Nabble.comhttp://nabble.com/
 .
 

Re: Short Design Question

2008-02-04 Thread Martijn Dashorst
The average joe doesn't look at the URL... only developers do
Martijn

On 2/3/08, oliverw [EMAIL PROTECTED] wrote:


 The point is that plain wicket urls might look at bit scary to average joe
 that's why I would like to have pretty urls everywhere. However Johan was
 correct that the page cannot be used without a user_id / user.  Default
 constructor changed.


 Edvin Syse wrote:
 
  So that page can also work without a user object/id? It is a nice url
  then but if the page cant be found it will call the default or
  pageparam constructor..
 
  You are right, the page is useless as a bookmarkable page, but atleast
 he
  gets his nice url :)
 
  I think Oliver's requirement was that the userid was never exposed in
 the
  URL, so I guess the default constructor should do something like:
 
  throw new
  RestartResponseAtInterceptPageException(UserRegistrationPage.class);
 
 
  -- Edvin
 
 
 
  On 2/2/08, oliverw [EMAIL PROTECTED] wrote:
  Thanks Edwin! That did the trick. Just from the looks it appears as if
  HybridUrlCodingStrategy would be the preferable mount strategy in
  general.
 
 
  Edvin Syse wrote:
Can't you just proceed this way:
  setResponsePage(new SummaryPage(userdId));
 
  i.e. pass the id as a parameter to the summary page constructor ?
 
  Regards
 
  This works - kind of. Because even though the response page is
  mounted, I
  not see a pretty url in the browser.
  You can mount the page with HybridUrlCodingStrategy to get a pretty
 URL
  even after redirecting:
 
  mount(new HybridUrlCodingStrategy(/summary, SummaryPage.class));
 
  -- Edvin
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
  --
  View this message in context:
  http://www.nabble.com/Short-Design-Question-tp15243739p15246739.html
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

 --
 View this message in context:
 http://www.nabble.com/Short-Design-Question-tp15243739p15255622.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


Re: A submit link that can be used with span wicket:id

2008-02-04 Thread dvd
That is what I meant. If wicket comes with such a commonly used
component, it would save a lot of time for both users and authors
having to exlain everytime needing this. And perhaps there is not
one yet because it is not easy to come up with a good abstraction
of such a component that would behave exactly like a usual
submitLink. All the examples/books I saw uses individual panels/htmls for
each button needed such as Edit and Delete. I have not seen a universal
one that one could just provide needed paramsin constructor and the onSubmit 
callback. Perhaps you could explain how to implement this with some skeleton 
code. I found it quite awkward everytime I construct
a datatable with different needs of links, I have to go through this.



why exactly is it a chore? you only have to write it once...

-igor


On Feb 2, 2008 8:55 PM,  [EMAIL PROTECTED] wrote:
 Hello:
 All the books and examples I have read to deal with situation like datatable 
that would not accept normal Link since it is not anchored with a but span 
wicket:id, the suggestion is to create a panel for each such a link in the 
app when needed. while it works, it is quite tedious  to write many of these. 
Is there already a component/extension that function the same as Link (or 
SubmitLink) (that is, has the same call such as onSubmit, and other common 
Link component functions)  yet can be used against  with span or aWhen 
used with span,  I mean that the component would replace the element with a 
a on the fly, I saw in the doc wicket can replace the entire element on the 
fly so I assume this is feasibly.
 Thanks

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


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



Re: HybridURLCodingStrategies vs others

2008-02-04 Thread Johan Compagner
because that link is by default not stateless
If you use stateless links then that should happen (a combination of
bookmarkable and instance)

And not all pages can be bookmarkable, they have to have a default or
pageparam constructor.

Hybrid is a very special one. That is not just a Bookmarkble url coding
strategy.
Its really a Redirect URL strategy

johan



On Feb 4, 2008 9:56 AM, mfs [EMAIL PROTECTED] wrote:


 Actually my last post was in context of BookmarkableURLCodingStrategy
 which
 doesnt preserve the url once any action on that page is called, my
 argument
 is why not, i mean if the pageid is there with those actions (i.e.
 links/button) why cant the same page be shown and offcourse on top of why
 cant the same bookmarkable url be preserved..


 Johan Compagner wrote:
 
  i am not sure what you are trying to say but it looks like you are
 exactly
  describing
  how wicket already works from day 1.
 
  The pageid in normal links are ofcourse used to lookup the page and call
  the
  listener
  and if you don't set a different response page that page is used also
 for
  rendering.
 
  johan
 
 
 
  On Feb 4, 2008 9:21 AM, mfs [EMAIL PROTECTED] wrote:
 
 
  Your point certainly makes sense for ajax based behavior (where one
 would
  loose the state) BUT lets say a a page just has normal links/button
  (which
  would have pageIds encoded in them) why cant in that case (i.e. on
  invocation of listeners on button/link click)...the response be
  redirected
  to the page associated with pageId which is part of links/buttons url..
 
 
 
  Martijn Dashorst wrote:
  
   If you use ajax components to update page state, this will not modify
  the
   URL in the BUCS strategy. Refresh or go back to that URL and you
 loose
   your
   state because the URL invokes a bookmarkable page request.
   Martijn
  
   On 1/31/08, mfs [EMAIL PROTECTED] wrote:
  
  
   Thanks for the follow up Matej, it does clarify certain things..but
   commenting on your last point, as you said earlier..the
 links/buttons
   (bind
   to any event) have the pageId in them irrespective of whether the
 page
  is
   loaded through BUCS or HUCS, so even in case of BUCS we still would
  have
   the
   pageId on an event-invocation, so why cant the page (in session be
   retrieved
   based on the pageId with those links) and be forward to..
  
  
  
  
  
   Matej Knopp-2 wrote:
   
On Jan 30, 2008 1:36 AM, mfs [EMAIL PROTECTED] wrote:
   
When u say  it attempts to reuse existing page instance (when
  pageid
   in
session matches the class specified by mount point). - you mean
  the
pageid
in the URL (and not session) matches the class specified by the
  mount
path ?
No. The pageId in url is of course used to retrieve page instance
  from
session which is then tested to match the mount point.
   
   
- So other strategies are there to provide relatively clean-er
 url
  ?
(i.e.
without pageId and version info) what other reasons would be
 there
  to
   use
the non-HUCS, i wonder what happens to existing the page
 instances
  ?
Nothing new page instance is created, that doesn't affect the old
  page
instances at all.
   
- Creating a new page-instance for every call, doesnt that break
  the
   back
button support ? arent we compromising the wicket functionality
 of
maintaining page-history by creating a new page instance every
 time
   and
not
using the existing ones ?
What do you mean by every call? New page instance is created on
every request with regular bookmarkable URL. That doesn't affect
  back
button at all becaue all page instance relative urls (listener
interface, e.g. clicking a link on page) are not bookmarkable and
contain the page instance id. Only when you refresh the page
 (while
still having the bookmarkable url in url bar) new page instance is
created.
   
- Last but not the least when i read that all other strategies
  other
   than
HUCS doesnt preserve the mount path after a listener is invoked
 on
   that
page
sounded like a bug to me, i mean why cant the mount path be
  preserved
using
the same strategy ?, with that a person is bound to use HUCS
  although
   he
prefers to keep to BookMarkableUCS since its more clean in terms
 of
displayed url.
That's the point. The regular URL conding strategies don't insert
  page
instance in URL. So after clicking a link there is no way to
  redirect
to bookmarkable URL while still displaying the same page. That's
 the
whole reason for hybridurlcodingstrategy.
   
-Matej
   
   
   
   
   
Matej Knopp-2 wrote:

 Hi,

 the other strategies always create new page instance. The
  difference
with
 hybridurlcodingstrategy is that it attempts to reuse existing
  page
 instance
 (when pageid in session matches the class specified by mount
  point).

 -Matej

 On Jan 29, 2008 11:36 PM, 

Re: Short Design Question

2008-02-04 Thread Johan Compagner
+1

On Feb 4, 2008 10:05 AM, Martijn Dashorst [EMAIL PROTECTED]
wrote:

 The average joe doesn't look at the URL... only developers do
 Martijn

 On 2/3/08, oliverw [EMAIL PROTECTED] wrote:
 
 
  The point is that plain wicket urls might look at bit scary to average
 joe
  that's why I would like to have pretty urls everywhere. However Johan
 was
  correct that the page cannot be used without a user_id / user.  Default
  constructor changed.
 
 
  Edvin Syse wrote:
  
   So that page can also work without a user object/id? It is a nice url
   then but if the page cant be found it will call the default or
   pageparam constructor..
  
   You are right, the page is useless as a bookmarkable page, but atleast
  he
   gets his nice url :)
  
   I think Oliver's requirement was that the userid was never exposed in
  the
   URL, so I guess the default constructor should do something like:
  
   throw new
   RestartResponseAtInterceptPageException(UserRegistrationPage.class);
  
  
   -- Edvin
  
  
  
   On 2/2/08, oliverw [EMAIL PROTECTED] wrote:
   Thanks Edwin! That did the trick. Just from the looks it appears as
 if
   HybridUrlCodingStrategy would be the preferable mount strategy in
   general.
  
  
   Edvin Syse wrote:
 Can't you just proceed this way:
   setResponsePage(new SummaryPage(userdId));
  
   i.e. pass the id as a parameter to the summary page constructor ?
  
   Regards
  
   This works - kind of. Because even though the response page is
   mounted, I
   not see a pretty url in the browser.
   You can mount the page with HybridUrlCodingStrategy to get a pretty
  URL
   even after redirecting:
  
   mount(new HybridUrlCodingStrategy(/summary, SummaryPage.class));
  
   -- Edvin
  
  
  
 -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
  
   --
   View this message in context:
   http://www.nabble.com/Short-Design-Question-tp15243739p15246739.html
   Sent from the Wicket - User mailing list archive at 
   Nabble.comhttp://nabble.com/
 .
  
  
  
 -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
  
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
  
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
  
 
  --
  View this message in context:
  http://www.nabble.com/Short-Design-Question-tp15243739p15255622.html
  Sent from the Wicket - User mailing list archive at 
  Nabble.comhttp://nabble.com/
 .
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 


 --
 Buy Wicket in Action: http://manning.com/dashorst
 Apache Wicket 1.3.0 is released
 Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0



Re: Short Design Question

2008-02-04 Thread Johan Compagner
i am always really scared as a user when looking at the gmail urls yes
i almost run away screaming ..

But i do like the app itself so i guess i will try to be a big boy and not
be scared.

johan



On Feb 3, 2008 6:13 PM, oliverw [EMAIL PROTECTED] wrote:


 The point is that plain wicket urls might look at bit scary to average joe
 that's why I would like to have pretty urls everywhere. However Johan was
 correct that the page cannot be used without a user_id / user.  Default
 constructor changed.


 Edvin Syse wrote:
 
  So that page can also work without a user object/id? It is a nice url
  then but if the page cant be found it will call the default or
  pageparam constructor..
 
  You are right, the page is useless as a bookmarkable page, but atleast
 he
  gets his nice url :)
 
  I think Oliver's requirement was that the userid was never exposed in
 the
  URL, so I guess the default constructor should do something like:
 
  throw new
  RestartResponseAtInterceptPageException(UserRegistrationPage.class);
 
 
  -- Edvin
 
 
 
  On 2/2/08, oliverw [EMAIL PROTECTED] wrote:
  Thanks Edwin! That did the trick. Just from the looks it appears as if
  HybridUrlCodingStrategy would be the preferable mount strategy in
  general.
 
 
  Edvin Syse wrote:
Can't you just proceed this way:
  setResponsePage(new SummaryPage(userdId));
 
  i.e. pass the id as a parameter to the summary page constructor ?
 
  Regards
 
  This works - kind of. Because even though the response page is
  mounted, I
  not see a pretty url in the browser.
  You can mount the page with HybridUrlCodingStrategy to get a pretty
 URL
  even after redirecting:
 
  mount(new HybridUrlCodingStrategy(/summary, SummaryPage.class));
 
  -- Edvin
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
  --
  View this message in context:
  http://www.nabble.com/Short-Design-Question-tp15243739p15246739.html
  Sent from the Wicket - User mailing list archive at 
  Nabble.comhttp://nabble.com/
 .
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

 --
 View this message in context:
 http://www.nabble.com/Short-Design-Question-tp15243739p15255622.html
  Sent from the Wicket - User mailing list archive at 
 Nabble.comhttp://nabble.com/
 .


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




Re: 2 process cant together in a same time - modal window and form in the same page constructor?

2008-02-04 Thread kenixwong

thx for reply, johan

yes..you r right, when i click a link, I want redirect to a load a page and
then at the same time, a modal dialog is show immediately... 

my current testing here is... the modal window component is call at the
parent class and then the report form is call at child class. Common sense,
all the component at the parent class will call first before the child
class' component , right...

yes... right now my page can load the modal window, but it is shown after
the report page is finish load. The main reason i use the modalwindow is
feasible the user to make decision whether want terminate the report page
loading or not ( if the user don't want to wait until the page is finish
load) 

as what you suggested on Jan 31, 2008.. yes.. i did. Add ajaxlink to call
the modal window and then onload it. The code that i auto fire the ajaxlink
is 

getBodyContainer().addOnLoadModifier(new ClickOnceOnLoadModel( ajaxLink ),
null );

which i get the sample resource from this forum
http://www.nabble.com/modal-window-question---opening-a-modal-window-on-page-load-to12586008.html#a12598786

yes..it worked. but it is loaded after the page is finish load.  :(


thanks in advance 
- kenix




Johan Compagner wrote:
 
 what do you exactly want?
 you want a modal dialog to show immedianlty when another page is loaded?
 I think you have to dig into the javascript portion of modal window then
 (or
 matej can tell you a bit more)
 
 first of all the page below it has to load first completely because that
 does contain the div.
 
 I do think you should think about your gui a bit more and if there isn't a
 better way of doing stuff
 because showing a modal dialog immediantly on a new page doesn't make much
 sense to me in 99.9% of the cases i can think of
 
 johan
 
 On Feb 4, 2008 12:24 PM, kenixwong [EMAIL PROTECTED] wrote:
 

 hi,

 can anybody share the solution with me ?

 is that the javaScript is take time to load for the modal window even
 this
 component is called before the form component is call?


 anyone can help ? until now i still can't get any solution and resource
 yet...


 thanks in advance,...
 - kenix



 kenixwong wrote:
 
  2 process cant together in a same time - modal window and form in the
 same
  page constructor?  Is because the process haven't done, so the request
  wont send to wicket there?
 
  The main  reason i want to implement this features, caused modal window
  can prevent the user navigate to other page or feasible the user to
 cancel
  the form process if the loading time is longer. Another point is,
 because
  my report page is loading with JFreeChart to generate the chart report.
 If
  the user press right click to Open Link in new tab, the chart at the
  previous tab will have the broken link issue means the chart is cant
  display. So, modal window can play an important role here...
 
 
  I was using the wicket 1.2.4. Is it the version cant support it and i
 need
  to upgrade ? i read from
  http://cwiki.apache.org/WICKET/wicket-130-rc1.html .. Migration from
 1.2
  to 1.3, there is not much different for the modal window in both
 version..
  can anyone give some solution to me?
 
 
  Thanks in advance
  - kenix
 
 
 
 
 
  kenixwong wrote:
 
  thanks for reply, johan
 
  i want to show the modal window once the report page is load. Mean
  background is continue loading the report and the modal window is just
 as
  a control (its features is invisible the background and only close
 once
  action performed is click in the modal window ) to prevent user
 navigate
  to other page. For the modal window it only define one cancel button,
  mean if user click the cancel button, the background ( report page )
 is
  stop.
 
  Yes... the modal window is only shown by an ajax link. I get the
 source
  from this forum ..where it can fire the ajaxlink whitout click the
 link.
  Here is the code
 
   getBodyContainer().addOnLoadModifier(new ClickOnceOnLoadModel(
  ajaxLink ), null );   
 
  Even i tried to create a modal window with ajaxlink ( add auto fire
 event
  as above code ) and put at the parent class and the report page is the
  child class. But the result is same, the report page is finish loaded
  then only pop up the modal window.
 
  my report page constructor :
 
  public LineChart() {
  /// modal window use panel..declare the modal window setting here
  then add
   add(modalWindow);
 
   // to auto pop up the modal window.
   ajaxLink = new AjaxLink(cancelReportModalLink){
  @Override
  public void onClick(AjaxRequestTarget target) {
  cancelReportModal.show(target);
  }
  };
   add(ajaxLink);
 
//  Fire the ajaxLink onclick function
   getBodyContainer().addOnLoadModifier(new ClickOnceOnLoadModel(
  ajaxLink ), null );
 
   add(feedback);
   add(new LineChartForm(LineChartForm));
  }
 
 
  private class LineChartForm extends Form {
  

Re: 2 process cant together in a same time - modal window and form in the same page constructor?

2008-02-04 Thread Johan Compagner
What is that ReportPage is that the page that also loads the modal dialog?
And that page is taken a long time to load? Because it generates things?

But for the modal dialog to work, the report page (if that is the modal
dialogs parent)
must first be fully loaded there is no other way.

I stil dont get exactly what you suspect to happen, you think that the
parent page
that generates the report or something and that one doesn't load completely
because it has to wait for the report
can display the modal dialog already but itself isn't done yet?

johan



On Feb 4, 2008 2:18 PM, kenixwong [EMAIL PROTECTED] wrote:


 thx for reply, johan

 yes..you r right, when i click a link, I want redirect to a load a page
 and
 then at the same time, a modal dialog is show immediately...

 my current testing here is... the modal window component is call at the
 parent class and then the report form is call at child class. Common
 sense,
 all the component at the parent class will call first before the child
 class' component , right...

 yes... right now my page can load the modal window, but it is shown after
 the report page is finish load. The main reason i use the modalwindow is
 feasible the user to make decision whether want terminate the report page
 loading or not ( if the user don't want to wait until the page is finish
 load)

 as what you suggested on Jan 31, 2008.. yes.. i did. Add ajaxlink to call
 the modal window and then onload it. The code that i auto fire the
 ajaxlink
 is

 getBodyContainer().addOnLoadModifier(new ClickOnceOnLoadModel( ajaxLink ),
 null );

 which i get the sample resource from this forum

 http://www.nabble.com/modal-window-question---opening-a-modal-window-on-page-load-to12586008.html#a12598786

 yes..it worked. but it is loaded after the page is finish load.  :(


 thanks in advance
 - kenix




 Johan Compagner wrote:
 
  what do you exactly want?
  you want a modal dialog to show immedianlty when another page is loaded?
  I think you have to dig into the javascript portion of modal window then
  (or
  matej can tell you a bit more)
 
  first of all the page below it has to load first completely because that
  does contain the div.
 
  I do think you should think about your gui a bit more and if there isn't
 a
  better way of doing stuff
  because showing a modal dialog immediantly on a new page doesn't make
 much
  sense to me in 99.9% of the cases i can think of
 
  johan
 
  On Feb 4, 2008 12:24 PM, kenixwong [EMAIL PROTECTED] wrote:
 
 
  hi,
 
  can anybody share the solution with me ?
 
  is that the javaScript is take time to load for the modal window even
  this
  component is called before the form component is call?
 
 
  anyone can help ? until now i still can't get any solution and resource
  yet...
 
 
  thanks in advance,...
  - kenix
 
 
 
  kenixwong wrote:
  
   2 process cant together in a same time - modal window and form in the
  same
   page constructor?  Is because the process haven't done, so the
 request
   wont send to wicket there?
  
   The main  reason i want to implement this features, caused modal
 window
   can prevent the user navigate to other page or feasible the user to
  cancel
   the form process if the loading time is longer. Another point is,
  because
   my report page is loading with JFreeChart to generate the chart
 report.
  If
   the user press right click to Open Link in new tab, the chart at the
   previous tab will have the broken link issue means the chart is cant
   display. So, modal window can play an important role here...
  
  
   I was using the wicket 1.2.4. Is it the version cant support it and i
  need
   to upgrade ? i read from
   http://cwiki.apache.org/WICKET/wicket-130-rc1.html .. Migration from
  1.2
   to 1.3, there is not much different for the modal window in both
  version..
   can anyone give some solution to me?
  
  
   Thanks in advance
   - kenix
  
  
  
  
  
   kenixwong wrote:
  
   thanks for reply, johan
  
   i want to show the modal window once the report page is load. Mean
   background is continue loading the report and the modal window is
 just
  as
   a control (its features is invisible the background and only close
  once
   action performed is click in the modal window ) to prevent user
  navigate
   to other page. For the modal window it only define one cancel
 button,
   mean if user click the cancel button, the background ( report page )
  is
   stop.
  
   Yes... the modal window is only shown by an ajax link. I get the
  source
   from this forum ..where it can fire the ajaxlink whitout click the
  link.
   Here is the code
  
getBodyContainer().addOnLoadModifier(new ClickOnceOnLoadModel(
   ajaxLink ), null );   
  
   Even i tried to create a modal window with ajaxlink ( add auto fire
  event
   as above code ) and put at the parent class and the report page is
 the
   child class. But the result is same, the report page is finish
 loaded
   then only pop up the modal window.
  
   

AjaxLink, BookmarkablePageLink and feedback problem

2008-02-04 Thread Vatroslav

I have noticed very strange behaviour of feedback messages when using
AjaxLink and BookmarkablePageLink on the same page.

Code example is attached to the message.
http://www.nabble.com/file/p15269007/Feedback_example.txt
Feedback_example.txt 


How to reproduce it..

1st Case (working)
a) Disable (remove) first link (HomePageTest): test
b) Click on feedback test
c) Type something and press submit button few times - new message
overwrites last one, that is OK.

2nd Case (non working)
a) Enable first link (HomePageTest): test
b) Click on feedback test
c) Type something and press submit button few times: last message is
displayed (inside feedback panel) below previous one!

I have problem with required fields in my program because feedback messages
are never cleared.

I'm using new release: 1.3.1 (it doesn't work with 1.3.0, either).

Thanks in advance,
Vatroslav


-- 
View this message in context: 
http://www.nabble.com/AjaxLink%2C-BookmarkablePageLink-and-feedback-problem-tp15269007p15269007.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Reloading resource

2008-02-04 Thread gantini

I'm very new with Wicket.
It is possible to automatically reload resource (class and HTML file) ?

I've set:

@Override
protected void init() {
getResourceSettings().setResourcePollFrequency( 
Duration.ONE_SECOND );
}

but this don't work for me.
Thanks.
-- 
View this message in context: 
http://www.nabble.com/Reloading-resource-tp15268997p15268997.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Wicket Maven JARs Compiled with Java 6?

2008-02-04 Thread Nick Heudecker
Hi,

I'm getting a number of class not valid errors when my IDE is trying to
autocomplete imports.  Typically this error occurs when I encounter JARs
compiled with Java 6, while I'm on Java 5.  Can the JARs be compiled with
Java 5, or can multiple versions be made available?  Thanks.

-Nick


Re: How to delete an item from List view.

2008-02-04 Thread Johan Compagner
You do use a delete button, so i guess the values are submitted.
Then if you store those first in the model objects you won't loose anything

johan



On Feb 4, 2008 2:35 PM, pnerkar [EMAIL PROTECTED] wrote:


 Hi Johan,

 Yes that will be quickest solution ,
 But this will clear the fields of all vehicles.

 -Pnerkar


 Johan Compagner wrote:
 
  wasn't the quickest solution:
 
  public void onSubmit() {
 List vehicles = (List) getParent().getParent().getModelObject();
 vehicles.remove(index);
 listView.removeAll();
  }
 
  Then if the list itself is stable on the server side (if other persons
 can
  also delete or add stuff to that list you really should do it
 differently)
  that should work fine. After you alter the listviews model you have to
  remove all the items so that it will rebuild
 
  johan
 
 
 
 
  On Feb 1, 2008 12:49 AM, pnerkar [EMAIL PROTECTED] wrote:
 
 
  Hi All,
 
  I have rendered a list view on a Web Page.
 
  vehicle1X
  vehicle2X
  vehicle3X
 
  when a person click on 'X', that item should be deleted.
  But I'm facing an issue, when i click on 'X', last item get deleted.
  Actually when I delete vehicle2 from my list, it deletes vehicle2 but
  that
  component is still there.
  So while rendering it render vehicle1  vehicle2.
 
  public void onSubmit() {
 List vehicles = (List) getParent().getParent().getModelObject();
 vehicles.remove(index);
  }
 
  can please help out ??
 
 
 
  --
  View this message in context:
 
 http://www.nabble.com/How-to-delete-an-item-from-List-view.-tp15217608p15217608.html
  Sent from the Wicket - User mailing list archive at
  Nabble.com http://nabble.com/http://nabble.com/
  .
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 

 --
 View this message in context:
 http://www.nabble.com/How-to-delete-an-item-from-List-view.-tp15217608p15268198.html
  Sent from the Wicket - User mailing list archive at 
 Nabble.comhttp://nabble.com/
 .


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




Re: wicketstuff rome and mounting resources

2008-02-04 Thread Michael Sparer

Hi Johan, 

thanks for the quick reply and your suggestions, yepp you're right
especially by saying that's a dangerous thing ... watching superbowl sunday
in europe definitely had an impact on my programming skills today (yes I'm
looking for an excuse for that error in reasoning :-))

regards

Michael



Johan Compagner wrote:
 
 what you do there seems dangerous to me
 
 especially the line:
 
  protected Resource newResource() {
return new
 UserFeedResource(currentUser);
}
 
 currentUser??
 
 Is that the session specific thing?
 that looks a bit weird because if a ResourceReference is binded to the
 SharedResources
 then it first checks if there is a Resource for that reference (and
 reference is class,name,locale and style combo)
 
 So for the second user the first resource will be found...
 
 What you should do is add that UserFeedResource as a shared resource:
 
 application.getSharedResources().add(myFeed,new UserFeedResource());
 
 Then mount it if you like with the
 
 SharedResourceRequestTargetUrlCodingStrategy(myFeed, myFeed)
 (then you get a url like /resources/myFeed)
 
 
 then in your UserFeedResource you lookup the session and get the current
 user from there.
 
 you can stil use the: FeedResource.autodiscoveryLink(new
 ResourceReference(myFeed)
 
 to add a reference to that feed.
 
 johan
 
 
 On Feb 4, 2008 12:42 PM, Michael Sparer [EMAIL PROTECTED] wrote:
 

 Hi,

 I'm using wicketstuff-rome to create and add RSS feeds to certain pages
 of
 my webapplication. The problem I'm now facing is that the feeds do not
 have
 nice URLs as they're in the format e.g.
 http://www.foo.bar/resources/org.apache.wicket.Application/myFeed. It
 would
 be much better to just have them like http://www.foo.bar/feeds/myFeed. I
 add
 the feed to the page like that:

add(FeedResource.autodiscoveryLink(new
 ResourceReference(myFeed) {

private static final long serialVersionUID
 = 1L;

@Override
protected Resource newResource() {
return new
 UserFeedResource(currentUser);
}

}));
 As myFeed needs a session-dependent parameter (currentUser), I can't just
 mount the resource by using mountsharedresource in the application class.
 I had a look at a recent post in the mailinglist
 (http://www.nabble.com/Mounting-shared-resources-to15230311.html), but I
 wondered if they're might be an easier way, as I'd like to use the
 autodiscoveryLink method to add the resources.

 thanks in advance

 Michael

 -
 Michael Sparer
 http://talk-on-tech.blogspot.com
 --
 View this message in context:
 http://www.nabble.com/wicketstuff-rome-and-mounting-resources-tp15266406p15266406.html
 Sent from the Wicket - User mailing list archive at
 Nabble.comhttp://nabble.com/
 .


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


 
 


-
Michael Sparer
http://talk-on-tech.blogspot.com
-- 
View this message in context: 
http://www.nabble.com/wicketstuff-rome-and-mounting-resources-tp15266406p15267599.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: wicketstuff rome and mounting resources

2008-02-04 Thread Johan Compagner
what you do there seems dangerous to me

especially the line:

 protected Resource newResource() {
   return new
UserFeedResource(currentUser);
   }

currentUser??

Is that the session specific thing?
that looks a bit weird because if a ResourceReference is binded to the
SharedResources
then it first checks if there is a Resource for that reference (and
reference is class,name,locale and style combo)

So for the second user the first resource will be found...

What you should do is add that UserFeedResource as a shared resource:

application.getSharedResources().add(myFeed,new UserFeedResource());

Then mount it if you like with the

SharedResourceRequestTargetUrlCodingStrategy(myFeed, myFeed)
(then you get a url like /resources/myFeed)


then in your UserFeedResource you lookup the session and get the current
user from there.

you can stil use the: FeedResource.autodiscoveryLink(new
ResourceReference(myFeed)

to add a reference to that feed.

johan


On Feb 4, 2008 12:42 PM, Michael Sparer [EMAIL PROTECTED] wrote:


 Hi,

 I'm using wicketstuff-rome to create and add RSS feeds to certain pages of
 my webapplication. The problem I'm now facing is that the feeds do not
 have
 nice URLs as they're in the format e.g.
 http://www.foo.bar/resources/org.apache.wicket.Application/myFeed. It
 would
 be much better to just have them like http://www.foo.bar/feeds/myFeed. I
 add
 the feed to the page like that:

add(FeedResource.autodiscoveryLink(new
 ResourceReference(myFeed) {

private static final long serialVersionUID
 = 1L;

@Override
protected Resource newResource() {
return new
 UserFeedResource(currentUser);
}

}));
 As myFeed needs a session-dependent parameter (currentUser), I can't just
 mount the resource by using mountsharedresource in the application class.
 I had a look at a recent post in the mailinglist
 (http://www.nabble.com/Mounting-shared-resources-to15230311.html), but I
 wondered if they're might be an easier way, as I'd like to use the
 autodiscoveryLink method to add the resources.

 thanks in advance

 Michael

 -
 Michael Sparer
 http://talk-on-tech.blogspot.com
 --
 View this message in context:
 http://www.nabble.com/wicketstuff-rome-and-mounting-resources-tp15266406p15266406.html
 Sent from the Wicket - User mailing list archive at 
 Nabble.comhttp://nabble.com/
 .


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




Re: Challenge: write something really sleek for Facebook?

2008-02-04 Thread Jeremy Levy
We have been thinking about this a little bit as well... It broke down into
two parts:

Making FaceBook Wicket components that represent and render the
corresponding FBML.

Integrating the wicket session with facebooks session.  It seemed like to us
that the calls from facebook across multiple users would break / not
maintain a wicket session as well as include an easy mechanism to retrieve
data from facebook.

j



On Feb 2, 2008 5:27 AM, tieTYT [EMAIL PROTECTED] wrote:


 Hi Eelco,

 I wanted to give you an update of what i learned about facebook apps:
 there's 2 types: FBML and IFRAME

 fbml apps are actually translated from your webapp and facebook renders it
 with their server (me thinks).
 the IFRAME app is just literally your app rendered from your server but
 displayed on theirs

 if you want to do it as IFRAME, that wiki post i made is pretty much all
 you
 need...  that and you need to understand how to use the FaceBookRestClient
 that you put in the session.  As I prefer the IFRAME approach, that's what
 i'm going to use.


 Eelco Hillenius wrote:
 
  Hi,
 
  Daniel Kaplan wrote a WIKI page[1] that describes how to set up Wicket
  for Facebook. Someone posted a link to that on DZone[2], and that in
  turn prompted Dave from Alfresco to write an alternative to it that
  shows it can be done much shorter[3]. I know that several people
  posted the idea before of writing a simple integration framework for
  Facebook/ Wicket, but so far no-one actually contributed code (besides
  this WIKI).
 
  How about it? Is that blog posting a challenge enough to come up with
  a simple framework that makes writing Facebook apps with Wicket short
  and elegant? I can imagine we'd need a component (set) and/ or
  specialized models for parsing external REST requests. But maybe I'm
  just talking crap here. Any takers? :-)
 
  Eelco
 
 
  [1]
 http://cwiki.apache.org/confluence/display/WICKET/Facebook+Integration
  [2]
 http://www.dzone.com/links/rss/apache_wicket_facebook_integration.html
  [3] http://blogs.alfresco.com/davidc/?p=12
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

 --
 View this message in context:
 http://www.nabble.com/Challenge%3A-write-something-really-sleek-for-Facebook--tp15220672p15241533.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




Re: User authentication

2008-02-04 Thread Martin Makundi
Hi!

Have a look at Pro Wicket book:
http://books.google.com/books?id=bA8yTZIZQCsChl=fi

It has a nice tutorial on authentication. Furthermore, look at swarm
and wicket auth:
http://wicketstuff.org/confluence/display/STUFFWIKI/Wicket-Security

**
Martin

2008/2/4, Jukka Aittokallio [EMAIL PROTECTED]:

 Hello, I am new to wicket framework. What would be a good place to place
 user authentication? I am creating a website where the session must be
 protected by username, password authentication.

 I was thinking of creating a base class (derived from the WebPage) in
 which I redirect the browser to the logon page if the session doesn't
 have the User-object yet. The logic would be something like

   if (requiresAuthentication()  getUser() == null)

 requiresAuthentication() is a method which can be overrided by actual
 page implementations. For example the login page itself would return
 false from the requiresAuthentication() -function. The default
 implementation returns true.

 When the user have logged in successfully with his password he should be
 redirected to the page of the original request.

 Is this a good way to do this? Where should I put this logic? How should
 the redirection be done?






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



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



Re: How to delete an item from List view.

2008-02-04 Thread Eelco Hillenius
On Feb 4, 2008 3:45 AM, Martijn Dashorst [EMAIL PROTECTED] wrote:
 On 2/3/08, Eelco Hillenius [EMAIL PROTECTED] wrote:
 
  How about a reconsideration of depreciating ListView?


 -1

 If anytime someone comes along with a misunderstanding of a valid component
 we don't have a framework left:
  - models
  - drop down choice
  - urls
  - mounting

 All those things can be deprecated then.

Not true. There are perfectly complete replacements for ListView, not
for the other things you mention.

Eelco

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



Re: Wicket Maven JARs Compiled with Java 6?

2008-02-04 Thread Martijn Dashorst
Yep, only the jar is created with Java 5, but that doesn't affect
the usability with older Java versions.
(this is done because of Maven's inability to not modify jars when they have
been generated and signed already)

Martijn

On 2/4/08, Frank Bille [EMAIL PROTECTED] wrote:

 Hi,

 I'm not entirely sure what you mean. All the jdk-1.4 projects is compiled
 with 1.4 for the releases.

 Frank

 On Feb 4, 2008 4:05 PM, Nick Heudecker [EMAIL PROTECTED] wrote:

  Hi,
 
  I'm getting a number of class not valid errors when my IDE is trying
 to
  autocomplete imports.  Typically this error occurs when I encounter JARs
  compiled with Java 6, while I'm on Java 5.  Can the JARs be compiled
 with
  Java 5, or can multiple versions be made available?  Thanks.
 
  -Nick
 




-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


Re: 2 process cant together in a same time - modal window and form in the same page constructor?

2008-02-04 Thread kenixwong

hi, johan...

what i mean is.. based on the example below: -

a) Parent Page
===

public ParentPage() extends WebPage{


Link reportLink = new Link(link, new Model()){
  @Override
  public void onClick() {
setResponsePage(ReportPage.class);
  }
};

Label label = new Label(linkLabel, text);
reportLink .add(label); 
add(reportLink );


ModalWindow cancelModal = new ModalWindow(cancelModal);
CancelPanel  cancelPanel = new CancelPanel(content,cancelModal);
add(cancelModal);
cancelModal.setContent(cancelPanel);
cancelModal.setPageMapName(cancelModal);


 // to auto pop up the modal window.
 ajaxLink = new AjaxLink(cancelModalLink){
@Override
public void onClick(AjaxRequestTarget target) {
cancelModal.show(target);
}
};
 add(ajaxLink);

  //  Fire the ajaxLink onclick function
 getBodyContainer().addOnLoadModifier(new ClickOnceOnLoadModel( ajaxLink
), null );
 
 add(feedback);
 
}



b) Child page ( My report Page )

public ReportPage() extends ParentPage{
   
 add(feedback);
 add(new ChildPageForm(ChildPageForm));
}


private class ChildPageForm extends Form {
// execute query
// generate the result as Chart ( JFreeChart tool )
// NOTES: taken a long time to load because it generates things
} 


Explanation:
=
Once i click on the reportLink , it will setResponsePage to the
ReportPage.class. So, once it load, for what i expected result is pop up the
modal window and then the reportPage is loading at the backgroup. 

BUT then it was NOT. The actual result that i get is once the report page is
finish loaded then only turn to pop up the modal window. 


yes...you r right, my reportPage will taken a long time to load, because it
generates the chart. That why i need to pop up a modal window at the same
time in order to let the user cancel the reportPage if the user don't wait
for the page finish load.


thanks for your reply...


-kenix


Johan Compagner wrote:
 
 What is that ReportPage is that the page that also loads the modal dialog?
 And that page is taken a long time to load? Because it generates things?
 
 But for the modal dialog to work, the report page (if that is the modal
 dialogs parent)
 must first be fully loaded there is no other way.
 
 I stil dont get exactly what you suspect to happen, you think that the
 parent page
 that generates the report or something and that one doesn't load
 completely
 because it has to wait for the report
 can display the modal dialog already but itself isn't done yet?
 
 johan
 
 
 
 On Feb 4, 2008 2:18 PM, kenixwong [EMAIL PROTECTED] wrote:
 

 thx for reply, johan

 yes..you r right, when i click a link, I want redirect to a load a page
 and
 then at the same time, a modal dialog is show immediately...

 my current testing here is... the modal window component is call at the
 parent class and then the report form is call at child class. Common
 sense,
 all the component at the parent class will call first before the child
 class' component , right...

 yes... right now my page can load the modal window, but it is shown after
 the report page is finish load. The main reason i use the modalwindow is
 feasible the user to make decision whether want terminate the report page
 loading or not ( if the user don't want to wait until the page is finish
 load)

 as what you suggested on Jan 31, 2008.. yes.. i did. Add ajaxlink to call
 the modal window and then onload it. The code that i auto fire the
 ajaxlink
 is

 getBodyContainer().addOnLoadModifier(new ClickOnceOnLoadModel( ajaxLink
 ),
 null );

 which i get the sample resource from this forum

 http://www.nabble.com/modal-window-question---opening-a-modal-window-on-page-load-to12586008.html#a12598786

 yes..it worked. but it is loaded after the page is finish load.  :(


 thanks in advance
 - kenix




 Johan Compagner wrote:
 
  what do you exactly want?
  you want a modal dialog to show immedianlty when another page is
 loaded?
  I think you have to dig into the javascript portion of modal window
 then
  (or
  matej can tell you a bit more)
 
  first of all the page below it has to load first completely because
 that
  does contain the div.
 
  I do think you should think about your gui a bit more and if there
 isn't
 a
  better way of doing stuff
  because showing a modal dialog immediantly on a new page doesn't make
 much
  sense to me in 99.9% of the cases i can think of
 
  johan
 
  On Feb 4, 2008 12:24 PM, kenixwong [EMAIL PROTECTED] wrote:
 
 
  hi,
 
  can anybody share the solution with me ?
 
  is that the javaScript is take time to load for the modal window even
  this
  component is called before the form component is call?
 
 
  anyone can help ? until now i still can't get any solution and
 resource
  

Re: How to delete an item from List view.

2008-02-04 Thread Johan Compagner
wasn't the quickest solution:

public void onSubmit() {
   List vehicles = (List) getParent().getParent().getModelObject();
   vehicles.remove(index);
   listView.removeAll();
}

Then if the list itself is stable on the server side (if other persons can
also delete or add stuff to that list you really should do it differently)
that should work fine. After you alter the listviews model you have to
remove all the items so that it will rebuild

johan




On Feb 1, 2008 12:49 AM, pnerkar [EMAIL PROTECTED] wrote:


 Hi All,

 I have rendered a list view on a Web Page.

 vehicle1X
 vehicle2X
 vehicle3X

 when a person click on 'X', that item should be deleted.
 But I'm facing an issue, when i click on 'X', last item get deleted.
 Actually when I delete vehicle2 from my list, it deletes vehicle2 but that
 component is still there.
 So while rendering it render vehicle1  vehicle2.

 public void onSubmit() {
List vehicles = (List) getParent().getParent().getModelObject();
vehicles.remove(index);
 }

 can please help out ??



 --
 View this message in context:
 http://www.nabble.com/How-to-delete-an-item-from-List-view.-tp15217608p15217608.html
 Sent from the Wicket - User mailing list archive at 
 Nabble.comhttp://nabble.com/
 .


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




Re: Ajax Feedback Problem in 1.3

2008-02-04 Thread SantiagoA

Hi again,

I made a little example project with eclipse where you could take a look at
the problem, because maybe my english is not good enough to explain right.
Is there a possibility that I can send you the example as a zip-file?
I made to little examples, one running with the 1.3.0 final version, one
with the 1.2.6 version.

thanks again for your time,
Santiago
-- 
View this message in context: 
http://www.nabble.com/Ajax-Feedback-Problem-in-1.3-tp14191234p15266481.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: 2 process cant together in a same time - modal window and form in the same page constructor?

2008-02-04 Thread Johan Compagner
what do you exactly want?
you want a modal dialog to show immedianlty when another page is loaded?
I think you have to dig into the javascript portion of modal window then (or
matej can tell you a bit more)

first of all the page below it has to load first completely because that
does contain the div.

I do think you should think about your gui a bit more and if there isn't a
better way of doing stuff
because showing a modal dialog immediantly on a new page doesn't make much
sense to me in 99.9% of the cases i can think of

johan

On Feb 4, 2008 12:24 PM, kenixwong [EMAIL PROTECTED] wrote:


 hi,

 can anybody share the solution with me ?

 is that the javaScript is take time to load for the modal window even this
 component is called before the form component is call?


 anyone can help ? until now i still can't get any solution and resource
 yet...


 thanks in advance,...
 - kenix



 kenixwong wrote:
 
  2 process cant together in a same time - modal window and form in the
 same
  page constructor?  Is because the process haven't done, so the request
  wont send to wicket there?
 
  The main  reason i want to implement this features, caused modal window
  can prevent the user navigate to other page or feasible the user to
 cancel
  the form process if the loading time is longer. Another point is,
 because
  my report page is loading with JFreeChart to generate the chart report.
 If
  the user press right click to Open Link in new tab, the chart at the
  previous tab will have the broken link issue means the chart is cant
  display. So, modal window can play an important role here...
 
 
  I was using the wicket 1.2.4. Is it the version cant support it and i
 need
  to upgrade ? i read from
  http://cwiki.apache.org/WICKET/wicket-130-rc1.html .. Migration from 1.2
  to 1.3, there is not much different for the modal window in both
 version..
  can anyone give some solution to me?
 
 
  Thanks in advance
  - kenix
 
 
 
 
 
  kenixwong wrote:
 
  thanks for reply, johan
 
  i want to show the modal window once the report page is load. Mean
  background is continue loading the report and the modal window is just
 as
  a control (its features is invisible the background and only close once
  action performed is click in the modal window ) to prevent user
 navigate
  to other page. For the modal window it only define one cancel button,
  mean if user click the cancel button, the background ( report page ) is
  stop.
 
  Yes... the modal window is only shown by an ajax link. I get the source
  from this forum ..where it can fire the ajaxlink whitout click the
 link.
  Here is the code
 
   getBodyContainer().addOnLoadModifier(new ClickOnceOnLoadModel(
  ajaxLink ), null );   
 
  Even i tried to create a modal window with ajaxlink ( add auto fire
 event
  as above code ) and put at the parent class and the report page is the
  child class. But the result is same, the report page is finish loaded
  then only pop up the modal window.
 
  my report page constructor :
 
  public LineChart() {
  /// modal window use panel..declare the modal window setting here
  then add
   add(modalWindow);
 
   // to auto pop up the modal window.
   ajaxLink = new AjaxLink(cancelReportModalLink){
  @Override
  public void onClick(AjaxRequestTarget target) {
  cancelReportModal.show(target);
  }
  };
   add(ajaxLink);
 
//  Fire the ajaxLink onclick function
   getBodyContainer().addOnLoadModifier(new ClickOnceOnLoadModel(
  ajaxLink ), null );
 
   add(feedback);
   add(new LineChartForm(LineChartForm));
  }
 
 
  private class LineChartForm extends Form {
  // execute query
  // result as in JFreeChart
  }
 
 
  i add the component for modal window then only come to form. supposedly
  it will show the modal window then load the form, am i right . Why ? 2
  process in a same time cant together?  Is because the process haven't
  done, so the request wont send to wicket there,
 
  2 way i tried. Call the modal window at Parent class and also child
  class. But it still given me the same result.
 
  between, can you explain more or give example for the onload event that
  you mentioned ? onLoad event for the modal window ? I was using the
  wicket 1.2.4. Is it the version cant support it and i need to upgrade ?
 
 
 
  Thanks in advance
 
  - kenix
 
 
 
 
 
  Johan Compagner wrote:
 
  how do you show the modal dialog??
  Normally the modal dialog is only shown by an ajax link.
  I guess you show it on onload event. Then yes the page will first load
  itself
  then call onload and then the modal window will show itself
 
  johan
 
 
 
  On Jan 31, 2008 6:16 AM, kenixwong [EMAIL PROTECTED] wrote:
 
 
  hi,
 
  for the above case, for example... my page constructor: i add the
  component
  ( modal window, feedBackPanel, form ) . Once i load the page, why the
  modal
  

Re: How to delete an item from List view.

2008-02-04 Thread Martijn Dashorst
On 2/3/08, Eelco Hillenius [EMAIL PROTECTED] wrote:

 How about a reconsideration of depreciating ListView?


-1

If anytime someone comes along with a misunderstanding of a valid component
we don't have a framework left:
 - models
 - drop down choice
 - urls
 - mounting

All those things can be deprecated then.

Martijn

-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


wicketstuff rome and mounting resources

2008-02-04 Thread Michael Sparer

Hi, 

I'm using wicketstuff-rome to create and add RSS feeds to certain pages of
my webapplication. The problem I'm now facing is that the feeds do not have
nice URLs as they're in the format e.g.
http://www.foo.bar/resources/org.apache.wicket.Application/myFeed. It would
be much better to just have them like http://www.foo.bar/feeds/myFeed. I add
the feed to the page like that:

add(FeedResource.autodiscoveryLink(new 
ResourceReference(myFeed) {

private static final long serialVersionUID = 1L;

@Override
protected Resource newResource() {
return new 
UserFeedResource(currentUser);
}

}));
As myFeed needs a session-dependent parameter (currentUser), I can't just
mount the resource by using mountsharedresource in the application class.
I had a look at a recent post in the mailinglist
(http://www.nabble.com/Mounting-shared-resources-to15230311.html), but I
wondered if they're might be an easier way, as I'd like to use the
autodiscoveryLink method to add the resources.

thanks in advance

Michael

-
Michael Sparer
http://talk-on-tech.blogspot.com
-- 
View this message in context: 
http://www.nabble.com/wicketstuff-rome-and-mounting-resources-tp15266406p15266406.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



User authentication

2008-02-04 Thread Jukka Aittokallio

Hello, I am new to wicket framework. What would be a good place to place
user authentication? I am creating a website where the session must be
protected by username, password authentication.

I was thinking of creating a base class (derived from the WebPage) in
which I redirect the browser to the logon page if the session doesn't
have the User-object yet. The logic would be something like

  if (requiresAuthentication()  getUser() == null)

requiresAuthentication() is a method which can be overrided by actual
page implementations. For example the login page itself would return
false from the requiresAuthentication() -function. The default
implementation returns true.

When the user have logged in successfully with his password he should be
redirected to the page of the original request.

Is this a good way to do this? Where should I put this logic? How should
the redirection be done? 






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



Re: AjaxLink, BookmarkablePageLink and feedback problem

2008-02-04 Thread Igor Vaynberg
please file a jira issue with a quickstart

-igor

On Feb 4, 2008 7:41 AM, Vatroslav [EMAIL PROTECTED] wrote:

 I have noticed very strange behaviour of feedback messages when using
 AjaxLink and BookmarkablePageLink on the same page.

 Code example is attached to the message.
 http://www.nabble.com/file/p15269007/Feedback_example.txt
 Feedback_example.txt


 How to reproduce it..

 1st Case (working)
 a) Disable (remove) first link (HomePageTest): test
 b) Click on feedback test
 c) Type something and press submit button few times - new message
 overwrites last one, that is OK.

 2nd Case (non working)
 a) Enable first link (HomePageTest): test
 b) Click on feedback test
 c) Type something and press submit button few times: last message is
 displayed (inside feedback panel) below previous one!

 I have problem with required fields in my program because feedback messages
 are never cleared.

 I'm using new release: 1.3.1 (it doesn't work with 1.3.0, either).

 Thanks in advance,
 Vatroslav


 --
 View this message in context: 
 http://www.nabble.com/AjaxLink%2C-BookmarkablePageLink-and-feedback-problem-tp15269007p15269007.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



Re: Wicket Maven JARs Compiled with Java 6?

2008-02-04 Thread Nick Heudecker
Looks like both 1.3.0 and 1.3.1 were both built with Java 5.  Not sure what
the problem was, but upgrading to 1.3.1 fixed it.

On Feb 4, 2008 9:05 AM, Nick Heudecker [EMAIL PROTECTED] wrote:

 Hi,

 I'm getting a number of class not valid errors when my IDE is trying to
 autocomplete imports.  Typically this error occurs when I encounter JARs
 compiled with Java 6, while I'm on Java 5.  Can the JARs be compiled with
 Java 5, or can multiple versions be made available?  Thanks.

 -Nick



onComponentTag vs AttributeModifier

2008-02-04 Thread Fernando Wermus
Hi all,
  I have a combobox which is available when a checkbox is clicked. I
try to implement this behavior using AttributeModifier class and onComponent
tag method. The first one I failed to get the behavior working and the
second one I succeed. Using AttributeModifier renders well the first time,
but It doesn't notice the change next times. Is this the correct behavior or
not? The condition to available the combobox is of course the same.

-- 
Fernando Wermus.


Re: How to delete an item from List view.

2008-02-04 Thread pnerkar

Hi Johan,

Yes that will be quickest solution , 
But this will clear the fields of all vehicles.

-Pnerkar


Johan Compagner wrote:
 
 wasn't the quickest solution:
 
 public void onSubmit() {
List vehicles = (List) getParent().getParent().getModelObject();
vehicles.remove(index);
listView.removeAll();
 }
 
 Then if the list itself is stable on the server side (if other persons can
 also delete or add stuff to that list you really should do it differently)
 that should work fine. After you alter the listviews model you have to
 remove all the items so that it will rebuild
 
 johan
 
 
 
 
 On Feb 1, 2008 12:49 AM, pnerkar [EMAIL PROTECTED] wrote:
 

 Hi All,

 I have rendered a list view on a Web Page.

 vehicle1X
 vehicle2X
 vehicle3X

 when a person click on 'X', that item should be deleted.
 But I'm facing an issue, when i click on 'X', last item get deleted.
 Actually when I delete vehicle2 from my list, it deletes vehicle2 but
 that
 component is still there.
 So while rendering it render vehicle1  vehicle2.

 public void onSubmit() {
List vehicles = (List) getParent().getParent().getModelObject();
vehicles.remove(index);
 }

 can please help out ??



 --
 View this message in context:
 http://www.nabble.com/How-to-delete-an-item-from-List-view.-tp15217608p15217608.html
 Sent from the Wicket - User mailing list archive at
 Nabble.comhttp://nabble.com/
 .


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


 
 

-- 
View this message in context: 
http://www.nabble.com/How-to-delete-an-item-from-List-view.-tp15217608p15268198.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: anyone in pune want to represent?

2008-02-04 Thread karthik Guru
There are at least 2 companies for sure that work on wicket in pune, India.
I met them while at a conference there a few months back.  I think I have
their email - I will put a word from my side as well for sure.

- Karthik

On Feb 4, 2008 1:32 AM, Jonathan Locke [EMAIL PROTECTED] wrote:


 i saw this today on facebook from my old javasoft buddy freeman...

 http://barcamp.org/BarCampPune4


 --
 View this message in context:
 http://www.nabble.com/anyone-in-pune-want-to-represent--tp15263298p15263298.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




-- 
-- karthik --


Re: Wicket Maven JARs Compiled with Java 6?

2008-02-04 Thread Nick Heudecker
Thanks for the info.  I'm not sure what the problem was, but upgrading fixed
it.

On Feb 4, 2008 9:38 AM, Martijn Dashorst [EMAIL PROTECTED] wrote:

 Yep, only the jar is created with Java 5, but that doesn't affect
 the usability with older Java versions.
 (this is done because of Maven's inability to not modify jars when they
 have
 been generated and signed already)

 Martijn

 On 2/4/08, Frank Bille [EMAIL PROTECTED] wrote:
 
  Hi,
 
  I'm not entirely sure what you mean. All the jdk-1.4 projects is
 compiled
  with 1.4 for the releases.
 
  Frank
 
  On Feb 4, 2008 4:05 PM, Nick Heudecker [EMAIL PROTECTED] wrote:
 
   Hi,
  
   I'm getting a number of class not valid errors when my IDE is trying
  to
   autocomplete imports.  Typically this error occurs when I encounter
 JARs
   compiled with Java 6, while I'm on Java 5.  Can the JARs be compiled
  with
   Java 5, or can multiple versions be made available?  Thanks.
  
   -Nick
  
 



 --
 Buy Wicket in Action: http://manning.com/dashorst
 Apache Wicket 1.3.0 is released
 Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0



Session Expiration. UnauthorizedComponentInstantiationException. PageExpiredException. IllegalStateException. Ajax and Bookmarkable links.

2008-02-04 Thread Matt Smith
A co-worker and I are looking into how to provide a consistent
handling of session expiration with an AuthenticatedWebApplication.

If a session expires, ideally, we'd like to provide a consistent
behavior of redirecting to a login page with a helpful message (i.e. -
Your session expired, please re-login), re-authenticate, and then
proceed to the original request regardless of what type of request is
made of the server.

Examples of the scenarios we'd like to handle consistently are:
1.   User logs in.  Session expires, then user clicks a wicket
generated Page link.
2.   User logs in.  Session expires, then user clicks the back button
in the browser and then clicks on a wicket generated component link.
3.   User logs in.  User performs an action which results in them
being redirected to a bookmarkable page.  The session expires, then
user submits a form
4.   User logs in.  User performs an action which results in them
being redirected to a bookmarkable page.  The session expires, then
user clicks a wicket generated link on the current page.
5.   User logs in.  User performs an action which results in them
being redirected to a bookmarkable page.  The session expires, then
user triggers an AJAX request of the server.
6.   User logs in.  The session expires.  User then triggers an AJAX
request of the server.
7.   User logs in.  The session expires, then user gets redirected to
login page (thus creating a new session).   User then clicks back and
clicks on a wicket generated link, gets redirected to a login page,
clicks back, clicks a wicket generated link.

The examples above seem to cause various behaviors in:
#1.  The Web app's UnauthorizedComponentInstantiation listener is
fired and given the page the user was on as an argument (thus
redirecting them directly to the page without a message).
#2 throws an UnauthorizedComponentInstantiationException
#3 throws a PageExpiredException
#4 throws a PageExpiredException
#5 throws a PageExpiredException
#6 throws an IllegalStateException (unmatched key/value pairs).
#7  A WicketRuntimeException exception is thrown (component not found
in page)(because the page id in the link is referring to a different
page in the current/new session than the page it referred to in the
old session).  It seems that using nextnumber id's (starting at 0)
allows for potential overlap in id's between a new session and an old
session.

We are able to handle PageExpiredException consistently by overriding
onRuntimeException() in our own custom RequestCycle.

Is there a way we can specify some consistent behavior for the other scenarios?

- Matt
http://netsmith.blogspot.com

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



Re: Using IInitializer and wicket.properties with Databinder

2008-02-04 Thread Johan Compagner
yes init is called before i do see this:


// Call internal init method of web application for default

// initialization

webApplication.internalInit();

// Call init method of web application

webApplication.init();

// We initialize components here rather than in the constructor or

// in the internal init, because in the init method class aliases

// can be added, that would be used in installing resources in the

// component.

webApplication.initializeComponents();
Look that last part... its meant this way because class alliasses can be
added that are then being used again in the iinitializers

johan



On Feb 4, 2008 3:06 AM, Daniel Walmsley [EMAIL PROTECTED] wrote:

  I am currently having great fun (no, I'm not being sarcastic) with
 Wicket's IInitializer plugin mechanism, using it to plug additional
 functionality into a basic CMS framework (e.g. news feeds, video upload,
 etc). Just hit a brick wall though - it seems as through the initializers
 are called too late for me to configure annotated entities for Databinder's
 Hibernate session (which makes sense, I suppose - you need to give the
 WebApplication a chance to run init() before all your other components
 register themselves).

 Has anyone else tried to plug data-bound sub-projects into a Wicket
 project? How did you register the plug-in's persistent entities without
 recreating the entire SessionFactory after all the Iinitializers have been
 called? For that matter, how do you _know_ when all the IInitializers have
 been called?

 Thanks,
 Dan

   * Daniel Walmsley
 Director, Firesyde http://firesyde.com/
 e: [EMAIL PROTECTED]
 m: +61404864141
 *





Re: adding conditional component

2008-02-04 Thread Janos Cserep

 How do you guys implement a link that is conditional? Like for example the
 link only shows if a given data is provided. Adding the a-tag in the
 Markup will coz an error if the condition is not met, because AjaxLink is
 not added.


I usually handle such a situation by overriding the isVisible() method of
the component:

add(new Link(link) {

@Override
public boolean isVisible() {
boolean externalCondition = ;
return super.isVisible()  externalCondition;
}

});


The type wicket.Component cannot be resolved. It is indirectly referenced The type wicket.Component cannot be resolved. It is indirectly referenced from required .class files

2008-02-04 Thread Fernando Wermus
Hi all!
I got this error message from Eclipse when I download DataPicker
library and append the following line to the code,

DateTextField bornDate=new DateTextField(player);
bornDate.add(new DatePicker());

It seems to be a problem with Eclipse according to google, instead of
Wicket. But I couldn't solve it.
Does anyone happend this before?

Thanks!
-- 
Fernando Wermus.


adding conditional component

2008-02-04 Thread Beyonder Unknown

Hi all,

How do you guys implement a link that is conditional? Like for example the link 
only shows if a given data is provided. Adding the a-tag in the Markup will 
coz an error if the condition is not met, because AjaxLink is not added.


Thanks!
Wen Tong
 
--
The only constant in life is change.




  

Be a better friend, newshound, and 
know-it-all with Yahoo! Mobile.  Try it now.  
http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ 


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



Re: The type wicket.Component cannot be resolved. It is indirectly referenced The type wicket.Component cannot be resolved. It is indirectly referenced from required .class files

2008-02-04 Thread Martijn Dashorst
Read about models [1], and make sure you have attached a model to your date
field.
Martijn

[1] Working with Wicket
modelshttp://cwiki.apache.org/WICKET/working-with-wicket-models.html

On 2/4/08, Fernando Wermus [EMAIL PROTECTED] wrote:

 Hi all!
 I got this error message from Eclipse when I download DataPicker
 library and append the following line to the code,

 DateTextField bornDate=new DateTextField(player);
 bornDate.add(new DatePicker());

 It seems to be a problem with Eclipse according to google, instead of
 Wicket. But I couldn't solve it.
 Does anyone happend this before?

 Thanks!
 --
 Fernando Wermus.




-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


Re: Wicket menus?

2008-02-04 Thread Edvin Syse
That's purely a css issue, most menues are laid out using an ul and  
styled accordingly these days :)


-- Edvin

On 4. feb.. 2008, at 23.18, davout [EMAIL PROTECTED] wrote:



Are there any demos to show how Wicket supports vertically  
orientated menus?

--
View this message in context: 
http://www.nabble.com/Wicket-menus--tp15278751p15278751.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



RE: Challenge: write something really sleek for Facebook?

2008-02-04 Thread Dan Kaplan
As I understand facebook apps more, I see that this separation is distinct.
That being said, I don't understand your last paragraph.  I think I already
accomplished that with the wiki post.

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Jeremy Levy
Sent: Monday, February 04, 2008 11:19 AM
To: users@wicket.apache.org
Subject: Re: Challenge: write something really sleek for Facebook?

We have been thinking about this a little bit as well... It broke down into
two parts:

Making FaceBook Wicket components that represent and render the
corresponding FBML.

Integrating the wicket session with facebooks session.  It seemed like to us
that the calls from facebook across multiple users would break / not
maintain a wicket session as well as include an easy mechanism to retrieve
data from facebook.

j



On Feb 2, 2008 5:27 AM, tieTYT [EMAIL PROTECTED] wrote:


 Hi Eelco,

 I wanted to give you an update of what i learned about facebook apps:
 there's 2 types: FBML and IFRAME

 fbml apps are actually translated from your webapp and facebook renders it
 with their server (me thinks).
 the IFRAME app is just literally your app rendered from your server but
 displayed on theirs

 if you want to do it as IFRAME, that wiki post i made is pretty much all
 you
 need...  that and you need to understand how to use the FaceBookRestClient
 that you put in the session.  As I prefer the IFRAME approach, that's what
 i'm going to use.


 Eelco Hillenius wrote:
 
  Hi,
 
  Daniel Kaplan wrote a WIKI page[1] that describes how to set up Wicket
  for Facebook. Someone posted a link to that on DZone[2], and that in
  turn prompted Dave from Alfresco to write an alternative to it that
  shows it can be done much shorter[3]. I know that several people
  posted the idea before of writing a simple integration framework for
  Facebook/ Wicket, but so far no-one actually contributed code (besides
  this WIKI).
 
  How about it? Is that blog posting a challenge enough to come up with
  a simple framework that makes writing Facebook apps with Wicket short
  and elegant? I can imagine we'd need a component (set) and/ or
  specialized models for parsing external REST requests. But maybe I'm
  just talking crap here. Any takers? :-)
 
  Eelco
 
 
  [1]
 http://cwiki.apache.org/confluence/display/WICKET/Facebook+Integration
  [2]
 http://www.dzone.com/links/rss/apache_wicket_facebook_integration.html
  [3] http://blogs.alfresco.com/davidc/?p=12
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

 --
 View this message in context:

http://www.nabble.com/Challenge%3A-write-something-really-sleek-for-Facebook
--tp15220672p15241533.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




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



Re: The type wicket.Component cannot be resolved. It is indirectly referenced The type wicket.Component cannot be resolved. It is indirectly referenced from required .class files

2008-02-04 Thread Martin Funk
As I don't have a percise answer I can only come up with some trivia you
already might have thought of.

If you project is 'mavenized' a
mvn eclipse:clean eclipse:eclipse
might help.

Other than that, a 'clean build' in eclipse.

Martin

2008/2/4, Fernando Wermus [EMAIL PROTECTED]:

 Hi all!
 I got this error message from Eclipse when I download DataPicker
 library and append the following line to the code,

 DateTextField bornDate=new DateTextField(player);
 bornDate.add(new DatePicker());

 It seems to be a problem with Eclipse according to google, instead of
 Wicket. But I couldn't solve it.
 Does anyone happend this before?

 Thanks!
 --
 Fernando Wermus.



Wicket menus?

2008-02-04 Thread davout

Are there any demos to show how Wicket supports vertically orientated menus?
-- 
View this message in context: 
http://www.nabble.com/Wicket-menus--tp15278751p15278751.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: Workaround for AjaxEditableLabel yields java.lang.IllegalAccessError (WICKET-1239)?

2008-02-04 Thread Martijn Dashorst
You mean the 1.3.0-snapshot dirs?
If so, then yes.

Martijn

On 2/2/08, Johan Compagner [EMAIL PROTECTED] wrote:

 it works now
 all the poms where changed to 1.3 instead of 1.3.0 so the shell script
 still
 copied the wrong one.

 can i delete all the 1.3.0 dirs??

 johan



 On Feb 2, 2008 3:36 PM, Gerolf Seitz [EMAIL PROTECTED] wrote:

  i have reopened the issue, as the exception is still thrown (at least on
  wicketstuff.org) :/
 
  see http://wicketstuff.org/wicket13/ajax/editable-label and try it with
  any
  of the two labels fox
  and dog.
 
   gerolf
 
  On Jan 31, 2008 7:45 PM, Per Ejeklint [EMAIL PROTECTED] wrote:
 
  
   Nice! Thank you Gerolf.
  
   /Per
  
  
   Gerolf Seitz wrote:
   
i'm sorry this one slipped through.
i commited Per's fix.
   
Edvin, can you try with latest trunk to verify it's fixed?
   
  gerolf
   
On Jan 31, 2008 8:53 AM, Edvin Syse [EMAIL PROTECTED] wrote:
   
Advanced Technology(R) skrev:
 Check Per solution :

   
  
 
 http://www.nabble.com/AjaxEditableLabel-in-1.3.0-tp14675483p14687720.html
   
Thanks! Worked like a charm. For some reason this didn't make it
 into
1.3.1, though..
   
-- Edvin
   
   
 -
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
   
   
   
   
  
   --
   View this message in context:
  
 
 http://www.nabble.com/Workaround-for-%22AjaxEditableLabel-yields-java.lang.IllegalAccessError-%28WICKET-1239%29%22--tp15193816p15211776.html
   Sent from the Wicket - User mailing list archive at Nabble.com
 http://nabble.com/
  .
  
  
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
 




-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


Re: inmethod grid links?

2008-02-04 Thread Matej Knopp
Hi,

that would be a bug, are you using latest svn version?

-Matej

On Feb 5, 2008 12:16 AM, Ryan McKinley [EMAIL PROTECTED] wrote:
 I'm trying to add a href=... links withing the inmethod grid
 component.  Clicking on the link does not do anything -- i think this is
 becasue the row onclick event eats it up.

 I was able to make things work by adding an AttributeModifier to the
 link and calling javascript for document.location=URL

 Is there a better way to have links in the grid?

 Thanks again -- this is a really great component!

 ryan

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





-- 
Resizable and reorderable grid components.
http://www.inmethod.com

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



Delaying AutoCompleteTextField by n characters?

2008-02-04 Thread Michael Mehrle
What is the preferred way of delaying the Javascript call to
getChoices() until a certain amount of characters have been types in? I
guess I could just put in some kind of if condition that checks the
input string's length, but I was wondering if there's a more elegant way
of doing this.

Thanks!

Michael


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



wicket:link with images supported?

2008-02-04 Thread oliverw

Is a construct like this supported:

wicket:link Page1.html  /img/Page1.gif  /wicket:link

I'm asking because I'm getting really strange results when using it.
Initially everything looks ok but after hitting the backbutton, the image is
suddenly in the page history as if it was a stand-alone page.
-- 
View this message in context: 
http://www.nabble.com/wicket%3Alink-with-images-supported--tp15280790p15280790.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: inmethod grid links?

2008-02-04 Thread Ryan McKinley

yes, latest from svn
mvn clean install

thanks
ryan


Matej Knopp wrote:

Hi,

that would be a bug, are you using latest svn version?

-Matej

On Feb 5, 2008 12:16 AM, Ryan McKinley [EMAIL PROTECTED] wrote:

I'm trying to add a href=... links withing the inmethod grid
component.  Clicking on the link does not do anything -- i think this is
becasue the row onclick event eats it up.

I was able to make things work by adding an AttributeModifier to the
link and calling javascript for document.location=URL

Is there a better way to have links in the grid?

Thanks again -- this is a really great component!

ryan

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









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



Re: How to delete an item from List view.

2008-02-04 Thread Igor Vaynberg
you lose values that werent validated if you do that, because those
are stored in components themselves...

-igor


On Feb 4, 2008 6:15 AM, Johan Compagner [EMAIL PROTECTED] wrote:
 You do use a delete button, so i guess the values are submitted.
 Then if you store those first in the model objects you won't loose anything

 johan




 On Feb 4, 2008 2:35 PM, pnerkar [EMAIL PROTECTED] wrote:

 
  Hi Johan,
 
  Yes that will be quickest solution ,
  But this will clear the fields of all vehicles.
 
  -Pnerkar
 
 
  Johan Compagner wrote:
  
   wasn't the quickest solution:
  
   public void onSubmit() {
  List vehicles = (List) getParent().getParent().getModelObject();
  vehicles.remove(index);
  listView.removeAll();
   }
  
   Then if the list itself is stable on the server side (if other persons
  can
   also delete or add stuff to that list you really should do it
  differently)
   that should work fine. After you alter the listviews model you have to
   remove all the items so that it will rebuild
  
   johan
  
  
  
  
   On Feb 1, 2008 12:49 AM, pnerkar [EMAIL PROTECTED] wrote:
  
  
   Hi All,
  
   I have rendered a list view on a Web Page.
  
   vehicle1X
   vehicle2X
   vehicle3X
  
   when a person click on 'X', that item should be deleted.
   But I'm facing an issue, when i click on 'X', last item get deleted.
   Actually when I delete vehicle2 from my list, it deletes vehicle2 but
   that
   component is still there.
   So while rendering it render vehicle1  vehicle2.
  
   public void onSubmit() {
  List vehicles = (List) getParent().getParent().getModelObject();
  vehicles.remove(index);
   }
  
   can please help out ??
  
  
  
   --
   View this message in context:
  
  http://www.nabble.com/How-to-delete-an-item-from-List-view.-tp15217608p15217608.html
   Sent from the Wicket - User mailing list archive at
   Nabble.com http://nabble.com/http://nabble.com/
   .
  
  
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
  
  
 
  --
  View this message in context:
  http://www.nabble.com/How-to-delete-an-item-from-List-view.-tp15217608p15268198.html
   Sent from the Wicket - User mailing list archive at 
  Nabble.comhttp://nabble.com/

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


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



strange DropDownChoice display

2008-02-04 Thread dvd
Hello:
I am using two dropdownchoices, after the first select, the second would get 
data  on the fly using the first choice. The first round everything is fine 
with both displaying Choose One  and selecting the first one set the correct 
second one list of choice with Choose One still displaying on the second so 
that one could click on it to pick the right one. After the first round, I 
select a different value in the first one, which resets correctly the second 
one' list as in the first round but strangely this time, the 'Choose One 
display is gone in the second dropdownchoice. Instead it shows the first item 
of the new list.  I used the wicket-examples sample code as basis  and use 
getObject() to load the correct list when selection on the first changed.
Thanks

Re: strange DropDownChoice display

2008-02-04 Thread Igor Vaynberg
whe the first is submitted you have to set the second one's model object to null

-igor


On Feb 4, 2008 4:59 PM,  [EMAIL PROTECTED] wrote:
 Hello:
 I am using two dropdownchoices, after the first select, the second would get 
 data  on the fly using the first choice. The first round everything is fine 
 with both displaying Choose One  and selecting the first one set the 
 correct second one list of choice with Choose One still displaying on the 
 second so that one could click on it to pick the right one. After the first 
 round, I select a different value in the first one, which resets correctly 
 the second one' list as in the first round but strangely this time, the 
 'Choose One display is gone in the second dropdownchoice. Instead it shows 
 the first item of the new list.  I used the wicket-examples sample code as 
 basis  and use getObject() to load the correct list when selection on the 
 first changed.
 Thanks

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



Re: Wicket menus?

2008-02-04 Thread Martin Makundi
For more on modern layout, see http://www.hotdesign.com/seybold/everything.html

**
Martin

2008/2/4, Edvin Syse [EMAIL PROTECTED]:
 That's purely a css issue, most menues are laid out using an ul and
 styled accordingly these days :)

 -- Edvin

 On 4. feb.. 2008, at 23.18, davout [EMAIL PROTECTED] wrote:

 
  Are there any demos to show how Wicket supports vertically
  orientated menus?
  --
  View this message in context: 
  http://www.nabble.com/Wicket-menus--tp15278751p15278751.html
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 

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



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



Re: The type wicket.Component cannot be resolved. It is indirectly referenced The type wicket.Component cannot be resolved. It is indirectly referenced from required .class files

2008-02-04 Thread Fernando Wermus
Some people agree on that the problem is because of dependences and my
proyect is not 'mavenized'. However, I looked at /lib in the downloaded zip
file and I have all the dependences except wicket 1.2.3 (I am using 1.3).

The only two are,

commons-logging-1.0.4 and log4j-1.2.13

Any other suggestion?

On Feb 4, 2008 6:10 PM, Martin Funk [EMAIL PROTECTED] wrote:

 As I don't have a percise answer I can only come up with some trivia you
 already might have thought of.

 If you project is 'mavenized' a
 mvn eclipse:clean eclipse:eclipse
 might help.

 Other than that, a 'clean build' in eclipse.

 Martin

 2008/2/4, Fernando Wermus [EMAIL PROTECTED]:
 
  Hi all!
  I got this error message from Eclipse when I download DataPicker
  library and append the following line to the code,
 
  DateTextField bornDate=new DateTextField(player);
  bornDate.add(new DatePicker());
 
  It seems to be a problem with Eclipse according to google, instead of
  Wicket. But I couldn't solve it.
  Does anyone happend this before?
 
  Thanks!
  --
  Fernando Wermus.
 




-- 
Fernando Wermus.


Re: onComponentTag vs AttributeModifier

2008-02-04 Thread Timo Rantalaiho
On Mon, 04 Feb 2008, Fernando Wermus wrote:
   I have a combobox which is available when a checkbox is clicked. I
 try to implement this behavior using AttributeModifier class and onComponent
 tag method. The first one I failed to get the behavior working and the
 second one I succeed. Using AttributeModifier renders well the first time,
 but It doesn't notice the change next times. Is this the correct behavior or
 not? The condition to available the combobox is of course the same.

Some code would be helpful, otherwise we have to get our
crystal balls out of the closet :)

Best wishes,
Timo

-- 
Timo Rantalaiho   
Reaktor Innovations OyURL: http://www.ri.fi/ 

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



Re: The type wicket.Component cannot be resolved. It is indirectly referenced The type wicket.Component cannot be resolved. It is indirectly referenced from required .class files

2008-02-04 Thread Timo Rantalaiho
On Tue, 05 Feb 2008, Fernando Wermus wrote:
 Some people agree on that the problem is because of dependences and my
 proyect is not 'mavenized'. However, I looked at /lib in the downloaded zip
 file and I have all the dependences except wicket 1.2.3 (I am using 1.3).

Are you using some library that is meant for Wicket 1.2? In 
1.2, the base package name is wicket but in 1.3, it's 
org.apache.wicket.

Best wishes,
Timo

-- 
Timo Rantalaiho   
Reaktor Innovations OyURL: http://www.ri.fi/ 

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



Re: strange DropDownChoice display

2008-02-04 Thread dvd
The following is the code sample

class webpage
  String secondchoiceSelected;
 

  }
  new Firstdropdownchoice( ){
 onSelectionChange{
   secondchoiceSelected = null;
  }


I did set to null. This issue is that the displayed value is
the first item of the new list, instead of Choose One, it is not
displaying the old secondVarSelected since I already set it to null.
Basically, when the dropdownchoice is redisplayed and is model is
null, it is supposed to display the same as the first created. It does
not appear this way.




whe the first is submitted you have to set the second one's model object to 
null

-igor


On Feb 4, 2008 4:59 PM,  [EMAIL PROTECTED] wrote:
 Hello:
 I am using two dropdownchoices, after the first select, the second would get 
data  on the fly using the first choice. The first round everything is fine 
with both displaying Choose One  and selecting the first one set the correct 
second one list of choice with Choose One still displaying on the second so 
that one could click on it to pick the right one. After the first round, I 
select a different value in the first one, which resets correctly the second 
one' list as in the first round but strangely this time, the 'Choose One 
display is gone in the second dropdownchoice. Instead it shows the first item 
of the new list.  I used the wicket-examples sample code as basis  and use 
getObject() to load the correct list when selection on the first changed.
 Thanks

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


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



Re: The type wicket.Component cannot be resolved. It is indirectly referenced The type wicket.Component cannot be resolved. It is indirectly referenced from required .class files

2008-02-04 Thread Fernando Wermus
Martjin,
   I've attached it. I got the problem when I add the DataPicker to the
DateTextField; without the DataPicker, it works.

Fernando.

On Feb 4, 2008 6:15 PM, Martijn Dashorst [EMAIL PROTECTED] wrote:

 Read about models [1], and make sure you have attached a model to your
 date
 field.
 Martijn

 [1] Working with Wicket
 modelshttp://cwiki.apache.org/WICKET/working-with-wicket-models.html

 On 2/4/08, Fernando Wermus [EMAIL PROTECTED] wrote:
 
  Hi all!
  I got this error message from Eclipse when I download DataPicker
  library and append the following line to the code,
 
  DateTextField bornDate=new DateTextField(player);
  bornDate.add(new DatePicker());
 
  It seems to be a problem with Eclipse according to google, instead of
  Wicket. But I couldn't solve it.
  Does anyone happend this before?
 
  Thanks!
  --
  Fernando Wermus.
 



 --
 Buy Wicket in Action: http://manning.com/dashorst
 Apache Wicket 1.3.0 is released
 Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0




-- 
Fernando Wermus.


Wicket Phone Book example

2008-02-04 Thread Omair Aasim

Hello,
I'm pretty new to wicket and tried out the phonebook
example by downloading the war file and deployed it on
tomcat and it worked fine.

Later i downloaded the source code and without making
any modifications, compiled it using Maven, created
the war file and deployed it again. But this new war
file is throwing the following error:
*
exception
javax.servlet.ServletException: Servlet.init() for
servlet phonebook threw exception

root cause
java.lang.IncompatibleClassChangeError
*

I know I'm doing something very stupid. This is the
first time I'm using maven too and I just followed the
instructions to compile and build the war.

Any help will be appreciated.
Thanks

   
-
Never miss a thing.   Make Yahoo your homepage.

Re: The type wicket.Component cannot be resolved. It is indirectly referenced The type wicket.Component cannot be resolved. It is indirectly referenced from required .class files

2008-02-04 Thread Igor Vaynberg
datepicker is in wicket-datetime.jar

-igor


On Feb 4, 2008 7:44 PM, Fernando Wermus [EMAIL PROTECTED] wrote:
 Timo,
 Thanks! It is obvious. But I am trying to find the zip file with
 DataPicker for wicket 1.3 and I can't find it.
 I am not mavenized!



 On Feb 5, 2008 1:28 AM, Timo Rantalaiho [EMAIL PROTECTED] wrote:

  On Tue, 05 Feb 2008, Fernando Wermus wrote:
   Some people agree on that the problem is because of dependences and my
   proyect is not 'mavenized'. However, I looked at /lib in the downloaded
  zip
   file and I have all the dependences except wicket 1.2.3 (I am using 1.3
  ).
 
  Are you using some library that is meant for Wicket 1.2? In
  1.2, the base package name is wicket but in 1.3, it's
  org.apache.wicket.
 
  Best wishes,
  Timo
 
  --
  Timo Rantalaiho
  Reaktor Innovations OyURL: http://www.ri.fi/ 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 


 --
 Fernando Wermus.


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



Re: strange DropDownChoice display

2008-02-04 Thread Igor Vaynberg
but it is not just like it was after it has been created is it? it is
currently holding a value from the request. anywho:

secondchoiceSelected=null;
secondchoicedropdownchoice.clearInput();

and you will have what you want.

-igor


On Feb 4, 2008 7:36 PM,  [EMAIL PROTECTED] wrote:
 The following is the code sample

 class webpage
   String secondchoiceSelected;


   }
   new Firstdropdownchoice( ){
  onSelectionChange{
secondchoiceSelected = null;
   }


 I did set to null. This issue is that the displayed value is
 the first item of the new list, instead of Choose One, it is not
 displaying the old secondVarSelected since I already set it to null.
 Basically, when the dropdownchoice is redisplayed and is model is
 null, it is supposed to display the same as the first created. It does
 not appear this way.





 whe the first is submitted you have to set the second one's model object to
 null
 
 -igor
 
 
 On Feb 4, 2008 4:59 PM,  [EMAIL PROTECTED] wrote:
  Hello:
  I am using two dropdownchoices, after the first select, the second would 
  get
 data  on the fly using the first choice. The first round everything is fine
 with both displaying Choose One  and selecting the first one set the 
 correct
 second one list of choice with Choose One still displaying on the second so
 that one could click on it to pick the right one. After the first round, I
 select a different value in the first one, which resets correctly the second
 one' list as in the first round but strangely this time, the 'Choose One
 display is gone in the second dropdownchoice. Instead it shows the first item
 of the new list.  I used the wicket-examples sample code as basis  and use
 getObject() to load the correct list when selection on the first changed.
  Thanks
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 

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



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



Why has my page expired?

2008-02-04 Thread Sri Sankaran

Wicket Version: 1.3

OK, I'll admit to having a tenuous grasp of Wicket -- but I am trying to
learn.  I am having trouble with a pages having a very short half life!  I
have looked at several prior postings on the topic of page expiry but none
seem fit the bill.

I have boiled my application down to two very simple pages:  Page1.html that
has a link to Page2.  


lt;a href=# wicket:id=link_to_page_twoPage Twolt;/a

That's it!

Here are the sequence of steps:

I invoke the app, Page1 is displayed
I click on the link on Page1, Wicket correctly leads me to Page2
I use the browser's back button (I can hear you say aha!) -- Page1 is
displayed
I click on the link (to Page2) -- I get the Page Expired page


I can see that this has something to do with the version of the page that is
being referenced but beyond that I don't have a rational explanation for
what I am seeing.  Can you please explain -- or point me to the appropriate
docs?

Also, what I have described above is a fairly common usage scenario.  How
can I prevent the user from seeing the Page expired page?

FWIW, the link to Page2 has been coded as a PageLink.  For good measure, I
have even tried both PageLink constructor variants.  I see the same behavior
in both cases.

I appreciate any guidance you can provide.

Sri

-- 
View this message in context: 
http://www.nabble.com/Why-has-my-page-expired--tp15283551p15283551.html
Sent from the Wicket - User mailing list archive at Nabble.com.


Re: adding conditional component

2008-02-04 Thread Beyonder Unknown

I see. Thanks Igor! 
 
--
The only constant in life is change.

- Original Message 
From: Igor Vaynberg [EMAIL PROTECTED]
To: users@wicket.apache.org
Sent: Monday, February 4, 2008 5:01:31 PM
Subject: Re: adding conditional component


when 
a 
component 
is 
not 
visible 
its 
markup 
tag 
is 
not 
rendered 
either

-igor


On 
Feb 
4, 
2008 
4:16 
PM, 
Beyonder 
Unknown 
[EMAIL PROTECTED] 
wrote:

 
Thanks 
Janos! 
This 
will 
solve 
the 
problem! 
Although 
it 
has 
extra 
unused 
tag 
in 
the 
markup.

 
Regards,
 
Wen 
Tong

 
--
 
The 
only 
constant 
in 
life 
is 
change.


 
- 
Original 
Message 

 
From: 
Janos 
Cserep 
[EMAIL PROTECTED]
 
To: 
users@wicket.apache.org
 
Sent: 
Monday, 
February 
4, 
2008 
12:40:16 
PM
 
Subject: 
Re: 
adding 
conditional 
component


 

 

 
How
 
do
 
you
 
guys
 
implement
 
a
 
link
 
that
 
is
 
conditional?
 
Like
 
for
 
example
 
the
 

 
link
 
only
 
shows
 
if
 
a
 
given
 
data
 
is
 
provided.
 
Adding
 
the
 
a-tag
 
in
 
the
 

 
Markup
 
will
 
coz
 
an
 
error
 
if
 
the
 
condition
 
is
 
not
 
met,
 
because
 
AjaxLink
 
is
 

 
not
 
added.
 

 

 
I
 
usually
 
handle
 
such
 
a
 
situation
 
by
 
overriding
 
the
 
isVisible()
 
method
 
of
 
the
 
component:

 
add(new
 
Link(link)
 
{

 
@Override
 
public
 
boolean
 
isVisible()
 
{


 
boolean
 
externalCondition
 
=
 
;


 
return
 
super.isVisible()
 

 
externalCondition;
 
}

 
});





  
  
  
 

 
Looking 
for 
last 
minute 
shopping 
deals?
 
Find 
them 
fast 
with 
Yahoo! 
Search.  
http://tools.search.yahoo.com/newsearch/category.php?category=shopping


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



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






  

Looking for last minute shopping deals?  
Find them fast with Yahoo! Search.  
http://tools.search.yahoo.com/newsearch/category.php?category=shopping

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



Re: Why has my page expired?

2008-02-04 Thread Igor Vaynberg
i dont think the page actually expires, i think wicket cant find it anymore.

are the cookies enabled in the browser?

how are you deploying your app?

show us the code to the link.

show us your web.xml

-igor

On Feb 4, 2008 8:53 PM, Sri Sankaran [EMAIL PROTECTED] wrote:

 Wicket Version: 1.3

 OK, I'll admit to having a tenuous grasp of Wicket -- but I am trying to
 learn.  I am having trouble with a pages having a very short half life!  I
 have looked at several prior postings on the topic of page expiry but none
 seem fit the bill.

 I have boiled my application down to two very simple pages:  Page1.html that
 has a link to Page2.


 lt;a href=# wicket:id=link_to_page_twoPage Twolt;/a

 That's it!

 Here are the sequence of steps:

 I invoke the app, Page1 is displayed
 I click on the link on Page1, Wicket correctly leads me to Page2
 I use the browser's back button (I can hear you say aha!) -- Page1 is
 displayed
 I click on the link (to Page2) -- I get the Page Expired page


 I can see that this has something to do with the version of the page that is
 being referenced but beyond that I don't have a rational explanation for
 what I am seeing.  Can you please explain -- or point me to the appropriate
 docs?

 Also, what I have described above is a fairly common usage scenario.  How
 can I prevent the user from seeing the Page expired page?

 FWIW, the link to Page2 has been coded as a PageLink.  For good measure, I
 have even tried both PageLink constructor variants.  I see the same behavior
 in both cases.

 I appreciate any guidance you can provide.

 Sri

 --
 View this message in context: 
 http://www.nabble.com/Why-has-my-page-expired--tp15283551p15283551.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: 2 process cant together in a same time - modal window and form in the same page constructor?

2008-02-04 Thread kenixwong

thanks johan ,

i make a summary here 


 1. report link an ajax link.
   == add a reportAjaxLink  to the parentPage

 ajaxLink = new AjaxLink(cancelReportLink){
public void onClick(AjaxRequestTarget target) {
if (stopThread == null) {
stopThread = new Thread (ReportPage);
stopThread.setName(ReportPageThread);
stopThread.setDaemon( true ); 
stopThread.start();
isLoad = true;
}
setResponsePage(ReportPage.class);
}   
};

2. ajax link gets a thread from a thread pool and let that thread generate
the report 
  == once the link is click, it will start the report page thread and
setResponsePage to the report page

== So, my reportPage will be implements Runnable ( in order put in
thread ) , eg :

  public ReportPage() extends ParentPage implements Runnble{
   add(feedback);

 // add the modal window here ?? how it auto call and pop it
?
// as i know it need the ajaxLink to fire it 
   ModalWindow cancelModal = new ModalWindow(cancelModal);
   CancelPanel  cancelPanel = new
CancelPanel(content,cancelModal);
   add(cancelModal);
  cancelModal.setContent(cancelPanel);
  cancelModal.setPageMapName(cancelModal); 

   add(new ChildPageForm(ChildPageForm));
   }

   private class ChildPageForm extends Form {
 // execute query
 // generate the result as Chart ( JFreeChart tool )
   } 



3. modal dialog you have a cancel button and a ajax timer that checks if the
report is done every x second.
== the ajaxTimer u mean is... i tried as below

  cancelReportModal.add(new
AbstractAjaxTimerBehavior(Duration.seconds(1)) { 
@Override
protected void onTimer(AjaxRequestTarget target) {
// if the report page is still loading   
   if(isLoad){
 cancelReportModal.show(target);
 target.addComponent(cancelReportModal);
   }else{
   cancelReportModal.close(target); 
   stopThread = null;
}
   }
}); 


   == But this part is only  run the else part. Is that i did something
wrong there? 


Btw, i am the newbia to wicket and i was using the wisket 1.2.4. So, hope
can share and do any discusion here 


thanks in advance 
-kenix


Johan Compagner wrote:
 
 this is again a extremly fuzzy examle
 Because the parent page has the link and the modal dialog
 But hte report page extends the parent page so that one also has the link
 and the modal dialog...
 
 So what do you want to show on what page??
 
 If the report page takes a long time then ofcourse you can;t show the
 modal
 dialog on that page
 because the report page isn't there yet..
 
 
 What you should do if you want a modal dialog to happen is
 
 Make the report link an ajax link.
 That ajax link gets a thread from a thread pool and let that thread
 generate
 the report
 Then it displays the modal dialog on the page it is coming from (so just
 the
 parent page with the report link)
 
 On that modal dialog you have a cancel button and a ajax timer that checks
 if the report is done every x seconds.
 
 the cancel button sets a flag on the server so that the report thread
 checks
 as often as he can and when he sees that he just stops with what he is
 doing.
 
 If the ajax timer sees the report beind done it closed the dialog and then
 shows the report page.
 
 johan
 
 
 
 On Feb 4, 2008 3:58 PM, kenixwong [EMAIL PROTECTED] wrote:
 

 hi, johan...

 what i mean is.. based on the example below: -

 a) Parent Page
 ===

 public ParentPage() extends WebPage{


Link reportLink = new Link(link, new Model()){
  @Override
  public void onClick() {
setResponsePage(ReportPage.class);
  }
};

Label label = new Label(linkLabel, text);
reportLink .add(label);
add(reportLink );


ModalWindow cancelModal = new ModalWindow(cancelModal);
CancelPanel  cancelPanel = new CancelPanel(content,cancelModal);
add(cancelModal);
cancelModal.setContent(cancelPanel);
cancelModal.setPageMapName(cancelModal);


 // to auto pop up the modal window.
 ajaxLink = new AjaxLink(cancelModalLink){
@Override
public void onClick(AjaxRequestTarget target) {
cancelModal.show(target);
}
};
 add(ajaxLink);

  //  Fire the ajaxLink onclick function
   

Re: DatePicker Problem

2008-02-04 Thread Igor Vaynberg
you have an old version of wicket.jar, looks like wicket-datetime jar
you are using was compiled against a newer verison of wicket

you could just use maven to manage all these dependencies, that way
you dont run into crap like this. our website will even generate the
maven command line to crate a new skeleton project.

-igor


On Feb 4, 2008 11:04 PM, tsuresh [EMAIL PROTECTED] wrote:

 Hello,

 I tried to run the java dates example(with DatePicker) as provided in the
 examples of wicket 1.3. I am using netbeans .  I just copied the code. When
 I run the program I get the following error.

 javax.servlet.ServletException: Servlet execution threw an exception

 org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:390)

 root cause

 java.lang.NoClassDefFoundError: org/joda/time/ReadableInstant
 np.com.fw.DatesPage.init(DatesPage.java:132)
 .

 When I added the joda-time.jar in lib, i got the error as follows

 Description The server encountered an internal error () that prevented it
 from fulfilling this request.

 exception

 javax.servlet.ServletException: Servlet execution threw an exception

 org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:390)

 root cause

 java.lang.NoSuchMethodError:
 org.apache.wicket.ajax.AjaxRequestTarget.get()Lorg/apache/wicket/ajax/AjaxRequestTarget;

 org.apache.wicket.extensions.yui.calendar.DatePicker.renderHead(DatePicker.java:272)
 org.apache.wicket.Component.renderHead(Component.java:2239)

 org.apache.wicket.markup.html.internal.HtmlHeaderContainer$1.component(HtmlHeaderContainer.java:209)
 
 org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:842)
 
 org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:857)
 
 org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:882)

 org.apache.wicket.markup.html.internal.HtmlHeaderContainer.renderHeaderSections(HtmlHeaderContainer.java:200)

 org.apache.wicket.markup.html.internal.HtmlHeaderContainer.onComponentTagBody(HtmlHeaderContainer.java:134)
 org.apache.wicket.Component.renderComponent(Component.java:2154)
 org.apache.wicket.MarkupContainer.onRender(MarkupContainer.java:1316)
 org.apache.wicket.Component.render(Component.java:1980)
 org.apache.wicket.MarkupContainer.autoAdd(MarkupContainer.java:232)

 org.apache.wicket.markup.resolver.HtmlHeaderResolver.resolve(HtmlHeaderResolver.java:81)
 
 org.apache.wicket.MarkupContainer.renderNext(MarkupContainer.java:1228)
 org.apache.wicket.MarkupContainer.renderAll(MarkupContainer.java:1333)
 org.apache.wicket.Page.onRender(Page.java:1425)
 org.apache.wicket.Component.render(Component.java:1980)
 org.apache.wicket.Page.renderPage(Page.java:927)

 org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.respond(BookmarkablePageRequestTarget.java:225)

 org.apache.wicket.request.AbstractRequestCycleProcessor.respond(AbstractRequestCycleProcessor.java:103)

 org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1038)
 org.apache.wicket.RequestCycle.step(RequestCycle.java:1108)
 org.apache.wicket.RequestCycle.steps(RequestCycle.java:1177)
 org.apache.wicket.RequestCycle.request(RequestCycle.java:500)
 
 org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:257)
 
 org.apache.wicket.protocol.http.WicketServlet.doGet(WicketServlet.java:126)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

 org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:390)

 Am i missing something else? thanks

 --
 View this message in context: 
 http://www.nabble.com/DatePicker-Problem-tp15284457p15284457.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



DatePicker Problem

2008-02-04 Thread tsuresh

Hello,

I tried to run the java dates example(with DatePicker) as provided in the
examples of wicket 1.3. I am using netbeans .  I just copied the code. When
I run the program I get the following error. 

javax.servlet.ServletException: Servlet execution threw an exception

org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:390)

root cause

java.lang.NoClassDefFoundError: org/joda/time/ReadableInstant
np.com.fw.DatesPage.init(DatesPage.java:132)
.

When I added the joda-time.jar in lib, i got the error as follows

Description The server encountered an internal error () that prevented it
from fulfilling this request.

exception

javax.servlet.ServletException: Servlet execution threw an exception

org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:390)

root cause

java.lang.NoSuchMethodError:
org.apache.wicket.ajax.AjaxRequestTarget.get()Lorg/apache/wicket/ajax/AjaxRequestTarget;

org.apache.wicket.extensions.yui.calendar.DatePicker.renderHead(DatePicker.java:272)
org.apache.wicket.Component.renderHead(Component.java:2239)

org.apache.wicket.markup.html.internal.HtmlHeaderContainer$1.component(HtmlHeaderContainer.java:209)

org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:842)

org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:857)

org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:882)

org.apache.wicket.markup.html.internal.HtmlHeaderContainer.renderHeaderSections(HtmlHeaderContainer.java:200)

org.apache.wicket.markup.html.internal.HtmlHeaderContainer.onComponentTagBody(HtmlHeaderContainer.java:134)
org.apache.wicket.Component.renderComponent(Component.java:2154)
org.apache.wicket.MarkupContainer.onRender(MarkupContainer.java:1316)
org.apache.wicket.Component.render(Component.java:1980)
org.apache.wicket.MarkupContainer.autoAdd(MarkupContainer.java:232)

org.apache.wicket.markup.resolver.HtmlHeaderResolver.resolve(HtmlHeaderResolver.java:81)
org.apache.wicket.MarkupContainer.renderNext(MarkupContainer.java:1228)
org.apache.wicket.MarkupContainer.renderAll(MarkupContainer.java:1333)
org.apache.wicket.Page.onRender(Page.java:1425)
org.apache.wicket.Component.render(Component.java:1980)
org.apache.wicket.Page.renderPage(Page.java:927)

org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.respond(BookmarkablePageRequestTarget.java:225)

org.apache.wicket.request.AbstractRequestCycleProcessor.respond(AbstractRequestCycleProcessor.java:103)

org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1038)
org.apache.wicket.RequestCycle.step(RequestCycle.java:1108)
org.apache.wicket.RequestCycle.steps(RequestCycle.java:1177)
org.apache.wicket.RequestCycle.request(RequestCycle.java:500)

org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:257)

org.apache.wicket.protocol.http.WicketServlet.doGet(WicketServlet.java:126)
javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:390)

Am i missing something else? thanks

-- 
View this message in context: 
http://www.nabble.com/DatePicker-Problem-tp15284457p15284457.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: Wicket Phone Book example

2008-02-04 Thread Martijn Dashorst
I think you need to remove servlet-api and jetty-* jars from the
war/web-inf/lib folder
Martijn

On 2/5/08, Omair Aasim [EMAIL PROTECTED] wrote:


 Hello,
 I'm pretty new to wicket and tried out the phonebook
 example by downloading the war file and deployed it on
 tomcat and it worked fine.

 Later i downloaded the source code and without making
 any modifications, compiled it using Maven, created
 the war file and deployed it again. But this new war
 file is throwing the following error:
 *
 exception
 javax.servlet.ServletException: Servlet.init() for
 servlet phonebook threw exception

 root cause
 java.lang.IncompatibleClassChangeError
 *

 I know I'm doing something very stupid. This is the
 first time I'm using maven too and I just followed the
 instructions to compile and build the war.

 Any help will be appreciated.
 Thanks


 -
 Never miss a thing.   Make Yahoo your homepage.




-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


Re: onComponentTag vs AttributeModifier

2008-02-04 Thread Martijn Dashorst
On 2/5/08, Timo Rantalaiho [EMAIL PROTECTED] wrote:

 Some code would be helpful, otherwise we have to get our
 crystal balls out of the closet :)


Tsss... crystal balls in my time we used tea leaves!


Martijn

-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


Re: How to delete an item from List view.

2008-02-04 Thread Nino Saturnino Martinez Vazquez Wael
I've come to love listview, and use it all the time. Would be sad to see 
it go away.. Sure there are somethinges you need to be aware of when 
working with it but thats just life...


-1

Eelco Hillenius wrote:

On Feb 4, 2008 3:45 AM, Martijn Dashorst [EMAIL PROTECTED] wrote:
  

On 2/3/08, Eelco Hillenius [EMAIL PROTECTED] wrote:


How about a reconsideration of depreciating ListView?
  

-1

If anytime someone comes along with a misunderstanding of a valid component
we don't have a framework left:
 - models
 - drop down choice
 - urls
 - mounting

All those things can be deprecated then.



Not true. There are perfectly complete replacements for ListView, not
for the other things you mention.

Eelco

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


  


--
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684


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