Weird feedback message formats

2010-03-25 Thread Sigmar Muuga
Hello,
how to customize error / feedback messages in wicket?
At the moment wicket displays quite stupidly password errors:
mysecret is too short and so on.

I would like to use translated field labels in feedback messages instead of
field names, that are not so user friendly.

Sigmar


Re: Weird feedback message formats

2010-03-25 Thread Martin Makundi
Use same label localization property name as wicket component id:

Application.properties:
mysecret=My password

labelwicket:message key=mysecret//label: input
type=password wicket:id=mysecret/



Ofcourse there are other ways too, but the above is way simplest.

http://cwiki.apache.org/WICKET/localization-and-skinning-of-applications.html

**
Martin

2010/3/25 Sigmar Muuga meedi...@gmail.com:
 Hello,
 how to customize error / feedback messages in wicket?
 At the moment wicket displays quite stupidly password errors:
 mysecret is too short and so on.

 I would like to use translated field labels in feedback messages instead of
 field names, that are not so user friendly.

 Sigmar


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



RE: Wicketstuff updated!

2010-03-25 Thread Stefan Lindner
Hi Boris,

thank you for doing the job. I have tested jWicket again and everything looks 
fine.

Stefan

-Ursprüngliche Nachricht-
Von: Boris Goldowsky [mailto:bgoldow...@cast.org] 
Gesendet: Mittwoch, 24. März 2010 22:14
An: users@wicket.apache.org
Betreff: Wicketstuff updated!

As discussed, and not hearing any objections, I've updated the 
wicketstuff-core project to depend on Wicket 1.4.7.  wicketstuff-core's 
version number is now 1.4.7-SNAPSHOT, and the idea is that people can 
test it, and barring any major problems it can be released as a stable 
version 1.4.7 .

Now, before people can easily test this, the artifacts need to get into 
the wicket snapshots maven repository, right?  Can someone with the 
requisite permissions make this happen?  In the meantime of course 
people are encouraged to download the projects and build and test them 
locally.

In addition to wicket, the following dependencies were also updated to 
the latest stable version within the same major version of the project.  
I did not attempt to move Lucene from version 2.4.1 to 3.0.1, for 
instance, since more significant changes might be required for this (if 
any subproject is actually using it).

  Jetty: 6.1.22
  Lucene: 2.4.1
  slf4j: 1.5.11
  JUnit: 4.8.1

I had to make a couple of changes to get everything to build with the 
new dependencies (commented out wagon-ssh-external extension from 
inmethod-grid; added new required constructor argument to two instances 
of SpringComponentInjector).  People should test the build and make sure 
these changes are ok.  But at least for me, I can do a mvn install at 
the top level and it works.

Bng


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


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



Wicket DatePicker memory leak during ajax rerender?

2010-03-25 Thread Jomar Lorentzen
Hi,

we are using the DatePicker in a panel that is rerendered through ajax at a 
certain interval, and we have noticed
that the DOM reporter in firebug reports that a new function is added each time 
the DatePicker is rerendered. As none
on our team are really into javascript we're wondering if anybody could say if 
this is a potential memory leak?

Each time the DatePicker is rerendered a new random javascript function of the 
type initdateXXX is added to the page. Are these
initXXX references a potential memory leak on the browser, or would they be 
cleaned up by the browser if firebug had not been running?

initdate838 = function() {
Wicket.DateTime.init( ... );
};


if (wicketCalendarInitFinished) {
// when a DatePicker is added via ajax, the loader is already finished, so
// we call the init function directly.
initdate838();
} else {
// when page is rendered, all calendar components will be initialized after
// the required js libraries have been loaded.
wicketCalendarInits.push(initdate838);
}
Save a tree - don't print this e-mail unless necessary!

Statnett SF, Tel. head office +47 22527000, Enterprise No. NO 962 986 633 VAT, 
www.statnett.no, firmap...@statnett.no
_

This e-mail and any attached files are confidential and may be legally 
privileged. If you have received this transmission in error please notify the 
sender by reply e-mail immediately and then delete the e-mail.
E-mail transmission cannot be guaranteed to be secure or error free as 
information could be intercepted, corrupted, lost, destroyed, arrive late or 
incomplete. If verification is required please request a hard copy version. 
This e-mail message has been virus checked by the antivirus programs used by 
Statnett SF.
_


Re: RE: RE: RE: Regarding TreeTable Horizontal Scrollbar

2010-03-25 Thread Leo . Erlandsson
Hi,

Still a CSS issue, not a Wicket one ;)

I used Google to search for css table locked column scroll

First result was a good StackOverflow-question:
http://stackoverflow.com/questions/296020/how-can-i-lock-the-first-row-and-first-column-of-a-table-when-scrolling-possibly

Try the Horizontal Scrollbar in the example mentioned in the Accepted 
StackOverflow answer:
http://www.cubido.at/Portals/7/docs/Blog/Karin/HTML%20and%20Javascript/ResizeColumns/Table.htm

Source here: 
http://www.cubido.at/Portals/7/docs/Blog/Karin/HTML%20and%20Javascript/ResizeColumns.zip


Seems to be what you're looking for. 



Thanks to have your valuable reply  effort you made to answer my query. 
But let me to explain you again my problem statement because this solution 
won't help me to fix the issue I have. I need a CSS style at TreeTable 
markup level so that the Horizontal Scrollbar would be a part of TreeTable 
component. Here is my problem statement:

In my application, there are two scenarios: 

1) I need an entire table to be scrollable horizontally 
2) Horizontal scrolling on entire table except the tree node column.

Now I tried with changing both TreeTable markup  CSS attribute but 
couldn't get success. I am using wicket 1.4.5 version.

Actually the problem statement is, in my application, I need a TreeTable 
where first column should contain the data in a tree structure  rest 
others column will be the simple one. So, I used TreeTable 
wicket-extension component to get the requirement fulfill but the problem 
arises when table has many number of columns then the table should be 
horizontally scrollable. And as per my analysis, this existing treetable 
component doesn't provide this feature.

Could you please let me know that whether it's possible to customize 
component for above mentioned requirement? And if yes, then guide me to do 
this otherwise please let me know what would be the other approach.



Re: Weird feedback message formats

2010-03-25 Thread Xavier López
Hi  Sigmar,

I went fine just setting the component's Label with setLabel().
This method sets a Model which will be used instead of the wicket:id in the
built-in validator's error messages.

Cheers,
Xavier

2010/3/25 Sigmar Muuga meedi...@gmail.com

 Hello,
 how to customize error / feedback messages in wicket?
 At the moment wicket displays quite stupidly password errors:
 mysecret is too short and so on.

 I would like to use translated field labels in feedback messages instead of
 field names, that are not so user friendly.

 Sigmar




-- 
Klein bottle for rent--inquire within.


Wicket Models Class Diagram

2010-03-25 Thread corneliu.petrescu
Hi guys,
 I've made a diagram relating to the wicket models.
 Can you tell me what you think about it, and what extra information it
should contain?
 I'm also thinking of creating a sequence diagram regarding the
lifecycle of a wicket application.


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

Re: Wicket Models Class Diagram

2010-03-25 Thread corneliu.petrescu
It seems attachements are ignored... :(
On Thu, 2010-03-25 at 10:51 +0200, corneliu.petrescu wrote:
 Hi guys,
  I've made a diagram relating to the wicket models.
  Can you tell me what you think about it, and what extra information it
 should contain?
  I'm also thinking of creating a sequence diagram regarding the
 lifecycle of a wicket application.
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org



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



Re: Wicket Models Class Diagram

2010-03-25 Thread corneliu.petrescu
Hi,
I've uploaded the diagram to a free file-sharing website.
You can download it from here:
 http://www.fileshare.ro/3936630672.98

On Thu, 2010-03-25 at 11:07 +0200, corneliu.petrescu wrote:
 It seems attachements are ignored... :(
 On Thu, 2010-03-25 at 10:51 +0200, corneliu.petrescu wrote:
  Hi guys,
   I've made a diagram relating to the wicket models.
   Can you tell me what you think about it, and what extra information it
  should contain?
   I'm also thinking of creating a sequence diagram regarding the
  lifecycle of a wicket application.
  
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 



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



Results of AutoCompleteTextField shown behind other form components

2010-03-25 Thread Andreas Maza

Hello,

I am experiencing a strange problem with the AutoCompleteTextField 
(Wicket 1.4.7): The results of the AutoCompleteTextField are shown 
behind my other form components are not selectable, too.
I am extending the DefaultCssAutoCompleteTextField and do not define any 
custom CSS for the textfield. Has anyone experienced a similar problem 
or can provide any hint?


Thanks in advance,
andr

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



signout and redirect

2010-03-25 Thread tubin gen
here is my code to signout link.

add(new LinkVoid(signout){
@Override
public void onClick() {
((AuditWebSession)(Session.get())).signout();
throw new RestartResponseException(SSISignOutPage.class);
}
});

when user clicks on signout I expect to go to SSISignOutPage.
but I end up with a  different page which is set in applicationsettings

IApplicationSettings settings= super.getApplicationSettings();
settings.setPageExpiredErrorPage(SessionExpiredPage.class);


the  SessionExpiredPage .
please tell me what could be causing this ?


Re: Results of AutoCompleteTextField shown behind other form components

2010-03-25 Thread Erik van Oosten

Don't use relative positioned divs.

There is no golden solution, but here is an attempt anyway: 
https://issues.apache.org/jira/browse/WICKET-1355


Regards,
   Erik.


Andreas Maza wrote:

Hello,

I am experiencing a strange problem with the AutoCompleteTextField 
(Wicket 1.4.7): The results of the AutoCompleteTextField are shown 
behind my other form components are not selectable, too.
I am extending the DefaultCssAutoCompleteTextField and do not define 
any custom CSS for the textfield. Has anyone experienced a similar 
problem or can provide any hint?


Thanks in advance,
andr



--
Sent from my SMTP compliant software
Erik van Oosten
http://day-to-day-stuff.blogspot.com/



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



Re: Results of AutoCompleteTextField shown behind other form components

2010-03-25 Thread Andreas Maza
thanks erik for that hint. I just got it working properly... it was 
simply a problem with my other divs z-index.


regards,
andr


On 25.03.2010 13:18, Erik van Oosten wrote:

Don't use relative positioned divs.

There is no golden solution, but here is an attempt anyway: 
https://issues.apache.org/jira/browse/WICKET-1355


Regards,
   Erik.


Andreas Maza wrote:

Hello,

I am experiencing a strange problem with the AutoCompleteTextField 
(Wicket 1.4.7): The results of the AutoCompleteTextField are shown 
behind my other form components are not selectable, too.
I am extending the DefaultCssAutoCompleteTextField and do not define 
any custom CSS for the textfield. Has anyone experienced a similar 
problem or can provide any hint?


Thanks in advance,
andr






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



Support for back button and new windows?

2010-03-25 Thread Sergey Olefir
Hi,

I'm looking for a good source of information on Wicket's support for
browser's back button and also on what happens when user opens a new
tab/window. I feel this is something I need to understand well before
we can deploy our first Wicket application in production.

I found this:
http://cwiki.apache.org/WICKET/browser-back-forward.html
But this is rather old page, so I'm not sure it's still accurate.
Furthermore after reading that page I'm still unsure what it all
implies.

For example, regarding 'back button' support, after a little
experimentation it seems as if Wicket serializes/stores each page it
generates -- including all the data involved. E.g. if I have
multi-page wizard that stores all data in a single object, and if I
fill pages 1  2 (and I'm currently at page 3), but then use browser's
'back' button to go to page 1 and submit that -- I'll get empty page 2
-- with all the data I've entered previously 'forgotten'. That seems
to strongly imply data serialization.

So what actually happens when browser's back button is used?


And similarly -- what happens when user opens new tab/window in the
middle of the wizard? Does user then get two completely separate
wizard forms that can be changed/submitted separately? Or something
else?


Thanks in advance!

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



Re: Feedback and field validation

2010-03-25 Thread Anna Simbirtsev
Thanks for your response. How do I get the components to hold the error
messages? As I understand the messages get marked rendered once they are
displayed.

On Wed, Mar 24, 2010 at 6:39 PM, alexander.elsholz 
alexander.elsh...@widas.de wrote:


 hi anna,

 feedback-messages will clear after the request processing.  build a visitor
 that checks the
 feedbackmassges of every component. your components have to hold the
 messages when error, info and warn will called. clear on successful
 validate.

 alex


 Anna Simbirtsev wrote:
 
  Hi,
 
  I validate fields using AjaxFormComponentUpdatingBehavior(onblur). When
  I
  am on field 1, and data is invalid, it displays feedback message, and I
  can
  see this message in session. When I move to a different field, this
  feedback
  message is no longer in the session. Can somebody explain that?
 
  Thanks,
  Anna
 
 

 --
 View this message in context:
 http://old.nabble.com/Feedback-and-field-validation-tp27924233p28022371.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




-- 
Anna Simbirtsev
(416) 729-7331


AW: signout and redirect

2010-03-25 Thread Giambalvo, Christian
Depends on what your SSISignOutPage.class does.
But why don't use setResponsePage(SSISignOutPage.class) ??

-Ursprüngliche Nachricht-
Von: tubin gen [mailto:fachh...@gmail.com] 
Gesendet: Donnerstag, 25. März 2010 12:59
An: users
Betreff: signout and redirect

here is my code to signout link.

add(new LinkVoid(signout){
@Override
public void onClick() {
((AuditWebSession)(Session.get())).signout();
throw new RestartResponseException(SSISignOutPage.class);
}
});

when user clicks on signout I expect to go to SSISignOutPage.
but I end up with a  different page which is set in applicationsettings

IApplicationSettings settings= super.getApplicationSettings();
settings.setPageExpiredErrorPage(SessionExpiredPage.class);


the  SessionExpiredPage .
please tell me what could be causing this ?

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



Re: Feedback and field validation

2010-03-25 Thread alexander.elsholz

subclass your components and override error, warn and info.

override validate and clear the message-list.

that was our solution - any better ideas?

alex



Anna Simbirtsev wrote:
 
 Thanks for your response. How do I get the components to hold the error
 messages? As I understand the messages get marked rendered once they are
 displayed.
 
 On Wed, Mar 24, 2010 at 6:39 PM, alexander.elsholz 
 alexander.elsh...@widas.de wrote:
 

 hi anna,

 feedback-messages will clear after the request processing.  build a
 visitor
 that checks the
 feedbackmassges of every component. your components have to hold the
 messages when error, info and warn will called. clear on successful
 validate.

 alex


 Anna Simbirtsev wrote:
 
  Hi,
 
  I validate fields using AjaxFormComponentUpdatingBehavior(onblur).
 When
  I
  am on field 1, and data is invalid, it displays feedback message, and I
  can
  see this message in session. When I move to a different field, this
  feedback
  message is no longer in the session. Can somebody explain that?
 
  Thanks,
  Anna
 
 

 --
 View this message in context:
 http://old.nabble.com/Feedback-and-field-validation-tp27924233p28022371.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


 
 
 -- 
 Anna Simbirtsev
 (416) 729-7331
 
 

-- 
View this message in context: 
http://old.nabble.com/Feedback-and-field-validation-tp27924233p28028928.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: AW: signout and redirect

2010-03-25 Thread fachhoch

I initially tried   etResponsePage(SSISignOutPage.class)  it did not worked ,
so used the new approach , 

regarding what my  SSISignOutPage it does nothing except for showing a link
,  before to that the control never goes to the page constructor ,  

I am assuming after a session is invalidated wicket removes all  its pages
from page map and  its possible that it cannot find the page SSISignOutPage  
and for that reason do I get pageExpired error ?




christian.giambalvo wrote:
 
 Depends on what your SSISignOutPage.class does.
 But why don't use setResponsePage(SSISignOutPage.class) ??
 
 -Ursprüngliche Nachricht-
 Von: tubin gen [mailto:fachh...@gmail.com] 
 Gesendet: Donnerstag, 25. März 2010 12:59
 An: users
 Betreff: signout and redirect
 
 here is my code to signout link.
 
 add(new LinkVoid(signout){
 @Override
 public void onClick() {
 ((AuditWebSession)(Session.get())).signout();
 throw new RestartResponseException(SSISignOutPage.class);
 }
 });
 
 when user clicks on signout I expect to go to SSISignOutPage.
 but I end up with a  different page which is set in applicationsettings
 
 IApplicationSettings settings= super.getApplicationSettings();
 settings.setPageExpiredErrorPage(SessionExpiredPage.class);
 
 
 the  SessionExpiredPage .
 please tell me what could be causing this ?
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

-- 
View this message in context: 
http://old.nabble.com/signout-and-redirect-tp28027857p28029507.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



AW: AW: signout and redirect

2010-03-25 Thread Giambalvo, Christian
setResponsePage(SSISignOutPage.class) creates a new page that will go into 
pagemap.
Is your Page class in a protected area?

-Ursprüngliche Nachricht-
Von: fachhoch [mailto:fachh...@gmail.com] 
Gesendet: Donnerstag, 25. März 2010 15:19
An: users@wicket.apache.org
Betreff: Re: AW: signout and redirect


I initially tried   etResponsePage(SSISignOutPage.class)  it did not worked ,
so used the new approach , 

regarding what my  SSISignOutPage it does nothing except for showing a link
,  before to that the control never goes to the page constructor ,  

I am assuming after a session is invalidated wicket removes all  its pages
from page map and  its possible that it cannot find the page SSISignOutPage  
and for that reason do I get pageExpired error ?




christian.giambalvo wrote:
 
 Depends on what your SSISignOutPage.class does.
 But why don't use setResponsePage(SSISignOutPage.class) ??
 
 -Ursprüngliche Nachricht-
 Von: tubin gen [mailto:fachh...@gmail.com] 
 Gesendet: Donnerstag, 25. März 2010 12:59
 An: users
 Betreff: signout and redirect
 
 here is my code to signout link.
 
 add(new LinkVoid(signout){
 @Override
 public void onClick() {
 ((AuditWebSession)(Session.get())).signout();
 throw new RestartResponseException(SSISignOutPage.class);
 }
 });
 
 when user clicks on signout I expect to go to SSISignOutPage.
 but I end up with a  different page which is set in applicationsettings
 
 IApplicationSettings settings= super.getApplicationSettings();
 settings.setPageExpiredErrorPage(SessionExpiredPage.class);
 
 
 the  SessionExpiredPage .
 please tell me what could be causing this ?
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

-- 
View this message in context: 
http://old.nabble.com/signout-and-redirect-tp28027857p28029507.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: AW: signout and redirect

2010-03-25 Thread Mauro Ciancio
  In order to implement my sign out page I've created a SignOutPage
that invokes the signOut method in AuthenticatedWebSession, then
setRedirect(true) and as final step I throw a:

throw new RestartResponseException(HomePage.class).

  This makes the home page be processed (and the url in the navigation
bar remains /your_home_page_url).

Here is the full code if you need it:

public class LogOutPage extends WebPage {

public LogOutPage() {
AuthenticatedWebSession.get().signOut();
setRedirect(true);
throw new RestartResponseException(HomePage.class);
}
}

Cheers.

On Thu, Mar 25, 2010 at 11:19 AM, fachhoch fachh...@gmail.com wrote:

 I initially tried   etResponsePage(SSISignOutPage.class)  it did not worked ,
 so used the new approach ,

 regarding what my  SSISignOutPage it does nothing except for showing a link
 ,  before to that the control never goes to the page constructor ,

 I am assuming after a session is invalidated wicket removes all  its pages
 from page map and  its possible that it cannot find the page SSISignOutPage
 and for that reason do I get pageExpired error ?




 christian.giambalvo wrote:

 Depends on what your SSISignOutPage.class does.
 But why don't use setResponsePage(SSISignOutPage.class) ??

 -Ursprüngliche Nachricht-
 Von: tubin gen [mailto:fachh...@gmail.com]
 Gesendet: Donnerstag, 25. März 2010 12:59
 An: users
 Betreff: signout and redirect

 here is my code to signout link.

 add(new LinkVoid(signout){
 @Override
 public void onClick() {
 ((AuditWebSession)(Session.get())).signout();
 throw new RestartResponseException(SSISignOutPage.class);
 }
 });

 when user clicks on signout I expect to go to SSISignOutPage.
 but I end up with a  different page which is set in applicationsettings

 IApplicationSettings settings= super.getApplicationSettings();
 settings.setPageExpiredErrorPage(SessionExpiredPage.class);


 the  SessionExpiredPage .
 please tell me what could be causing this ?

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




 --
 View this message in context: 
 http://old.nabble.com/signout-and-redirect-tp28027857p28029507.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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





-- 
Mauro Ciancio maurociancio at gmail dot com

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



Re: AW: AW: signout and redirect

2010-03-25 Thread fachhoch

no it is not.

christian.giambalvo wrote:
 
 setResponsePage(SSISignOutPage.class) creates a new page that will go into
 pagemap.
 Is your Page class in a protected area?
 
 -Ursprüngliche Nachricht-
 Von: fachhoch [mailto:fachh...@gmail.com] 
 Gesendet: Donnerstag, 25. März 2010 15:19
 An: users@wicket.apache.org
 Betreff: Re: AW: signout and redirect
 
 
 I initially tried   etResponsePage(SSISignOutPage.class)  it did not
 worked ,
 so used the new approach , 
 
 regarding what my  SSISignOutPage it does nothing except for showing a
 link
 ,  before to that the control never goes to the page constructor ,  
 
 I am assuming after a session is invalidated wicket removes all  its pages
 from page map and  its possible that it cannot find the page
 SSISignOutPage  
 and for that reason do I get pageExpired error ?
 
 
 
 
 christian.giambalvo wrote:
 
 Depends on what your SSISignOutPage.class does.
 But why don't use setResponsePage(SSISignOutPage.class) ??
 
 -Ursprüngliche Nachricht-
 Von: tubin gen [mailto:fachh...@gmail.com] 
 Gesendet: Donnerstag, 25. März 2010 12:59
 An: users
 Betreff: signout and redirect
 
 here is my code to signout link.
 
 add(new LinkVoid(signout){
 @Override
 public void onClick() {
 ((AuditWebSession)(Session.get())).signout();
 throw new RestartResponseException(SSISignOutPage.class);
 }
 });
 
 when user clicks on signout I expect to go to SSISignOutPage.
 but I end up with a  different page which is set in applicationsettings
 
 IApplicationSettings settings= super.getApplicationSettings();
 settings.setPageExpiredErrorPage(SessionExpiredPage.class);
 
 
 the  SessionExpiredPage .
 please tell me what could be causing this ?
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 
 
 -- 
 View this message in context:
 http://old.nabble.com/signout-and-redirect-tp28027857p28029507.html
 Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

-- 
View this message in context: 
http://old.nabble.com/signout-and-redirect-tp28027857p28030108.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Label update after change of radiochoice by ajax not working

2010-03-25 Thread Per Newgro
Hi *,

i have a courious situation here. My TestHomePanel is running green, but in 
browser the label is not updated. If i remove the css-class from the choices it 
works as expected. It seems that the lookup of the radios in the group is not 
working. But i don't find the place in code to check.

Is someone seeing the cause or knows where the radios in the group will be 
handled?

Cheers
Per

HomePanel.java
import org.apache.wicket.ajax.AjaxRequestTarget;
import org.apache.wicket.ajax.form.AjaxFormChoiceComponentUpdatingBehavior;
import org.apache.wicket.markup.html.basic.Label;
import org.apache.wicket.markup.html.form.Form;
import org.apache.wicket.markup.html.form.Radio;
import org.apache.wicket.markup.html.form.RadioGroup;
import org.apache.wicket.markup.html.panel.Panel;
import org.apache.wicket.model.IModel;
import org.apache.wicket.model.Model;

public class HomePanel extends Panel {

  public HomePanel(String id) {
super(id);

FormVoid f = new FormVoid(form);
add(f);

IModelByte groupModel = new ModelByte(Byte.valueOf(1));

final RadioGroupByte g = new RadioGroupByte(rgroup, groupModel);
f.add(g);
g.add(new AjaxFormChoiceComponentUpdatingBehavior() {
  @Override
  protected void onUpdate(AjaxRequestTarget target) {
target.addComponent(HomePanel.this);
  }
});
g.add(new RadioByte(r1, new ModelByte(Byte.valueOf(1;
g.add(new RadioByte(r2, new ModelByte(Byte.valueOf(2;

Label l = new Label(result, groupModel);
f.add(l);
  }
}

HomePanel.html
html xmlns:wicket
wicket:panel
form wicket:id=form
  span wicket:id=result[Text]/span
  span wicket:id=rgroup
input type=radio wicket:id=r1 class=abc
input type=radio wicket:id=r2 class=abc
  /span
/form
/wicket:panel
/html

TestHomePanel.java
import junit.framework.TestCase;

import org.apache.wicket.util.tester.FormTester;
import org.apache.wicket.util.tester.WicketTester;

/**
 * Simple test using the WicketTester
 */
public class TestHomePanel extends TestCase
{
  private WicketTester tester;

  @Override
  public void setUp()
  {
tester = new WicketTester(new WicketApplication());
  }

  public void testWorks() {
tester.startPanel(HomePanel.class);
assertChangedLabelOnClick();
  }

  private void assertChangedLabelOnClick() {
tester.assertLabel(panel:form:result, 1);
FormTester f = tester.newFormTester(panel:form);
f.select(rgroup, 1);
f.submit();
tester.assertLabel(panel:form:result, 2);
  }
}
-- 
Sicherer, schneller und einfacher. Die aktuellen Internet-Browser -
jetzt kostenlos herunterladen! http://portal.gmx.net/de/go/chbrowser

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



Re: AW: signout and redirect

2010-03-25 Thread fachhoch

I did as u said 
public class AuditSignOutPage extends SignOutPage
{

public AuditSignOutPage() {
((AuditWebSession)(Session.get())).signout();
setRedirect(true);
throw new RestartResponseException(SSISignOutPage.class);
}
}


public class SSISignOutPage extends UnSecuredBasePage {

public SSISignOutPage() {
add(new AjaxLinkVoid(relogin){
@Override
public void onClick(AjaxRequestTarget target) {
setResponsePage(new
AuditWicketApplication.SignInPageHelper().getSignInPage());
setRedirect(true);
}
});
}
}
I click on the signout link   AuditSignOutPage   invalidates  the session
and send to   SSISignOutPage   .here this page gets loaded , I see the link
relogin.

when  I click on the link relogin it should take me to my signinpage but
again i am ending up with session expired page .  I  set the break point  
in onClick method   but it never goes there , 

please explain me what could be causing this ? 



Mauro Ciancio wrote:
 
   In order to implement my sign out page I've created a SignOutPage
 that invokes the signOut method in AuthenticatedWebSession, then
 setRedirect(true) and as final step I throw a:
 
 throw new RestartResponseException(HomePage.class).
 
   This makes the home page be processed (and the url in the navigation
 bar remains /your_home_page_url).
 
 Here is the full code if you need it:
 
 public class LogOutPage extends WebPage {
 
 public LogOutPage() {
 AuthenticatedWebSession.get().signOut();
 setRedirect(true);
 throw new RestartResponseException(HomePage.class);
 }
 }
 
 Cheers.
 
 On Thu, Mar 25, 2010 at 11:19 AM, fachhoch fachh...@gmail.com wrote:

 I initially tried   etResponsePage(SSISignOutPage.class)  it did not
 worked ,
 so used the new approach ,

 regarding what my  SSISignOutPage it does nothing except for showing a
 link
 ,  before to that the control never goes to the page constructor ,

 I am assuming after a session is invalidated wicket removes all  its
 pages
 from page map and  its possible that it cannot find the page
 SSISignOutPage
 and for that reason do I get pageExpired error ?




 christian.giambalvo wrote:

 Depends on what your SSISignOutPage.class does.
 But why don't use setResponsePage(SSISignOutPage.class) ??

 -Ursprüngliche Nachricht-
 Von: tubin gen [mailto:fachh...@gmail.com]
 Gesendet: Donnerstag, 25. März 2010 12:59
 An: users
 Betreff: signout and redirect

 here is my code to signout link.

 add(new LinkVoid(signout){
 @Override
 public void onClick() {
 ((AuditWebSession)(Session.get())).signout();
 throw new RestartResponseException(SSISignOutPage.class);
 }
 });

 when user clicks on signout I expect to go to SSISignOutPage.
 but I end up with a  different page which is set in applicationsettings

 IApplicationSettings settings= super.getApplicationSettings();
 settings.setPageExpiredErrorPage(SessionExpiredPage.class);


 the  SessionExpiredPage .
 please tell me what could be causing this ?

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




 --
 View this message in context:
 http://old.nabble.com/signout-and-redirect-tp28027857p28029507.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


 
 
 
 -- 
 Mauro Ciancio maurociancio at gmail dot com
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

-- 
View this message in context: 
http://old.nabble.com/signout-and-redirect-tp28027857p28030542.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: AW: signout and redirect

2010-03-25 Thread James Carman
This works for me:

final Link signOutLink = new Link(signOutLink)
{
public void onClick()
{
getSession().invalidate();
setResponsePage(getApplication().getHomePage());
setRedirect(true);
}

public boolean isVisible()
{
return ((MySessionClass)getSession()).isSignedIn();
}
};

I put that in my base page class so that it's visible everywhere.

On Thu, Mar 25, 2010 at 11:30 AM, fachhoch fachh...@gmail.com wrote:

 I did as u said
 public class AuditSignOutPage extends SignOutPage
 {

        public AuditSignOutPage() {
                ((AuditWebSession)(Session.get())).signout();
                setRedirect(true);
                throw new RestartResponseException(SSISignOutPage.class);
        }
 }


 public class SSISignOutPage extends UnSecuredBasePage {

        public SSISignOutPage() {
                add(new AjaxLinkVoid(relogin){
                       �...@override
                        public void onClick(AjaxRequestTarget target) {
                                setResponsePage(new
 AuditWicketApplication.SignInPageHelper().getSignInPage());
                                setRedirect(true);
                        }
                });
        }
 }
 I click on the signout link   AuditSignOutPage   invalidates  the session
 and send to   SSISignOutPage   .here this page gets loaded , I see the link
 relogin.

 when  I click on the link relogin it should take me to my signinpage but
 again i am ending up with session expired page .  I  set the break point
 in onClick method   but it never goes there ,

 please explain me what could be causing this ?



 Mauro Ciancio wrote:

   In order to implement my sign out page I've created a SignOutPage
 that invokes the signOut method in AuthenticatedWebSession, then
 setRedirect(true) and as final step I throw a:

 throw new RestartResponseException(HomePage.class).

   This makes the home page be processed (and the url in the navigation
 bar remains /your_home_page_url).

 Here is the full code if you need it:

 public class LogOutPage extends WebPage {

     public LogOutPage() {
         AuthenticatedWebSession.get().signOut();
         setRedirect(true);
         throw new RestartResponseException(HomePage.class);
     }
 }

 Cheers.

 On Thu, Mar 25, 2010 at 11:19 AM, fachhoch fachh...@gmail.com wrote:

 I initially tried   etResponsePage(SSISignOutPage.class)  it did not
 worked ,
 so used the new approach ,

 regarding what my  SSISignOutPage it does nothing except for showing a
 link
 ,  before to that the control never goes to the page constructor ,

 I am assuming after a session is invalidated wicket removes all  its
 pages
 from page map and  its possible that it cannot find the page
 SSISignOutPage
 and for that reason do I get pageExpired error ?




 christian.giambalvo wrote:

 Depends on what your SSISignOutPage.class does.
 But why don't use setResponsePage(SSISignOutPage.class) ??

 -Ursprüngliche Nachricht-
 Von: tubin gen [mailto:fachh...@gmail.com]
 Gesendet: Donnerstag, 25. März 2010 12:59
 An: users
 Betreff: signout and redirect

 here is my code to signout link.

 add(new LinkVoid(signout){
 @Override
 public void onClick() {
 ((AuditWebSession)(Session.get())).signout();
 throw new RestartResponseException(SSISignOutPage.class);
 }
 });

 when user clicks on signout I expect to go to SSISignOutPage.
 but I end up with a  different page which is set in applicationsettings

 IApplicationSettings settings= super.getApplicationSettings();
 settings.setPageExpiredErrorPage(SessionExpiredPage.class);


 the  SessionExpiredPage .
 please tell me what could be causing this ?

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




 --
 View this message in context:
 http://old.nabble.com/signout-and-redirect-tp28027857p28029507.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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





 --
 Mauro Ciancio maurociancio at gmail dot com

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




 --
 View this message in context: 
 http://old.nabble.com/signout-and-redirect-tp28027857p28030542.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




[wicket-stuff] project sitemap-xml

2010-03-25 Thread Fernando Wermus
Hi all,
I need to develop sitemap for my web app. I see that there is a project
related to this problem. Which is its situation? Does anyone know?

thanks in advance

-- 
Fernando Wermus.

www.linkedin.com/in/fernandowermus


Re: AW: signout and redirect

2010-03-25 Thread fachhoch

does encryption has anything to do with this   upon debugging I found its
failing  in CryptedUrlWebRequestCodingStrategy.java

here is the method where it fails

protected String decodeURL(final String url)
{
int startIndex = url.indexOf(?x=);
if (startIndex == -1)
{
startIndex = url.indexOf(x=);
}

if (startIndex != -1)
{
try
{
startIndex = startIndex + 3;
final int endIndex = url.indexOf(, 
startIndex);
String secureParam;
if (endIndex == -1)
{
secureParam = url.substring(startIndex);
}
else
{
secureParam = url.substring(startIndex, 
endIndex);
}

secureParam = 
WicketURLDecoder.QUERY_INSTANCE.decode(secureParam);

// Get the crypt implementation from the 
application
final ICrypt urlCrypt = Application.get()
.getSecuritySettings()
.getCryptFactory()
.newCrypt();

// Decrypt the query string
String queryString = 
urlCrypt.decryptUrlSafe(secureParam);

// The querystring might have been shortened 
(length reduced).
// In that case, lengthen the query string 
again.
queryString = rebuildUrl(queryString);
return queryString;
}
catch (Exception ex)
{
return onError(ex, url);
}
}
return null;
}
it fails at this line 
String queryString = urlCrypt.decryptUrlSafe(secureParam);

why decrypt fails  if session is  invalidated ?

James Carman-3 wrote:
 
 This works for me:
 
 final Link signOutLink = new Link(signOutLink)
 {
 public void onClick()
 {
 getSession().invalidate();
 setResponsePage(getApplication().getHomePage());
 setRedirect(true);
 }
 
 public boolean isVisible()
 {
 return ((MySessionClass)getSession()).isSignedIn();
 }
 };
 
 I put that in my base page class so that it's visible everywhere.
 
 On Thu, Mar 25, 2010 at 11:30 AM, fachhoch fachh...@gmail.com wrote:

 I did as u said
 public class AuditSignOutPage extends SignOutPage
 {

        public AuditSignOutPage() {
                ((AuditWebSession)(Session.get())).signout();
                setRedirect(true);
                throw new RestartResponseException(SSISignOutPage.class);
        }
 }


 public class SSISignOutPage extends UnSecuredBasePage {

        public SSISignOutPage() {
                add(new AjaxLinkVoid(relogin){
                       �...@override
                        public void onClick(AjaxRequestTarget target) {
                                setResponsePage(new
 AuditWicketApplication.SignInPageHelper().getSignInPage());
                                setRedirect(true);
                        }
                });
        }
 }
 I click on the signout link   AuditSignOutPage   invalidates  the session
 and send to   SSISignOutPage   .here this page gets loaded , I see the
 link
 relogin.

 when  I click on the link relogin it should take me to my signinpage but
 again i am ending up with session expired page .  I  set the break point
 in onClick method   but it never goes there ,

 please explain me what could be causing this ?



 Mauro Ciancio wrote:

   In order to implement my sign out page I've created a SignOutPage
 that invokes the signOut method in AuthenticatedWebSession, then
 setRedirect(true) and as final step I throw a:

 throw new RestartResponseException(HomePage.class).

   This makes the home page be processed (and the url in the navigation
 bar remains /your_home_page_url).

 Here is the full code if you need it:

 public class LogOutPage extends WebPage {

     public LogOutPage() {
         AuthenticatedWebSession.get().signOut();
         setRedirect(true);
         throw new RestartResponseException(HomePage.class);
     }
 }

 Cheers.

 On Thu, Mar 25, 2010 at 11:19 AM, fachhoch fachh...@gmail.com wrote:

 I initially tried   etResponsePage(SSISignOutPage.class)  it did not
 worked ,
 so used the new approach ,

 regarding what my  

Re: AW: signout and redirect

2010-03-25 Thread James Carman
By default, Wicket uses the KeyInSessionSunJceCryptFactory which
stores the encryption key in the user's session.

On Thu, Mar 25, 2010 at 11:50 AM, fachhoch fachh...@gmail.com wrote:

 does encryption has anything to do with this   upon debugging I found its
 failing  in CryptedUrlWebRequestCodingStrategy.java

 here is the method where it fails

        protected String decodeURL(final String url)
        {
                int startIndex = url.indexOf(?x=);
                if (startIndex == -1)
                {
                        startIndex = url.indexOf(x=);
                }

                if (startIndex != -1)
                {
                        try
                        {
                                startIndex = startIndex + 3;
                                final int endIndex = url.indexOf(, 
 startIndex);
                                String secureParam;
                                if (endIndex == -1)
                                {
                                        secureParam = 
 url.substring(startIndex);
                                }
                                else
                                {
                                        secureParam = 
 url.substring(startIndex, endIndex);
                                }

                                secureParam = 
 WicketURLDecoder.QUERY_INSTANCE.decode(secureParam);

                                // Get the crypt implementation from the 
 application
                                final ICrypt urlCrypt = Application.get()
                                        .getSecuritySettings()
                                        .getCryptFactory()
                                        .newCrypt();

                                // Decrypt the query string
                                String queryString = 
 urlCrypt.decryptUrlSafe(secureParam);

                                // The querystring might have been shortened 
 (length reduced).
                                // In that case, lengthen the query string 
 again.
                                queryString = rebuildUrl(queryString);
                                return queryString;
                        }
                        catch (Exception ex)
                        {
                                return onError(ex, url);
                        }
                }
                return null;
        }
 it fails at this line
 String queryString = urlCrypt.decryptUrlSafe(secureParam);

 why decrypt fails  if session is  invalidated ?

 James Carman-3 wrote:

 This works for me:

 final Link signOutLink = new Link(signOutLink)
         {
             public void onClick()
             {
                 getSession().invalidate();
                 setResponsePage(getApplication().getHomePage());
                 setRedirect(true);
             }

             public boolean isVisible()
             {
                 return ((MySessionClass)getSession()).isSignedIn();
             }
         };

 I put that in my base page class so that it's visible everywhere.

 On Thu, Mar 25, 2010 at 11:30 AM, fachhoch fachh...@gmail.com wrote:

 I did as u said
 public class AuditSignOutPage extends SignOutPage
 {

        public AuditSignOutPage() {
                ((AuditWebSession)(Session.get())).signout();
                setRedirect(true);
                throw new RestartResponseException(SSISignOutPage.class);
        }
 }


 public class SSISignOutPage extends UnSecuredBasePage {

        public SSISignOutPage() {
                add(new AjaxLinkVoid(relogin){
                       �...@override
                        public void onClick(AjaxRequestTarget target) {
                                setResponsePage(new
 AuditWicketApplication.SignInPageHelper().getSignInPage());
                                setRedirect(true);
                        }
                });
        }
 }
 I click on the signout link   AuditSignOutPage   invalidates  the session
 and send to   SSISignOutPage   .here this page gets loaded , I see the
 link
 relogin.

 when  I click on the link relogin it should take me to my signinpage but
 again i am ending up with session expired page .  I  set the break point
 in onClick method   but it never goes there ,

 please explain me what could be causing this ?



 Mauro Ciancio wrote:

   In order to implement my sign out page I've created a SignOutPage
 that invokes the signOut method in AuthenticatedWebSession, then
 setRedirect(true) and as final step I throw a:

 throw new RestartResponseException(HomePage.class).

   This makes the home page be processed (and the url in the navigation
 bar remains /your_home_page_url).

 Here is the full code if you need it:

 public class LogOutPage extends WebPage {

     public LogOutPage() {
         AuthenticatedWebSession.get().signOut();
         setRedirect(true);
         throw new RestartResponseException(HomePage.class);
     }
 }

 Cheers.

 On 

Re: AW: signout and redirect

2010-03-25 Thread fachhoch

so what is the solution for my case ?

James Carman-3 wrote:
 
 By default, Wicket uses the KeyInSessionSunJceCryptFactory which
 stores the encryption key in the user's session.
 
 On Thu, Mar 25, 2010 at 11:50 AM, fachhoch fachh...@gmail.com wrote:

 does encryption has anything to do with this   upon debugging I found its
 failing  in CryptedUrlWebRequestCodingStrategy.java

 here is the method where it fails

        protected String decodeURL(final String url)
        {
                int startIndex = url.indexOf(?x=);
                if (startIndex == -1)
                {
                        startIndex = url.indexOf(x=);
                }

                if (startIndex != -1)
                {
                        try
                        {
                                startIndex = startIndex + 3;
                                final int endIndex = url.indexOf(,
 startIndex);
                                String secureParam;
                                if (endIndex == -1)
                                {
                                        secureParam =
 url.substring(startIndex);
                                }
                                else
                                {
                                        secureParam =
 url.substring(startIndex, endIndex);
                                }

                                secureParam =
 WicketURLDecoder.QUERY_INSTANCE.decode(secureParam);

                                // Get the crypt implementation from the
 application
                                final ICrypt urlCrypt = Application.get()
                                        .getSecuritySettings()
                                        .getCryptFactory()
                                        .newCrypt();

                                // Decrypt the query string
                                String queryString =
 urlCrypt.decryptUrlSafe(secureParam);

                                // The querystring might have been
 shortened (length reduced).
                                // In that case, lengthen the query string
 again.
                                queryString = rebuildUrl(queryString);
                                return queryString;
                        }
                        catch (Exception ex)
                        {
                                return onError(ex, url);
                        }
                }
                return null;
        }
 it fails at this line
 String queryString = urlCrypt.decryptUrlSafe(secureParam);

 why decrypt fails  if session is  invalidated ?

 James Carman-3 wrote:

 This works for me:

 final Link signOutLink = new Link(signOutLink)
         {
             public void onClick()
             {
                 getSession().invalidate();
                 setResponsePage(getApplication().getHomePage());
                 setRedirect(true);
             }

             public boolean isVisible()
             {
                 return ((MySessionClass)getSession()).isSignedIn();
             }
         };

 I put that in my base page class so that it's visible everywhere.

 On Thu, Mar 25, 2010 at 11:30 AM, fachhoch fachh...@gmail.com wrote:

 I did as u said
 public class AuditSignOutPage extends SignOutPage
 {

        public AuditSignOutPage() {
                ((AuditWebSession)(Session.get())).signout();
                setRedirect(true);
                throw new
 RestartResponseException(SSISignOutPage.class);
        }
 }


 public class SSISignOutPage extends UnSecuredBasePage {

        public SSISignOutPage() {
                add(new AjaxLinkVoid(relogin){
                       �...@override
                        public void onClick(AjaxRequestTarget target) {
                                setResponsePage(new
 AuditWicketApplication.SignInPageHelper().getSignInPage());
                                setRedirect(true);
                        }
                });
        }
 }
 I click on the signout link   AuditSignOutPage   invalidates  the
 session
 and send to   SSISignOutPage   .here this page gets loaded , I see the
 link
 relogin.

 when  I click on the link relogin it should take me to my signinpage
 but
 again i am ending up with session expired page .  I  set the break
 point
 in onClick method   but it never goes there ,

 please explain me what could be causing this ?



 Mauro Ciancio wrote:

   In order to implement my sign out page I've created a SignOutPage
 that invokes the signOut method in AuthenticatedWebSession, then
 setRedirect(true) and as final step I throw a:

 throw new RestartResponseException(HomePage.class).

   This makes the home page be processed (and the url in the navigation
 bar remains /your_home_page_url).

 Here is the full code if you need it:

 public class LogOutPage extends WebPage {

     public LogOutPage() {
         AuthenticatedWebSession.get().signOut();
         setRedirect(true);
         throw new 

DatePicker and visibility of the parent component

2010-03-25 Thread Anna Simbirtsev
Hi,

I have date picker added to a date field.

DateTextField field = new DateTextField(field, -MM-dd);

field1.add(new DatePicker());

If the section the date picker is in is visible there is no problem. If the
section is not visible using wicket:enclosure, I get an error:
http://localhost:8080/resources/org.apache.wicket.extensions.yui.YuiLib/calendar/calendar.jsUncaught
TypeError: Cannot read property 'id' of null

Thanks
Anna


Re: TypeNotPresentException

2010-03-25 Thread Swanthe Lindgren
Look more like a REST deserialization problem then a wicket. Could it be 
that se.**.core.domain.KmsUser only is available in your back end 
server? We use an environment very much like yours, with a back end 
which we send REST request to from our wicket layer, and we don't use 
the same classes at both ends.


//Swanthe



On 2010-03-19 13:05, Svante Reutland wrote:

Hi!

Im working on a project and I'm getting a weird exception in which I don't 
understand how to resolve. My application resides in two modules.

One server side module where all business logic are. On the server side I user 
spring and restful webservices. Than I have a web module which interact with 
the server side. The web tier is written in Wicket framework.

Now to the problem. When I try to access my restful webservices everything 
works great until I try to access a webservice that handles more than one 
entity. For example trying to access a users roles by entering userID.

this is the exception being thrown:
Code:
ERROR - RequestCycle.logRuntimeException(1521) | Method onFormSubmitted of 
interface org.apache.wicket.markup.html.form.IFormSubmitListener targeted at 
component [MarkupContainer [Component id = form]] threw an exception
org.apache.wicket.WicketRuntimeException: Method onFormSubmitted of interface 
org.apache.wicket.markup.html.form.IFormSubmitListener targeted at component 
[MarkupContainer [Component id = form]] threw an exception
 at 
org.apache.wicket.RequestListenerInterface.invoke(RequestListenerInterface.java:193)
 at 
org.apache.wicket.request.target.component.listener.ListenerInterfaceRequestTarget.processEvents(ListenerInterfaceRequestTarget.java:73)
 at 
org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:92)
 at 
org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1250)
 at org.apache.wicket.RequestCycle.step(RequestCycle.java:1329)
 at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1428)
 at org.apache.wicket.RequestCycle.request(RequestCycle.java:545)
 at 
org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:468)
 at 
org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:301)
 at 
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
 at 
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:388)
 at 
org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
 at 
org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
 at 
org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
 at 
org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:418)
 at 
org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230)
 at 
org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
 at 
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
 at org.mortbay.jetty.Server.handle(Server.java:326)
 at 
org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:536)
 at 
org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:930)
 at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:747)
 at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
 at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:405)
 at 
org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:228)
 at 
org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
Caused by: java.lang.reflect.InvocationTargetException
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
 at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
 at java.lang.reflect.Method.invoke(Method.java:597)
 at 
org.apache.wicket.RequestListenerInterface.invoke(RequestListenerInterface.java:182)
 ... 25 more
Caused by: org.jboss.resteasy.spi.ReaderException: 
java.lang.TypeNotPresentException: Type se.**.core.domain.KmsUser not present
 at 
org.jboss.resteasy.core.messagebody.ReaderUtility.doRead(ReaderUtility.java:123)
 at 
org.jboss.resteasy.client.core.BaseClientResponse.readFrom(BaseClientResponse.java:246)
 at 
org.jboss.resteasy.client.core.BaseClientResponse.getEntity(BaseClientResponse.java:210)
 at 
org.jboss.resteasy.client.core.BaseClientResponse.getEntity(BaseClientResponse.java:171)
 at 
org.jboss.resteasy.client.core.ClientInvoker.extractEntity(ClientInvoker.java:170)
 at 
org.jboss.resteasy.client.core.ClientInvoker.invoke(ClientInvoker.java:112)
 at 

Re: [wicket-stuff] project sitemap-xml

2010-03-25 Thread MZemeck
I am also interested in a sitemap project.  Check out the Wiki about 
dynamic sitemap below.  Would be nice if someone encapsulated this into a 
project for reuse.

http://cwiki.apache.org/WICKET/seo-search-engine-optimization.html




Fernando Wermus fernando.wer...@gmail.com 
03/25/2010 11:49 AM
Please respond to
users@wicket.apache.org


To
users@wicket.apache.org
cc

Subject
[wicket-stuff] project sitemap-xml






Hi all,
I need to develop sitemap for my web app. I see that there is a 
project
related to this problem. Which is its situation? Does anyone know?

thanks in advance

-- 
Fernando Wermus.

www.linkedin.com/in/fernandowermus





Notice: This communication, including any attachments, is intended solely 
for the use of the individual or entity to which it is addressed. This 
communication may contain information that is protected from disclosure 
under State and/or Federal law. Please notify the sender immediately if 
you have received this communication in error and delete this email from 
your system. If you are not the intended recipient, you are requested not 
to disclose, copy, distribute or take any action in reliance on the 
contents of this information.

css resources location

2010-03-25 Thread Matias Pansa



Hi , i'm new to wicket . I been searching in the list archive for css resource 
problems but i can't found a solution .
My app is developed under netbeans and there's no way to make de css ( file or 
html embedded ) to work with wicket .
I try almost every way that i found on the archive of this list , but nothing 
work.
When i preview the html in the browser everything is ok , css ,images etc , but 
when i deploy to tomcat only css is rendered ok , images are not showed.

here is what i've used :

1 - css embedded in the html file , css is ok but images are no showed , i try 
almost every path ( background-image : url( ) ... ) posible to the images , 
same as the html and java  files , web folder , web-inf , image folder , 
resources ,etc. I check that resource images are in the war file.

2- wicket:head tag with headercontributor.forcss(...) , css and images not 
working at all in every folder of the app.


I try almost every solution found on the mail list , nothing works to show the 
images , so now i'm lost , the most basic solution was put all the css code in 
the html file and nothing.

here is the tree of the app in netbeans :

Shirosecurity -

  -web pages

   -meta-inf
   -web-inf

  -configuration files

  -server resources
 
  -sourcepackages

   -com.myapp.wicket

   --- java and html files

  -test packages

  -libraries


i would apreciate any help on this.




 













  
_
Mirá tus emails ¡cuando te llegan! Hotmail actualiza tu bandeja de entrada 
automáticamente. Ver más
http://www.descubrewindowslive.com/hotmail/actualizacion-guardado.asp

Re: css resources location

2010-03-25 Thread corneliu.petrescu
You've probably got the path wrong.
Try: 
 String contextPath =
((WebRequest)getRequest()).getHttpServletRequest().getContextPath();
 construct path like this
 String path = contextPath + relative_css_path;
CSSPackageResource.getHeaderContribution(path);


On Thu, 2010-03-25 at 14:08 -0300, Matias Pansa wrote:

 
 
 Hi , i'm new to wicket . I been searching in the list archive for css 
 resource problems but i can't found a solution .
 My app is developed under netbeans and there's no way to make de css ( file 
 or html embedded ) to work with wicket .
 I try almost every way that i found on the archive of this list , but nothing 
 work.
 When i preview the html in the browser everything is ok , css ,images etc , 
 but when i deploy to tomcat only css is rendered ok , images are not showed.
 
 here is what i've used :
 
 1 - css embedded in the html file , css is ok but images are no showed , i 
 try almost every path ( background-image : url( ) ... ) posible to the 
 images , same as the html and java  files , web folder , web-inf , image 
 folder , resources ,etc. I check that resource images are in the war file.
 
 2- wicket:head tag with headercontributor.forcss(...) , css and images not 
 working at all in every folder of the app.
 
 
 I try almost every solution found on the mail list , nothing works to show 
 the images , so now i'm lost , the most basic solution was put all the css 
 code in the html file and nothing.
 
 here is the tree of the app in netbeans :
 
 Shirosecurity -
 
   -web pages
 
-meta-inf
-web-inf
 
   -configuration files
 
   -server resources
  
   -sourcepackages
 
-com.myapp.wicket
 
--- java and html files
 
   -test packages
 
   -libraries
 
 
 i would apreciate any help on this.
 
 
 
 
  
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 _
 Mirá tus emails ¡cuando te llegan! Hotmail actualiza tu bandeja de entrada 
 automáticamente. Ver más
 http://www.descubrewindowslive.com/hotmail/actualizacion-guardado.asp




RE: css resources location

2010-03-25 Thread Stefan Lindner
If you use background-image : url(' '), the path of the url is relative to 
the location of your css.
So if you write background-image : url('images/myimg.png') you need a 
subdirectory imags where your css is
e.g.
   /mypackage/mycss.css
   /mypackages/images/myimg.png

Do you use images like this:

 img src=/somePath/myimg.png/

Then perhaps you should use wicket's Image class

 img wicket:id=myImg/

add(new Image(myImg, ImageResource);

Stefan




-Ursprüngliche Nachricht-
Von: Matias Pansa [mailto:matute...@hotmail.com] 
Gesendet: Donnerstag, 25. März 2010 18:08
An: users@wicket.apache.org
Betreff: css resources location




Hi , i'm new to wicket . I been searching in the list archive for css resource 
problems but i can't found a solution .
My app is developed under netbeans and there's no way to make de css ( file or 
html embedded ) to work with wicket .
I try almost every way that i found on the archive of this list , but nothing 
work.
When i preview the html in the browser everything is ok , css ,images etc , but 
when i deploy to tomcat only css is rendered ok , images are not showed.

here is what i've used :

1 - css embedded in the html file , css is ok but images are no showed , i try 
almost every path ( background-image : url( ) ... ) posible to the images , 
same as the html and java  files , web folder , web-inf , image folder , 
resources ,etc. I check that resource images are in the war file.

2- wicket:head tag with headercontributor.forcss(...) , css and images not 
working at all in every folder of the app.


I try almost every solution found on the mail list , nothing works to show the 
images , so now i'm lost , the most basic solution was put all the css code in 
the html file and nothing.

here is the tree of the app in netbeans :

Shirosecurity -

  -web pages

   -meta-inf
   -web-inf

  -configuration files

  -server resources
 
  -sourcepackages

   -com.myapp.wicket

   --- java and html files

  -test packages

  -libraries


i would apreciate any help on this.




 













  
_
Mirá tus emails ¡cuando te llegan! Hotmail actualiza tu bandeja de entrada 
automáticamente. Ver más
http://www.descubrewindowslive.com/hotmail/actualizacion-guardado.asp

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



Re: [wicket-stuff] project sitemap-xml

2010-03-25 Thread Fernando Wermus
Take a look at Xaloon project. It has a plug in about SEO. But It is a plug
in for Brix, I dont know much about it.

On Thu, Mar 25, 2010 at 2:03 PM, mzem...@osc.state.ny.us wrote:

 I am also interested in a sitemap project.  Check out the Wiki about
 dynamic sitemap below.  Would be nice if someone encapsulated this into a
 project for reuse.

 http://cwiki.apache.org/WICKET/seo-search-engine-optimization.html




 Fernando Wermus fernando.wer...@gmail.com
 03/25/2010 11:49 AM
 Please respond to
 users@wicket.apache.org


 To
 users@wicket.apache.org
 cc

 Subject
 [wicket-stuff] project sitemap-xml






 Hi all,
I need to develop sitemap for my web app. I see that there is a
 project
 related to this problem. Which is its situation? Does anyone know?

 thanks in advance

 --
 Fernando Wermus.

 www.linkedin.com/in/fernandowermus





 Notice: This communication, including any attachments, is intended solely
 for the use of the individual or entity to which it is addressed. This
 communication may contain information that is protected from disclosure
 under State and/or Federal law. Please notify the sender immediately if
 you have received this communication in error and delete this email from
 your system. If you are not the intended recipient, you are requested not
 to disclose, copy, distribute or take any action in reliance on the
 contents of this information.




-- 
Fernando Wermus.

www.linkedin.com/in/fernandowermus


Re: [wicket-stuff] project sitemap-xml

2010-03-25 Thread Fernando Wermus
Do you know why it is said in the page you mention, each pages should have a
different title?

On Thu, Mar 25, 2010 at 2:41 PM, Fernando Wermus
fernando.wer...@gmail.comwrote:

 Take a look at Xaloon project. It has a plug in about SEO. But It is a plug
 in for Brix, I dont know much about it.


 On Thu, Mar 25, 2010 at 2:03 PM, mzem...@osc.state.ny.us wrote:

 I am also interested in a sitemap project.  Check out the Wiki about
 dynamic sitemap below.  Would be nice if someone encapsulated this into a
 project for reuse.

 http://cwiki.apache.org/WICKET/seo-search-engine-optimization.html




 Fernando Wermus fernando.wer...@gmail.com
 03/25/2010 11:49 AM
 Please respond to
 users@wicket.apache.org


 To
 users@wicket.apache.org
 cc

 Subject
 [wicket-stuff] project sitemap-xml






 Hi all,
I need to develop sitemap for my web app. I see that there is a
 project
 related to this problem. Which is its situation? Does anyone know?

 thanks in advance

 --
 Fernando Wermus.

 www.linkedin.com/in/fernandowermus





 Notice: This communication, including any attachments, is intended solely
 for the use of the individual or entity to which it is addressed. This
 communication may contain information that is protected from disclosure
 under State and/or Federal law. Please notify the sender immediately if
 you have received this communication in error and delete this email from
 your system. If you are not the intended recipient, you are requested not
 to disclose, copy, distribute or take any action in reliance on the
 contents of this information.




 --
 Fernando Wermus.

 www.linkedin.com/in/fernandowermus




-- 
Fernando Wermus.

www.linkedin.com/in/fernandowermus


Re: [wicket-stuff] project sitemap-xml

2010-03-25 Thread MZemeck
I would gather they are eluding to the fact that search engines may not 
index url's with duplicate titles, so its a best practice to provide a 
title unique to the url.




Fernando Wermus fernando.wer...@gmail.com 
03/25/2010 01:46 PM
Please respond to
users@wicket.apache.org


To
users@wicket.apache.org
cc

Subject
Re: [wicket-stuff] project sitemap-xml






Do you know why it is said in the page you mention, each pages should have 
a
different title?

On Thu, Mar 25, 2010 at 2:41 PM, Fernando Wermus
fernando.wer...@gmail.comwrote:

 Take a look at Xaloon project. It has a plug in about SEO. But It is a 
plug
 in for Brix, I dont know much about it.


 On Thu, Mar 25, 2010 at 2:03 PM, mzem...@osc.state.ny.us wrote:

 I am also interested in a sitemap project.  Check out the Wiki about
 dynamic sitemap below.  Would be nice if someone encapsulated this into 
a
 project for reuse.

 http://cwiki.apache.org/WICKET/seo-search-engine-optimization.html




 Fernando Wermus fernando.wer...@gmail.com
 03/25/2010 11:49 AM
 Please respond to
 users@wicket.apache.org


 To
 users@wicket.apache.org
 cc

 Subject
 [wicket-stuff] project sitemap-xml






 Hi all,
I need to develop sitemap for my web app. I see that there is a
 project
 related to this problem. Which is its situation? Does anyone know?

 thanks in advance

 --
 Fernando Wermus.

 www.linkedin.com/in/fernandowermus





 Notice: This communication, including any attachments, is intended 
solely
 for the use of the individual or entity to which it is addressed. This
 communication may contain information that is protected from disclosure
 under State and/or Federal law. Please notify the sender immediately if
 you have received this communication in error and delete this email 
from
 your system. If you are not the intended recipient, you are requested 
not
 to disclose, copy, distribute or take any action in reliance on the
 contents of this information.




 --
 Fernando Wermus.

 www.linkedin.com/in/fernandowermus




-- 
Fernando Wermus.

www.linkedin.com/in/fernandowermus





Notice: This communication, including any attachments, is intended solely 
for the use of the individual or entity to which it is addressed. This 
communication may contain information that is protected from disclosure 
under State and/or Federal law. Please notify the sender immediately if 
you have received this communication in error and delete this email from 
your system. If you are not the intended recipient, you are requested not 
to disclose, copy, distribute or take any action in reliance on the 
contents of this information.

Using Tuckey URLRewrite in together with Wicket

2010-03-25 Thread Sluis, M. van der (Minto)
Hi folks,

I am running into a bit of trouble using Wicket in conjunction with
Tuckey UrlRewrite. Hopefully someone can push me in the right direction
to get this resolved.

My situation:
- Existing JSP application that uses URLRewrite.
- New version is wicket based that places a border around the old JSP
pages. Later pages can be migrated to wicket one by one.

But now our URLRewrite config results in:
 javax.servlet.ServletException: unable to get request dispatcher for
/topicview/SimpleWicketPage?page=/jsp/acties/systeemsleutel-toevoegen.js
ptopic=T3879601

Our urlrewrite.xml contains:

   ...
   rule
from^/(.+)/systeemsleutel-toevoegen$/from
to
type=forward%{context-path}/SimpleWicketPage?page=/jsp/acties/systeem
sleutel-toevoegen.jspamp;topic=$1/to
   /rule
   ...

So the rewrite works, but somehow the result is not passed to Wicket for
processing. When I replace forward with redirect Wicket does handle
the page as expected, but in this case POSTing a form will loose the
posted data as a result of the redirect.

Our web.xml configuration look like this


...
filter
filter-nameUrlRewriteFilter/filter-name
 
filter-classorg.tuckey.web.filters.urlrewrite.UrlRewriteFilter/filter
-class
init-param
param-nameconfReloadCheckInterval/param-name
param-value0/param-value
/init-param
init-param 
param-namelogLevel/param-name 
param-valueDEBUG/param-value 
   /init-param
/filter

filter-mapping
filter-nameUrlRewriteFilter/filter-name
url-pattern/*/url-pattern
dispatcherREQUEST/dispatcher
/filter-mapping

filter

filter-namenl.politie.topicview.TopicViewApplication/filter-name

filter-classorg.apache.wicket.protocol.http.WicketFilter
/filter-class
init-param
param-nameapplicationClassName/param-name

param-valuenl.politie.topicview.TopicViewApplication
/param-value
/init-param
/filter

filter-mapping

filter-namenl.politie.topicview.TopicViewApplication/filter-name
url-pattern/*/url-pattern
/filter-mapping
...


Trying to find the answer on the mailing list, I found some posts that
refer to urlrewrite. But I have not been able to resolve the issue.

Can someone please push me in the right direction?

Regards,

Minto van der Sluis


=DISCLAIMER

De informatie in deze e-mail is vertrouwelijk en uitsluitend bestemd 
voor de geadresseerde. Indien u niet de geadresseerde bent, wordt u 
er hierbij op gewezen, dat u geen recht heeft kennis te nemen van de 
rest van deze e-mail, deze te gebruiken, te kopieren of te verstrekken
aan andere personen dan de geadresseerde. Indien u deze e-mail 
abusievelijk hebt ontvangen, brengt u dan alstublieft de afzender 
op de hoogte, waarbij u bij deze gevraagd wordt het originele bericht 
te vernietigen. Politie Amsterdam-Amstelland is niet verantwoordelijk 
voor de inhoud van deze e-mail en wijst iedere aansprakelijkheid af 
voor en/of in verband met alle gevolgen en/of schade van een onjuiste 
of onvolledige verzending ervan. Tenzij uitdrukkelijk het tegendeel 
blijkt, kunnen aan dit bericht geen rechten worden ontleend. Het 
gebruik van Internet e-mail brengt zekere risico?s met zich mee. 
Daarom wordt iedere aansprakelijkheid voor het gebruik van dit medium 
door de Politie Amsterdam-Amstelland van de hand gewezen.


WicketFilter Config

2010-03-25 Thread MZemeck
Due to the fact that SpringWebApplication is deprecated, we evaluated 
several ways of configuring Wicket using WicketFilter.  I found 
ContextParamWebApplicationFactory to work with a Spring Annotation 
approach.  SpringWebApplicationFactory also works with a Spring Annotation 
approach, but since it returns a SpringWebApplication (deprecated) should 
it be avoided?

I would love to hear from the Wicket team as far as the recommended 
configuration.



Notice: This communication, including any attachments, is intended solely 
for the use of the individual or entity to which it is addressed. This 
communication may contain information that is protected from disclosure 
under State and/or Federal law. Please notify the sender immediately if 
you have received this communication in error and delete this email from 
your system. If you are not the intended recipient, you are requested not 
to disclose, copy, distribute or take any action in reliance on the 
contents of this information.

Re: [wicket-stuff] project sitemap-xml

2010-03-25 Thread Andreas Petersson

On Thu, 25 Mar 2010 12:49:14 -0300, Fernando Wermus
fernando.wer...@gmail.com wrote:
 Hi all,
 I need to develop sitemap for my web app. I see that there is a
project
 related to this problem. Which is its situation? Does anyone know?
 
 thanks in advance


hi!
the sitemap-xml micro-project is a very simple thing that builds upon three
assumptions:

1) you want to build a sitemap according to
http://www.sitemaps.org/protocol.php - this is the language search engines
like.
2) the urls you want to expose in this xml are all mapped with wicket
bookmarkable strategies.
3) you want your xml to be generated on-the-fly as opposed to pre-rendered

then you can use the sitemap-xml from wicketstuff. it helps you with the
correct syntax.

unfortunately after some basic tests i have not yet seen it in action
being grabbed by the search engines to see if everything works fine. a bit
of feedback would be nice.

if there are request for enchancement or any uncertainties about it do not
hesitate to ask on the mailing list. as it stands now i have a bit spare
time at hand :)
best regards
andreas


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



Re: css resources location

2010-03-25 Thread Alex Objelean

You may want to consider a different approach: wro4j
(http://code.google.com/p/wro4j/wiki/GettingStarted). It can help you to
keep all you resources organized, minimized  merged.

Alex Objelean


pochoclo wrote:
 
 
 
 
 Hi , i'm new to wicket . I been searching in the list archive for css
 resource problems but i can't found a solution .
 My app is developed under netbeans and there's no way to make de css (
 file or html embedded ) to work with wicket .
 I try almost every way that i found on the archive of this list , but
 nothing work.
 When i preview the html in the browser everything is ok , css ,images etc
 , but when i deploy to tomcat only css is rendered ok , images are not
 showed.
 
 here is what i've used :
 
 1 - css embedded in the html file , css is ok but images are no showed , i
 try almost every path ( background-image : url( ) ... ) posible to the
 images , same as the html and java  files , web folder , web-inf , image
 folder , resources ,etc. I check that resource images are in the war file.
 
 2- wicket:head tag with headercontributor.forcss(...) , css and images
 not working at all in every folder of the app.
 
 
 I try almost every solution found on the mail list , nothing works to show
 the images , so now i'm lost , the most basic solution was put all the css
 code in the html file and nothing.
 
 here is the tree of the app in netbeans :
 
 Shirosecurity -
 
   -web pages
 
-meta-inf
-web-inf
 
   -configuration files
 
   -server resources
  
   -sourcepackages
 
-com.myapp.wicket
 
--- java and html files
 
   -test packages
 
   -libraries
 
 
 i would apreciate any help on this.
 
 
 
 
  
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 _
 Mirá tus emails ¡cuando te llegan! Hotmail actualiza tu bandeja de entrada
 automáticamente. Ver más
 http://www.descubrewindowslive.com/hotmail/actualizacion-guardado.asp
 

-- 
View this message in context: 
http://old.nabble.com/css-resources-location-tp28032076p28034191.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Application addRenderHeadListener causing error

2010-03-25 Thread Josh Chappelle
Hi,

 

On one of our pages we are having a strange error. The page renders and a
few seconds later a wicket error occurs. Below is the stack trace.

 

In our Application class we are calling addRenderHeadListener for a jquery
library and one for google. It works great in most cases but on one page it
causes the error below. We are using wicket 1.4.7.

Any ideas?

 

Thanks,

 

Josh

 

WicketMessage: Only methods that can be called on IHeaderResponse outside
renderHead() are renderOnLoadJavascript and renderOnDomReadyJavascript

Root cause:

org.apache.wicket.WicketRuntimeException: Only methods that can be called on
IHeaderResponse outside renderHead() are renderOnLoadJavascript and
renderOnDomReadyJavascript

at
org.apache.wicket.ajax.AjaxRequestTarget$AjaxHeaderResponse.checkHeaderRende
ring(AjaxRequestTarget.java:872)

at
org.apache.wicket.ajax.AjaxRequestTarget$AjaxHeaderResponse.renderJavascript
Reference(AjaxRequestTarget.java:915)

at
org.apache.wicket.markup.html.JavascriptPackageResource$2.renderHead(Javascr
iptPackageResource.java:94)

at
org.apache.wicket.behavior.AbstractHeaderContributor.renderHead(AbstractHead
erContributor.java:68)

at
org.apache.wicket.Application.notifyRenderHeadListener(Application.java:1250
)

at
org.apache.wicket.markup.html.internal.HeaderResponse.init(HeaderResponse.
java:56)

at
org.apache.wicket.ajax.AjaxRequestTarget$AjaxHeaderResponse.init(AjaxReque
stTarget.java:951)

at
org.apache.wicket.ajax.AjaxRequestTarget.getHeaderResponse(AjaxRequestTarget
.java:1018)

at
org.apache.wicket.ajax.AbstractAjaxTimerBehavior.respond(AbstractAjaxTimerBe
havior.java:163)

at
org.apache.wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDefault
AjaxBehavior.java:286)

at
org.apache.wicket.request.target.component.listener.BehaviorRequestTarget.pr
ocessEvents(BehaviorRequestTarget.java:119)

at
org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(Abstra
ctRequestCycleProcessor.java:92)

at
org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:125
0)

at org.apache.wicket.RequestCycle.step(RequestCycle.java:1329)

at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1428)

at org.apache.wicket.RequestCycle.request(RequestCycle.java:545)

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

at
org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:312)

at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:235)

at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:206)

at
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterI
nternal(OpenSessionInViewFilter.java:198)

at
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestF
ilter.java:76)

at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:235)

at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:206)

at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:233)

at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:191)

at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127
)

at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102
)

at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
:109)

at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)

at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:852)

at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http
11Protocol.java:588)

at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)

at java.lang.Thread.run(Unknown Source)



RE: Application addRenderHeadListener causing error

2010-03-25 Thread Josh Chappelle
Found the problem. We had two AjaxSelfUpdatingTimerBehaviors added to two
different components and they were both set to 5 seconds. What's funny is
that if we commented out the addRenderHeadListener calls in the Application
class we would not get the error. My guess is the header listeners increased
the request time and then we were sending two ajax requests at the same time
on that particular page it increased the opportunity for a race condition in
request processing.(only a guess)

-Original Message-
From: Josh Chappelle [mailto:jchappe...@4redi.com] 
Sent: Thursday, March 25, 2010 3:17 PM
To: users@wicket.apache.org
Subject: Application addRenderHeadListener causing error

Hi,

 

On one of our pages we are having a strange error. The page renders and a
few seconds later a wicket error occurs. Below is the stack trace.

 

In our Application class we are calling addRenderHeadListener for a jquery
library and one for google. It works great in most cases but on one page it
causes the error below. We are using wicket 1.4.7.

Any ideas?

 

Thanks,

 

Josh

 

WicketMessage: Only methods that can be called on IHeaderResponse outside
renderHead() are renderOnLoadJavascript and renderOnDomReadyJavascript

Root cause:

org.apache.wicket.WicketRuntimeException: Only methods that can be called on
IHeaderResponse outside renderHead() are renderOnLoadJavascript and
renderOnDomReadyJavascript

at
org.apache.wicket.ajax.AjaxRequestTarget$AjaxHeaderResponse.checkHeaderRende
ring(AjaxRequestTarget.java:872)

at
org.apache.wicket.ajax.AjaxRequestTarget$AjaxHeaderResponse.renderJavascript
Reference(AjaxRequestTarget.java:915)

at
org.apache.wicket.markup.html.JavascriptPackageResource$2.renderHead(Javascr
iptPackageResource.java:94)

at
org.apache.wicket.behavior.AbstractHeaderContributor.renderHead(AbstractHead
erContributor.java:68)

at
org.apache.wicket.Application.notifyRenderHeadListener(Application.java:1250
)

at
org.apache.wicket.markup.html.internal.HeaderResponse.init(HeaderResponse.
java:56)

at
org.apache.wicket.ajax.AjaxRequestTarget$AjaxHeaderResponse.init(AjaxReque
stTarget.java:951)

at
org.apache.wicket.ajax.AjaxRequestTarget.getHeaderResponse(AjaxRequestTarget
.java:1018)

at
org.apache.wicket.ajax.AbstractAjaxTimerBehavior.respond(AbstractAjaxTimerBe
havior.java:163)

at
org.apache.wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDefault
AjaxBehavior.java:286)

at
org.apache.wicket.request.target.component.listener.BehaviorRequestTarget.pr
ocessEvents(BehaviorRequestTarget.java:119)

at
org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(Abstra
ctRequestCycleProcessor.java:92)

at
org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:125
0)

at org.apache.wicket.RequestCycle.step(RequestCycle.java:1329)

at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1428)

at org.apache.wicket.RequestCycle.request(RequestCycle.java:545)

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

at
org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:312)

at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:235)

at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:206)

at
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterI
nternal(OpenSessionInViewFilter.java:198)

at
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestF
ilter.java:76)

at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:235)

at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:206)

at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:233)

at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:191)

at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127
)

at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102
)

at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
:109)

at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)

at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:852)

at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http
11Protocol.java:588)

at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)

at java.lang.Thread.run(Unknown Source)



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



Re: WicketFilter Config

2010-03-25 Thread Igor Vaynberg
recommended configuration is on our wiki's spring page

-igor

On Thu, Mar 25, 2010 at 11:22 AM,  mzem...@osc.state.ny.us wrote:
 Due to the fact that SpringWebApplication is deprecated, we evaluated
 several ways of configuring Wicket using WicketFilter.  I found
 ContextParamWebApplicationFactory to work with a Spring Annotation
 approach.  SpringWebApplicationFactory also works with a Spring Annotation
 approach, but since it returns a SpringWebApplication (deprecated) should
 it be avoided?

 I would love to hear from the Wicket team as far as the recommended
 configuration.



 Notice: This communication, including any attachments, is intended solely
 for the use of the individual or entity to which it is addressed. This
 communication may contain information that is protected from disclosure
 under State and/or Federal law. Please notify the sender immediately if
 you have received this communication in error and delete this email from
 your system. If you are not the intended recipient, you are requested not
 to disclose, copy, distribute or take any action in reliance on the
 contents of this information.

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



RE: css resources location

2010-03-25 Thread Matias Pansa

Thanks for the quick response , i try this way and it's not working . 
The href is correct but the css file it's not loaded , even try using the same 
lines included in the wicket example app for netbeans 
using StyleSheetReference (...) and nothing.
In the example app the style.css file is in the same folder with the java and 
html files , the example works ok.

By now i just forget the images , just trying to make de css file work ,  
href=resources/com.com.myapp.HomePage/My.css 
but the page is not showin the css atributes.
 



 Subject: Re: css resources location
 From: corneliu.petre...@theredpoint.ro
 To: users@wicket.apache.org
 Date: Thu, 25 Mar 2010 19:25:03 +0200
 
 You've probably got the path wrong.
 Try: 
  String contextPath =
 ((WebRequest)getRequest()).getHttpServletRequest().getContextPath();
  construct path like this
  String path = contextPath + relative_css_path;
 CSSPackageResource.getHeaderContribution(path);
 
 
 On Thu, 2010-03-25 at 14:08 -0300, Matias Pansa wrote:
 
  
  
  Hi , i'm new to wicket . I been searching in the list archive for css 
  resource problems but i can't found a solution .
  My app is developed under netbeans and there's no way to make de css ( file 
  or html embedded ) to work with wicket .
  I try almost every way that i found on the archive of this list , but 
  nothing work.
  When i preview the html in the browser everything is ok , css ,images etc , 
  but when i deploy to tomcat only css is rendered ok , images are not showed.
  
  here is what i've used :
  
  1 - css embedded in the html file , css is ok but images are no showed , i 
  try almost every path ( background-image : url( ) ... ) posible to the 
  images , same as the html and java  files , web folder , web-inf , image 
  folder , resources ,etc. I check that resource images are in the war file.
  
  2- wicket:head tag with headercontributor.forcss(...) , css and images 
  not working at all in every folder of the app.
  
  
  I try almost every solution found on the mail list , nothing works to show 
  the images , so now i'm lost , the most basic solution was put all the css 
  code in the html file and nothing.
  
  here is the tree of the app in netbeans :
  
  Shirosecurity -
  
-web pages
  
 -meta-inf
 -web-inf
  
-configuration files
  
-server resources
   
-sourcepackages
  
 -com.myapp.wicket
  
 --- java and html files
  
-test packages
  
-libraries
  
  
  i would apreciate any help on this.
  
  
  
  
   
  
  
  
  
  
  
  
  
  
  
  
  
  

  _
  Mirá tus emails ¡cuando te llegan! Hotmail actualiza tu bandeja de entrada 
  automáticamente. Ver más
  http://www.descubrewindowslive.com/hotmail/actualizacion-guardado.asp
 
 
  
_
Mirá tus emails ¡cuando te llegan! Hotmail actualiza tu bandeja de entrada 
automáticamente. Ver más
http://www.descubrewindowslive.com/hotmail/actualizacion-guardado.asp

Re: WicketFilter Config

2010-03-25 Thread Cemal Bayramoglu
See if   http://jweekend.com/dev/LegUp  gives you an easy way to get started.

Regards - Cemal
jWeekend
OO  Java Technologies, Wicket
Consulting, Development, Training
http://jWeekend.com


On 25 March 2010 18:22,  mzem...@osc.state.ny.us wrote:
 Due to the fact that SpringWebApplication is deprecated, we evaluated
 several ways of configuring Wicket using WicketFilter.  I found
 ContextParamWebApplicationFactory to work with a Spring Annotation
 approach.  SpringWebApplicationFactory also works with a Spring Annotation
 approach, but since it returns a SpringWebApplication (deprecated) should
 it be avoided?

 I would love to hear from the Wicket team as far as the recommended
 configuration.



 Notice: This communication, including any attachments, is intended solely
 for the use of the individual or entity to which it is addressed. This
 communication may contain information that is protected from disclosure
 under State and/or Federal law. Please notify the sender immediately if
 you have received this communication in error and delete this email from
 your system. If you are not the intended recipient, you are requested not
 to disclose, copy, distribute or take any action in reliance on the
 contents of this information.

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