Re: Bugs in wicket

2008-11-10 Thread jensiator

I've reported it to wicket JIRA.
Jens


Yes it seems to have a bug with datepicker in ModalWindows with IE7 (works
with firefox 3).
In file calendar-min.js line : this.oDomContainer.innerHTML=B.join(\n)
I think that innerHTML property is readonly in IE7.

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


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



Re: Wicket portlet

2008-11-10 Thread Nino Saturnino Martinez Vazquez Wael
Could people who use wicket in some portal container create a wiki page 
and report if it's working, working with problems or just not working?


maybe a sub page to this: http://cwiki.apache.org/WICKET/portal-howto.html


regards Nino

Serkan Camurcuoglu wrote:
though I've only used it in Jetspeed portal, I strongly recommend 
Wicket instead of Struts2 for portlet development..




Danny van Bruggen wrote:

Hi Pierre,

As far as I know (and I'm not an authority,) the status is as follows:

- portlet 1.0 support is OK
- portlet 2.0 support should be implemented soon (maybe it has
already been done?)
- Websphere is broken and does not accept Wicket portlets. Neither WS
or Wicket want to fix it.

Hopefully someone can give you more inside information ;)

Danny

On Thu, Nov 6, 2008 at 8:25 PM, Pierre Goupil 
[EMAIL PROTECTED] wrote:
 

Hello all,

I'm currently evaluating Struts2 Vs. Wicket 1.3.5 as a Web framework 
in a

portlet environment. I'm using eXo WebOS as a portal.

My question is : what's the status of portlet support in Wicket ? I 
don't
really care about portlet 1.0 or 2.0 but I'm looking for a fairly 
robust and

easy-to-go integration of my Web framework and my portal.

Hope to be clear !

Cheers,

Pierre



--
Parce que c'est la nuit qu'il est beau de croire en la lumière.




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


  



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



--
-Wicket for love

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


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



Wicket in clustered environment

2008-11-10 Thread Ricardo Mayerhofer

I have a clustered environment that is already running beehive, struts 2, jsf
projects. I'd like to develop a new project using wicket.
Is there any special configuration needed to run wicket in a clustered
environment?

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


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



Re: Wicket portlet

2008-11-10 Thread Serkan Camurcuoglu
though I've only used it in Jetspeed portal, I strongly recommend Wicket 
instead of Struts2 for portlet development..




Danny van Bruggen wrote:

Hi Pierre,

As far as I know (and I'm not an authority,) the status is as follows:

- portlet 1.0 support is OK
- portlet 2.0 support should be implemented soon (maybe it has
already been done?)
- Websphere is broken and does not accept Wicket portlets. Neither WS
or Wicket want to fix it.

Hopefully someone can give you more inside information ;)

Danny

On Thu, Nov 6, 2008 at 8:25 PM, Pierre Goupil [EMAIL PROTECTED] wrote:
  

Hello all,

I'm currently evaluating Struts2 Vs. Wicket 1.3.5 as a Web framework in a
portlet environment. I'm using eXo WebOS as a portal.

My question is : what's the status of portlet support in Wicket ? I don't
really care about portlet 1.0 or 2.0 but I'm looking for a fairly robust and
easy-to-go integration of my Web framework and my portal.

Hope to be clear !

Cheers,

Pierre



--
Parce que c'est la nuit qu'il est beau de croire en la lumière.




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


  



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



force client to use GET method

2008-11-10 Thread eyalbenamram

Hi
How do I tell the client to use a GET method instead of POST?
The problem is, the client is sending the form from a previous page
in a POST request, causing a double submission.
-- 
View this message in context: 
http://www.nabble.com/force-client-to-use-GET-method-tp20420920p20420920.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: force client to use GET method

2008-11-10 Thread Piller Sébastien

write it in html?

form wicket:id=foo method=GET...

eyalbenamram a écrit :

Hi
How do I tell the client to use a GET method instead of POST?
The problem is, the client is sending the form from a previous page
in a POST request, causing a double submission.
  



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



Re: force client to use GET method

2008-11-10 Thread Jeremy Thomerson
Or the method described here:
http://www.nabble.com/form-GET-calling-onSubmit-td19824816.html



-- 
Jeremy Thomerson
http://www.wickettraining.com

On Mon, Nov 10, 2008 at 8:38 AM, Piller Sébastien [EMAIL PROTECTED]wrote:

 write it in html?

 form wicket:id=foo method=GET...

 eyalbenamram a écrit :

 Hi
 How do I tell the client to use a GET method instead of POST?
 The problem is, the client is sending the form from a previous page
 in a POST request, causing a double submission.




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




Re: force client to use GET method

2008-11-10 Thread eyalbenamram

Ok.. that didn't stop the client from submitting the form of the previous
page again. 
Any other solutions to preventing double submissions?


Pills wrote:
 
 write it in html?
 
 form wicket:id=foo method=GET...
 
 eyalbenamram a écrit :
 Hi
 How do I tell the client to use a GET method instead of POST?
 The problem is, the client is sending the form from a previous page
 in a POST request, causing a double submission.
   
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/force-client-to-use-GET-method-tp20420920p20421291.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: force client to use GET method

2008-11-10 Thread Jeremy Thomerson
Can you give more details on what you mean by submitting the form of the
previous page again?

Is this:
1 - the user is clicking the submit button, and then clicking again before
the page every changes?
2 - the form is being submitted, and the user is doing refresh / etc / to
resubmit?

Number two is handled by default by Wicket using the redirect to buffer
strategy, unless you have modified settings otherwise.


-- 
Jeremy Thomerson
http://www.wickettraining.com


On Mon, Nov 10, 2008 at 8:46 AM, eyalbenamram [EMAIL PROTECTED]wrote:


 Ok.. that didn't stop the client from submitting the form of the previous
 page again.
 Any other solutions to preventing double submissions?


 Pills wrote:
 
  write it in html?
 
  form wicket:id=foo method=GET...
 
  eyalbenamram a écrit :
  Hi
  How do I tell the client to use a GET method instead of POST?
  The problem is, the client is sending the form from a previous page
  in a POST request, causing a double submission.
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

 --
 View this message in context:
 http://www.nabble.com/force-client-to-use-GET-method-tp20420920p20421291.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




Re: force client to use GET method

2008-11-10 Thread Piller Sébastien

store a flag in the form that change to true when the form is submitted.

then, in onsubmit, check if(myflag) { return;}

should work... ugly but should work


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



form being posted many times

2008-11-10 Thread eyalbenamram

Hi
I have a login page (with a form) that redirects to a progress bar page.
after the user submits the login form, I redirect to the progress bar page,
and it has an auto refresh so that every few seconds it refresh the page 
(to check if the login sequence is done).
The problem is the on refresh of progress bar, the browser client is posting
the login form again and again
with a POST request.
How do I make the progress bar page to be requested in a GET request.
I tried to override getMethod but it didn't work.

Thanks, Eyal.
-- 
View this message in context: 
http://www.nabble.com/form-being-posted-many-times-tp20418164p20418164.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: form being posted many times

2008-11-10 Thread eyalbenamram

Lazy load doesn't work for me. I cannot use AJAX since 
it is supposed to work on Mobile that may not support it.
Any other solution?


eyalbenamram wrote:
 
 Hi
 I have a login page (with a form) that redirects to a progress bar page.
 after the user submits the login form, I redirect to the progress bar
 page,
 and it has an auto refresh so that every few seconds it refresh the page 
 (to check if the login sequence is done).
 The problem is the on refresh of progress bar, the browser client is
 posting the login form again and again
 with a POST request.
 How do I make the progress bar page to be requested in a GET request.
 I tried to override getMethod but it didn't work.
 
 Thanks, Eyal.
 

-- 
View this message in context: 
http://www.nabble.com/form-being-posted-many-times-tp20418164p20418432.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Use provided head section

2008-11-10 Thread Thies Edeling

Hello,

At my current project the header and footer of each page is generated by 
a CMS, Fatwire, and provided as plain html. The generated header  
includes the head section (with lots of  javascript/css includes) and 
some layout tags.
In a JSP application the header/footer were jsp:included and any 
javascript/css files the application needed would be statically added in 
the CMS itself.
How to do this with Wicket? Contributions to the body of the html page 
is not a problem, I can parse them out of the provided html and add them 
as a Label or such but what's the best way to deal with a providedhead 
section ?


gr,
Thies

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



Re: SV: force client to use GET method

2008-11-10 Thread eyalbenamram

Thanks!!

Wilhelmsen Tor Iver wrote:
 
 Ok.. that didn't stop the client from submitting the form of 
 the previous page again. 
 Any other solutions to preventing double submissions?
 
 Tell people to use a less stupid browser than IE? (Which is the one with
 that behavior if memory serves)? :)
 
 Real solution: Use a hidden token that you use to check whether the
 particular form already has been posted, and in that case just skip the
 form processing and work on the already processed object, something like
 this in onSubmit():
 
 // MapString, DataObject objectmap...
 
 // FormDataObject
 
 String tokenvalue = form.get(token);
 DataObject obj = objectmap.get(tokenvalue);
 if (obj == null) {
 // Not already handled
 obj = this.getModelObject();
 // TODO Persist or whatever
 // Put in map
 objectmap.put(tokenvalue, obj);
 }
 // TODO Operate on obj
 
 Instead of this thrown-together example using an objectmap (which will
 get filled with garbage), use the session.
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/force-client-to-use-GET-method-tp20420920p20422599.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



WebMarkupContainer with AjaxTabbedPanel - duplicating panel data

2008-11-10 Thread Yazeed Isaacs
Hi

 

I have a WebMarkupContainer with a AjaxTabbedPanel. When I click on the
tab it duplicates the panel data.

 

What  am I doing wrong?

 

Here is my code:

 

final WebMarkupContainer terminalsContainer = new WebMarkupContainer(

terminalsContainer);

 

terminalsContainer.setOutputMarkupId(true);

terminalsContainer

.add(new ListView(terminalDetails, new
ArrayList()) {

  @Override

  protected void populateItem(ListItem item)
{

  }

});

 

add(terminalsContainer);

 

..

 

AjaxLink link = new AjaxLink(terminalIdLink) {

  @Override

public void onClick(AjaxRequestTarget target) {

ArrayList tabs = new ArrayList();

  

tabs.add(new AbstractTab(new Model(Details)) {

 

public Panel getPanel(String panelId) {

return new TerminalMonitorDetailsTabPanel(

  panelId, terminal.getId());

  }

});

 

terminalsContainer.replace(new AjaxTabbedPanel(terminalDetails,
tabs));

target.addComponent(terminalsContainer);

}

}

 

 

 

When I click on the Details tab then the data returned by the panel
TerminalMonitorDetailsTabPanel is duplicated below each time.

 

 

 

 

Yazeed Isaacs - Java Developer

[EMAIL PROTECTED]

 

 

 



setRequired on CheckBox

2008-11-10 Thread Emond Papegaaij
Hello all,

During the development of a (somewhat) generic form component, I stumbled on 
the following error:
FormComponent can't be not required when the type is primitive class: 
[MarkupContainer [Component id = formField, page = No Page, path = 
formField.CheckBox]]

This is caused by calling setType(Boolean.TYPE) and setRequired(false) on a 
CheckBox component. setRequired checks if the type is a primitive and throws 
an exception when an attempt is made to make the component not required for a 
primitive. Although I think this is a good thing for most components, I don't 
think this behaviour can be applied on a CheckBox, because of the (slightly) 
different interpretation of required on a CheckBox (WICKET-1221). Perhaps 
CheckBox should override setRequired to not throw the Exception? Right now, I 
am required to always check a CheckBox when I set the type to Boolean.TYPE.

Best regards,
Emond Papegaaij

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



Re: Wickets and Jung

2008-11-10 Thread Igor Vaynberg
what exactly is the issue you are having?

-igor

On Sun, Nov 9, 2008 at 3:58 PM, Jurek Piasek [EMAIL PROTECTED] wrote:
 Hi,

 I have a legacy web application that I am trying to port to wicket. I am
 having a problem with one page, in particular. The page makes use of JUNG
 (Java Universal Network/Graph Framework - http://jung.sourceforge.net/) to
 create a graph, the edges of which one can click on to get more information
 about the underlying process. The problem is that it the JUNG code is an
 applet and I am not sure of the best way to do the port. I noticed some
 earlier work in the wicket sandbox that purports to work with applets (
 http://svn.apache.org/repos/asf/wicket/sandbox/wicket-sandbox/src/jonathan/java/examples/applet/simple/SimpleApplet.java)
 but I cannot tell if this is live code or not.

 Any suggestions for a direction would be appreciated.

 Thanks,
 Jurek.


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



Re: WebMarkupContainer with AjaxTabbedPanel - duplicating panel data

2008-11-10 Thread Igor Vaynberg
could you paste your cod einto a pastebin that will show it properly
formatted. i cant read it in your email. also make sure you do not
have any divs inside spans, that is invalid html and causes browsers
to do funny things.

-igor

On Mon, Nov 10, 2008 at 4:12 AM, Yazeed Isaacs
[EMAIL PROTECTED] wrote:
 Hi



 I have a WebMarkupContainer with a AjaxTabbedPanel. When I click on the
 tab it duplicates the panel data.



 What  am I doing wrong?



 Here is my code:



 final WebMarkupContainer terminalsContainer = new WebMarkupContainer(

terminalsContainer);



terminalsContainer.setOutputMarkupId(true);

terminalsContainer

.add(new ListView(terminalDetails, new
 ArrayList()) {

  @Override

  protected void populateItem(ListItem item)
 {

  }

});



add(terminalsContainer);



..



 AjaxLink link = new AjaxLink(terminalIdLink) {

  @Override

 public void onClick(AjaxRequestTarget target) {

 ArrayList tabs = new ArrayList();



 tabs.add(new AbstractTab(new Model(Details)) {



 public Panel getPanel(String panelId) {

return new TerminalMonitorDetailsTabPanel(

  panelId, terminal.getId());

  }

 });



 terminalsContainer.replace(new AjaxTabbedPanel(terminalDetails,
 tabs));

 target.addComponent(terminalsContainer);

 }

}







 When I click on the Details tab then the data returned by the panel
 TerminalMonitorDetailsTabPanel is duplicated below each time.









 Yazeed Isaacs - Java Developer

 [EMAIL PROTECTED]









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



Re: Wicket portlet

2008-11-10 Thread Pierre Goupil
Hello again,

I did find this wiki page. Quoting it :

---
First of all, you need to make sure the portal (e.g. Liferay ) provides an
implementation of the Apache Portals Bridges
PortletResourceURLFactoryinterface, see:
PortletResourceURLFactoryhttp://portals.apache.org/bridges/multiproject/portals-bridges-common/xref/org/apache/portals/bridges/common/PortletResourceURLFactory.html
---

I don't know whether this interface is fully portlet spec compliant or not,
but anyways, my portal of choice is eXo platform (in WebOS mode) and it
doesn't provide it.

I am stuck or... ?

Regards,

Pierre



On Mon, Nov 10, 2008 at 1:48 PM, Nino Saturnino Martinez Vazquez Wael 
[EMAIL PROTECTED] wrote:

 Could people who use wicket in some portal container create a wiki page and
 report if it's working, working with problems or just not working?

 maybe a sub page to this: http://cwiki.apache.org/WICKET/portal-howto.html



-- 
Parce que c'est la nuit qu'il est beau de croire en la lumière.


Re: form being posted many times

2008-11-10 Thread Igor Vaynberg
show us some code because this doesnt make sense unless the way you
refresh is set a timer that does form.submit() on your login form.

-igor

On Mon, Nov 10, 2008 at 3:17 AM, eyalbenamram [EMAIL PROTECTED] wrote:

 Hi
 I have a login page (with a form) that redirects to a progress bar page.
 after the user submits the login form, I redirect to the progress bar page,
 and it has an auto refresh so that every few seconds it refresh the page
 (to check if the login sequence is done).
 The problem is the on refresh of progress bar, the browser client is posting
 the login form again and again
 with a POST request.
 How do I make the progress bar page to be requested in a GET request.
 I tried to override getMethod but it didn't work.

 Thanks, Eyal.
 --
 View this message in context: 
 http://www.nabble.com/form-being-posted-many-times-tp20418164p20418164.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



Re: Wicket in clustered environment

2008-11-10 Thread Igor Vaynberg
no.

-igor

On Mon, Nov 10, 2008 at 5:55 AM, Ricardo Mayerhofer
[EMAIL PROTECTED] wrote:

 I have a clustered environment that is already running beehive, struts 2, jsf
 projects. I'd like to develop a new project using wicket.
 Is there any special configuration needed to run wicket in a clustered
 environment?

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


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



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



AutoCompleteTextField and wicket 1.3.5

2008-11-10 Thread ulrik

There seems to be a problem with the AutoCompleteTextField in wicket 1.3.5.
The search results pops up in the wrong place (not below the search field).
When I downgrade to wicket 1.3.4 it works perfectly.

And the problem only occurs when I use Internet Explorer, not firefox.
I still wish to use wicket 1.3.5, does anybody know a sollution for this?
-- 
View this message in context: 
http://www.nabble.com/AutoCompleteTextField-and-wicket-1.3.5-tp20422758p20422758.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: force client to use GET method

2008-11-10 Thread Igor Vaynberg
why did you start another thread about this? please dont spawn more
then one thread for the same problem.

-igor

On Mon, Nov 10, 2008 at 6:27 AM, eyalbenamram [EMAIL PROTECTED] wrote:

 Hi
 How do I tell the client to use a GET method instead of POST?
 The problem is, the client is sending the form from a previous page
 in a POST request, causing a double submission.
 --
 View this message in context: 
 http://www.nabble.com/force-client-to-use-GET-method-tp20420920p20420920.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



Re: AutoCompleteTextField and wicket 1.3.5

2008-11-10 Thread bruno . borges

use firefox

On Nov 10, 2008 2:06pm, ulrik [EMAIL PROTECTED] wrote:



There seems to be a problem with the AutoCompleteTextField in wicket  

1.3.5.


The search results pops up in the wrong place (not below the search  

field).


When I downgrade to wicket 1.3.4 it works perfectly.



And the problem only occurs when I use Internet Explorer, not firefox.

I still wish to use wicket 1.3.5, does anybody know a sollution for this?

--

View this message in context:  

http://www.nabble.com/AutoCompleteTextField-and-wicket-1.3.5-tp20422758p20422758.html


Sent from the Wicket - User mailing list archive at Nabble.com.





-

To unsubscribe, e-mail: [EMAIL PROTECTED]

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





Re: Use provided head section

2008-11-10 Thread Igor Vaynberg
the most transparent thing to do would be to let your page have the
head tags and parse the head section out of the cms header and include
it via a header contributor. that way you let wicket retain control
over the head element and all other head contributors will work
transparently.

-igor

On Mon, Nov 10, 2008 at 4:13 AM, Thies Edeling [EMAIL PROTECTED] wrote:
 Hello,

 At my current project the header and footer of each page is generated by a
 CMS, Fatwire, and provided as plain html. The generated header  includes the
 head section (with lots of  javascript/css includes) and some layout tags.
 In a JSP application the header/footer were jsp:included and any
 javascript/css files the application needed would be statically added in the
 CMS itself.
 How to do this with Wicket? Contributions to the body of the html page is
 not a problem, I can parse them out of the provided html and add them as a
 Label or such but what's the best way to deal with a providedhead section
 ?

 gr,
 Thies

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



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



Re: Use provided head section

2008-11-10 Thread Thies Edeling
On Mon, Nov 10, 2008 at 5:09 PM, Charlie Dobbie [EMAIL PROTECTED] wrote:

 As default, anything in a wicket:head section gets included on the page.
 See the following:


 http://cwiki.apache.org/WICKET/wickets-xhtml-tags.html#Wicket%27sXHTMLtags-Elementwicket:head

 Otherwise, I'd say look into IHeaderContributor.

 --Charlie.



 2008/11/10 Thies Edeling [EMAIL PROTECTED]

  Hello,
 
  At my current project the header and footer of each page is generated by
 a
  CMS, Fatwire, and provided as plain html. The generated header  includes
 the
  head section (with lots of  javascript/css includes) and some layout
 tags.
  In a JSP application the header/footer were jsp:included and any
  javascript/css files the application needed would be statically added in
 the
  CMS itself.
  How to do this with Wicket? Contributions to the body of the html page is
  not a problem, I can parse them out of the provided html and add them as
 a
  Label or such but what's the best way to deal with a providedhead
 section
  ?
 
  gr,
  Thies
 



Re: Use provided head section

2008-11-10 Thread Christopher Lyth
There are 2 approaches i can imagine, without having the need to do
this or any knowledge of the api/tool you are using to generate the
headers.

* Write a custom HeaderContributor that, in the renderHead method,
fetches the head as generated from fatwire and write it out to the
header response.
* Get the generated header and write a simple parser that iterates
through the tags and adds a HeaderContributor for each tag type.

But i guess this depends on how those header components are generated.

On Mon, Nov 10, 2008 at 6:13 AM, Thies Edeling [EMAIL PROTECTED] wrote:

 Hello,

 At my current project the header and footer of each page is generated by a 
 CMS, Fatwire, and provided as plain html. The generated header  includes the 
 head section (with lots of  javascript/css includes) and some layout tags.
 In a JSP application the header/footer were jsp:included and any 
 javascript/css files the application needed would be statically added in the 
 CMS itself.
 How to do this with Wicket? Contributions to the body of the html page is not 
 a problem, I can parse them out of the provided html and add them as a Label 
 or such but what's the best way to deal with a providedhead section ?

 gr,
 Thies

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




--
Christopher J Lyth
[EMAIL PROTECTED]

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



Re: Use provided head section

2008-11-10 Thread Thies Edeling
Yes but the head section is in a different file, not managed by Wicket
so I can't use those tags. Anyway, I'm parsing out the head section from
the CMS file and then re-adding them in Wicket using indeed a
iheadercontributor.

(ok, I hope  this mail now does get sent properly - empty mail through gmail
and mail sent using my own smtp is killed by apache's sa.. grrr)

On Mon, Nov 10, 2008 at 5:09 PM, Charlie Dobbie [EMAIL PROTECTED] wrote:

 As default, anything in a wicket:head section gets included on the page.
 See the following:


 http://cwiki.apache.org/WICKET/wickets-xhtml-tags.html#Wicket%27sXHTMLtags-Elementwicket:head

 Otherwise, I'd say look into IHeaderContributor.

 --Charlie.



 2008/11/10 Thies Edeling [EMAIL PROTECTED]

  Hello,
 
  At my current project the header and footer of each page is generated by
 a
  CMS, Fatwire, and provided as plain html. The generated header  includes
 the
  head section (with lots of  javascript/css includes) and some layout
 tags.
  In a JSP application the header/footer were jsp:included and any
  javascript/css files the application needed would be statically added in
 the
  CMS itself.
  How to do this with Wicket? Contributions to the body of the html page is
  not a problem, I can parse them out of the provided html and add them as
 a
  Label or such but what's the best way to deal with a providedhead
 section
  ?
 
  gr,
  Thies
 



Re: Re: AutoCompleteTextField and wicket 1.3.5

2008-11-10 Thread bruno . borges

Not really. What version of IE are you using?

On Nov 10, 2008 2:19pm, ulrik [EMAIL PROTECTED] wrote:



Is that a joke?





Bruno Borges wrote:



 use firefox







--

View this message in context:  

http://www.nabble.com/AutoCompleteTextField-and-wicket-1.3.5-tp20422758p20423025.html


Sent from the Wicket - User mailing list archive at Nabble.com.





-

To unsubscribe, e-mail: [EMAIL PROTECTED]

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





Re: AutoCompleteTextField and wicket 1.3.5

2008-11-10 Thread ulrik

Is that a joke?


Bruno Borges wrote:
 
 use firefox
 


-- 
View this message in context: 
http://www.nabble.com/AutoCompleteTextField-and-wicket-1.3.5-tp20422758p20423025.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: Use provided head section

2008-11-10 Thread Charlie Dobbie
As default, anything in a wicket:head section gets included on the page.
See the following:

http://cwiki.apache.org/WICKET/wickets-xhtml-tags.html#Wicket%27sXHTMLtags-Elementwicket:head

Otherwise, I'd say look into IHeaderContributor.

--Charlie.



2008/11/10 Thies Edeling [EMAIL PROTECTED]

 Hello,

 At my current project the header and footer of each page is generated by a
 CMS, Fatwire, and provided as plain html. The generated header  includes the
 head section (with lots of  javascript/css includes) and some layout tags.
 In a JSP application the header/footer were jsp:included and any
 javascript/css files the application needed would be statically added in the
 CMS itself.
 How to do this with Wicket? Contributions to the body of the html page is
 not a problem, I can parse them out of the provided html and add them as a
 Label or such but what's the best way to deal with a providedhead section
 ?

 gr,
 Thies



combining target.addComponent and javascript

2008-11-10 Thread Steve Swinsburg

Hi all,

I am wanting to combine an AjaxRequestTarget addComponent call with a  
javascript call as well so that the component is added to the page by  
wicket, but displayed using a jQuery effect. The component adds to the  
page fine, but the jQuery effect doesn't seem to be working, the  
component just appears. Is it something to do with the order of when  
its set to be visible/prepend/append javascript?


//change picture panel
changePicture = new ChangeProfilePicture(changePicture, userProfile);
changePicture.setOutputMarkupPlaceholderTag(true);
//changePicture.setOutputMarkupId(true);
changePicture.setVisible(false);
add(changePicture);

//change profile image button
AjaxFallbackLink changePictureLink = new  
AjaxFallbackLink(changePictureLink, new  
ResourceModel(link.change.profile.picture)) {

public void onClick(AjaxRequestTarget target) {

//add the full changePicture component to the page dynamically
target.addComponent(changePicture);
changePicture.setVisible(true);
		String js = $('# + changePicture.getMarkupId() +  
').fadeIn('slow');

target.appendJavascript(js);

}

};
add(changePictureLink);

Any help much appreciated.


cheers,
Steve





smime.p7s
Description: S/MIME cryptographic signature


Re: force client to use GET method

2008-11-10 Thread eyalbenamram

Sorry, this seemed like two different ways that may solve the same problem.
anyway, problem solved. Thanks for your great support!

igor.vaynberg wrote:
 
 why did you start another thread about this? please dont spawn more
 then one thread for the same problem.
 
 -igor
 
 On Mon, Nov 10, 2008 at 6:27 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 Hi
 How do I tell the client to use a GET method instead of POST?
 The problem is, the client is sending the form from a previous page
 in a POST request, causing a double submission.
 --
 View this message in context:
 http://www.nabble.com/force-client-to-use-GET-method-tp20420920p20420920.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


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

-- 
View this message in context: 
http://www.nabble.com/force-client-to-use-GET-method-tp20420920p20423712.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: Wicket portlet

2008-11-10 Thread Serkan Camurcuoglu
I think you can write an implementation of this interface for eXo portal 
if you know a bit about its internals.. If eXo portal supports the 
portlet 2.0 spec, then it should be really simple since the portal will 
already have some way of generating resource urls, and you will delegate 
the call to this mechanism.. AFAIK, resource URLs are important for 
resource serving and wicket Ajax functionality..



Pierre Goupil wrote:

Hello again,

I did find this wiki page. Quoting it :

---
First of all, you need to make sure the portal (e.g. Liferay ) provides an
implementation of the Apache Portals Bridges
PortletResourceURLFactoryinterface, see:
PortletResourceURLFactoryhttp://portals.apache.org/bridges/multiproject/portals-bridges-common/xref/org/apache/portals/bridges/common/PortletResourceURLFactory.html
---

I don't know whether this interface is fully portlet spec compliant or not,
but anyways, my portal of choice is eXo platform (in WebOS mode) and it
doesn't provide it.

I am stuck or... ?

Regards,

Pierre



On Mon, Nov 10, 2008 at 1:48 PM, Nino Saturnino Martinez Vazquez Wael 
[EMAIL PROTECTED] wrote:

  

Could people who use wicket in some portal container create a wiki page and
report if it's working, working with problems or just not working?

maybe a sub page to this: http://cwiki.apache.org/WICKET/portal-howto.html







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



CSS navigation menu autolink

2008-11-10 Thread pgoiffon . wicket

Hello all,

I'm really new in the object world in general and using Wicket  
particularly, so please excuse if I'm missing something... I've  
googled around but maybe I didn't use the good keywords.



So here's my question !

I'm building a navigation menu for my web application. There are 3  
different levels, the higher one is linking to different Wicket pages.  
My top level menu is html coded like this :


ul
liMenu Item 1/li
li class=currentMenu Item 2/li
liMenu Item 3/li
/ul

Notice the class=current on the selected page.

I've already created the following code (see below), but was wondering  
if there are any means to use the Wicket autolink feature ? It would  
be far more simplier... The difficulty I see is to modify the li tag  
on the selected link ? Thanks for advices !




// LayoutAuthenticated.html
...
ul wicket:id=menu1a
li wicket:id=menu1aItemaLibellé menu1/a/li
/ul
...



// LayoutAuthenticated.java

protected MenuItem menu1aOpt1;
protected MenuItem menu1aOpt2;
protected MenuItem menu1aOpt3;

public LayoutAuthenticated() {
...
ListMenuItem menu1aList = new ArrayListMenuItem();
		menu1aList.add(menu1aOpt1 = new MenuItem(menu1aItem, true,  
menu1a.Opt1, Opt1.class));
		menu1aList.add(menu1aOpt2 = new MenuItem(menu1aItem, true,  
menu1a.Opt2, Opt2.class));
		menu1aList.add(menu1aOpt3 = new MenuItem(menu1aItem, true,  
menu1a.Opt3, Opt3.class));

add(new ListViewMenuItem(menu1a, menu1aList) {
@Override
protected void populateItem(ListItemMenuItem item) {
item.add(item.getModelObject());
}
});
...
}



// MenuItem.html

wicket:panel
li wicket:id=menuItema wicket:id=linkspan wicket:id=label  
//a/li

/wicket:panel



// MenuItem.java

private String keyLabel;
private Class lienClass;
private WebMarkupContainer menuItem;
private BookmarkablePageLinkWithoutDisabledMarkup link;

	public MenuItem(String wicketId, boolean isActive, String keyLabel,  
Class lienClass) {

super(wicketId);

setLienClass(lienClass);
setKeyLabel(keyLabel);

setRenderBodyOnly(true);
add(menuItem = new WebMarkupContainer(menuItem));
		menuItem.add(link = new  
BookmarkablePageLinkWithoutDisabledMarkup(link, lienClass));

Label label;
link.add(label = new Label(label, new 
ResourceModel(keyLabel)));
label.setRenderBodyOnly(true);
}

public void setLienClass(Class lienClass) {
this.lienClass = lienClass;
}

public void setKeyLabel(String keyLabel) {
this.keyLabel = keyLabel;
}

public void setActive() {
menuItem.add(new SimpleAttributeModifier(class,));
link.setEnabled(true);
}

public void setInActive() {
menuItem.add(new SimpleAttributeModifier(class,current));
link.setEnabled(false);
}



// BookmarkablePageLinkWithoutDisabledMarkup.java
// (just to keep my a tag on selected links)

public C extends Page 
BookmarkablePageLinkWithoutDisabledMarkup(String id,
ClassC pageClass) {
super(id, pageClass);
}

@Override
protected void disableLink(ComponentTag tag) {
tag.remove(href);
}



// Opt1.java

public class Opt1 extends LayoutAuthenticated {
public Opt1() {
menu1aOpt1.setInActive();
}
}



// Opt2.java

public class Opt2 extends LayoutAuthenticated {
public Opt2() {
menu1aOpt2.setInActive();
}
}



// Opt3.java

public class Opt3 extends LayoutAuthenticated {
public Opt3() {
menu1aOpt3.setInActive();
}
}



// Wicket application init()
// (don't need the default em tags around the selected link label)

...
getMarkupSettings().setDefaultBeforeDisabledLink();
getMarkupSettings().setDefaultAfterDisabledLink();
...


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



SV: force client to use GET method

2008-11-10 Thread Wilhelmsen Tor Iver
 Ok.. that didn't stop the client from submitting the form of 
 the previous page again. 
 Any other solutions to preventing double submissions?

Tell people to use a less stupid browser than IE? (Which is the one with
that behavior if memory serves)? :)

Real solution: Use a hidden token that you use to check whether the
particular form already has been posted, and in that case just skip the
form processing and work on the already processed object, something like
this in onSubmit():

// MapString, DataObject objectmap...

// FormDataObject

String tokenvalue = form.get(token);
DataObject obj = objectmap.get(tokenvalue);
if (obj == null) {
// Not already handled
obj = this.getModelObject();
// TODO Persist or whatever
// Put in map
objectmap.put(tokenvalue, obj);
}
// TODO Operate on obj

Instead of this thrown-together example using an objectmap (which will
get filled with garbage), use the session.

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



AW: form being posted many times

2008-11-10 Thread Stefan Lindner
Why don't you use a LazyLoadPanel? May this be an option?

-Ursprüngliche Nachricht-
Von: eyalbenamram [mailto:[EMAIL PROTECTED] 
Gesendet: Montag, 10. November 2008 12:17
An: users@wicket.apache.org
Betreff: form being posted many times


Hi
I have a login page (with a form) that redirects to a progress bar page.
after the user submits the login form, I redirect to the progress bar page,
and it has an auto refresh so that every few seconds it refresh the page 
(to check if the login sequence is done).
The problem is the on refresh of progress bar, the browser client is posting
the login form again and again
with a POST request.
How do I make the progress bar page to be requested in a GET request.
I tried to override getMethod but it didn't work.

Thanks, Eyal.
-- 
View this message in context: 
http://www.nabble.com/form-being-posted-many-times-tp20418164p20418164.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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


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



RE: AjaxFallbackDefaultDataTable with ajax lazy loading - sorting and paging throws an IllegalStateException

2008-11-10 Thread Yazeed Isaacs
I understand that the markupid needs to be there in order for ajax to
update the component.

The component that it complains about is called content which is the
inner content of the AjaxLazyLoadPanel.

I have set the ajaxlazyloadpanel to setRenderBodyOnly(false) and
setOutputMarkupId(true) and I did the same for the
AjaxFallbackDefaultDataTable, but I still get the same error.

This is my component layout:

Form  - AjaxButton
- AjaxLazyLoadPanel returns AjaxFallbackDefaultDataTable


Component id = content, page =
za.co.transactionjunction.transpector.pages.TransactionQueryPage, path =
8:transactionQueryForm:transactions:content.AjaxFallbackDefaultDataTable


Any ideas?

Yazeed Isaacs - Java Developer
[EMAIL PROTECTED]



-Original Message-
From: Ernesto Reinaldo Barreiro [mailto:[EMAIL PROTECTED] 
Sent: 06 October 2008 10:01 AM
To: users@wicket.apache.org
Subject: Re: AjaxFallbackDefaultDataTable with ajax lazy loading -
sorting and paging throws an IllegalStateException

The problem is, as Igor pointed, you cannot re-render a component via
AJAX
if it has set setRenderBodyOnly(true)... Why?
div wicket:id=testAjax
  pContent.../p
/div

will be renderend as

pContent.../p

instead of

div id=someid
  pContent.../p
/div

So, there is no way wicket AJAX js can replace the div with something
else... Additionally you have to set setOutputMarkupId(true) on the
component you want to replace..

Ernesto

On Mon, Oct 6, 2008 at 9:41 AM, Yazeed Isaacs 
[EMAIL PROTECTED] wrote:

 Hi Igor

 Here is the java code:

 add(new AjaxButton(ajaxSubmitButton, this) {

protected void onSubmit(AjaxRequestTarget target, Form form) {

AjaxLazyLoadPanel transactions = new AjaxLazyLoadPanel(
transactions) {

private static final long serialVersionUID =
1L;

@Override
public Component getLazyLoadComponent(String
id)
 {

TransactionQuery transactionQuery = new
 TransactionQuery();


 transactionQuery.setCardNumber(cardNumberField
.getInput());

 transactionQuery.setDateFrom(dateFromField
.getInput());

 transactionQuery.setDateTo(dateToField.getInput());

 transactionQuery.setStoreId(storeIdsDropDownChoice
.getInput());
transactionQuery

 .setTerminalId(terminalIdsDropDownChoice

 .getInput());
int transactionNumber = 0;
if (transNumberField.getInput() !=
null)
 {
if
 ((transNumberField.getInput().length()  0))
transactionNumber =
 Integer

 .parseInt(transNumberField

 .getInput());
}
transactionQuery

 .setTransactionNumber(transactionNumber);



AjaxFallbackDefaultDataTable results =
 new AjaxFallbackDefaultDataTable(
id,
columns,
new
 SortableTransactionQueryResultsDataProvider(

 transactionQuery), 10);

//
transactions.setOutputMarkupId(true);

results.setRenderBodyOnly(false);

return results;
}

};

transactions.setRenderBodyOnly(false);

form.replace(transactions);

target.addComponent(transactions);
}

 });



 HTML code:

 table cellpadding=2 cellspacing=0 width=521
 wicket:id=transactions

 /table


 I have tried playing around with the way I've implemented this, but I
 keep on getting the same exception (java.lang.IllegalStateException)
 when I sort a column or navigate to a page.

 Let me know what you think.

 Regards,
 Yazeed Isaacs



 -Original Message-
 From: Igor Vaynberg [mailto:[EMAIL PROTECTED]
 Sent: 06 October 2008 09:31 AM
 To: users@wicket.apache.org
 Subject: Re: AjaxFallbackDefaultDataTable with ajax lazy loading -
 sorting and paging throws an IllegalStateException

 if i were you i would read the exception message, it is telling you
 exactly what is going wrong...if you showed some code or provided a
 quickstart we can help further.

 -igor

 On Mon, Oct 6, 2008 at 12:04 AM, Yazeed Isaacs
 [EMAIL PROTECTED] wrote:
  Anybody?
 
  Guys please help me with this one.
 
 
 
  -Original Message-
  From: Yazeed Isaacs
  Sent: 03 October 2008 03:00 PM
  To: users@wicket.apache.org
  Subject: AjaxFallbackDefaultDataTable with ajax lazy loading -
sorting
 and paging throws an IllegalStateException
 
  Hi
 
  I have an 

Re: Wicket portlet

2008-11-10 Thread Danny van Bruggen
Hi Pierre,

As far as I know (and I'm not an authority,) the status is as follows:

- portlet 1.0 support is OK
- portlet 2.0 support should be implemented soon (maybe it has
already been done?)
- Websphere is broken and does not accept Wicket portlets. Neither WS
or Wicket want to fix it.

Hopefully someone can give you more inside information ;)

Danny

On Thu, Nov 6, 2008 at 8:25 PM, Pierre Goupil [EMAIL PROTECTED] wrote:
 Hello all,

 I'm currently evaluating Struts2 Vs. Wicket 1.3.5 as a Web framework in a
 portlet environment. I'm using eXo WebOS as a portal.

 My question is : what's the status of portlet support in Wicket ? I don't
 really care about portlet 1.0 or 2.0 but I'm looking for a fairly robust and
 easy-to-go integration of my Web framework and my portal.

 Hope to be clear !

 Cheers,

 Pierre



 --
 Parce que c'est la nuit qu'il est beau de croire en la lumière.


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



Re: AW: form being posted many times

2008-11-10 Thread eyalbenamram

Can you please elaborate?


Stefan Lindner wrote:
 
 Why don't you use a LazyLoadPanel? May this be an option?
 
 -Ursprüngliche Nachricht-
 Von: eyalbenamram [mailto:[EMAIL PROTECTED] 
 Gesendet: Montag, 10. November 2008 12:17
 An: users@wicket.apache.org
 Betreff: form being posted many times
 
 
 Hi
 I have a login page (with a form) that redirects to a progress bar page.
 after the user submits the login form, I redirect to the progress bar
 page,
 and it has an auto refresh so that every few seconds it refresh the page 
 (to check if the login sequence is done).
 The problem is the on refresh of progress bar, the browser client is
 posting
 the login form again and again
 with a POST request.
 How do I make the progress bar page to be requested in a GET request.
 I tried to override getMethod but it didn't work.
 
 Thanks, Eyal.
 -- 
 View this message in context:
 http://www.nabble.com/form-being-posted-many-times-tp20418164p20418164.html
 Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/form-being-posted-many-times-tp20418164p20418306.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: problem with PropertyModel and setDefaultFormProcessing(false) for button

2008-11-10 Thread Christopher Lyth
Have you tried to setDefaultFormProcessing to false and in the onSubmit of
the button reset the form model. Alternatively the add button could set the
model of the form to a new object every time.

On Sun, Nov 9, 2008 at 4:27 AM, itayh [EMAIL PROTECTED] wrote:


 Hi Timo,

 Changing it to link solve the problem, but created a new one. It changes
 the
 look and feel of my page (since I am using buttons for save and cancel in
 my
 site).

 Thank in advance,
  Itay


 Timo Rantalaiho wrote:
 
  On Tue, 28 Oct 2008, itayh wrote:
  I have a page that contain a hidden form. When the user press on Add
  Item
  or Edit Item then I set the visability of the form to true and the
 user
  can add details and the OK button save the data and set the visability
 of
  the form to false.
  The problem is if the user press on cancel. I need to set
  setDefaultFormProcessing(false) for the cancel button (since I don't
 want
  to
  do validation checks) but It cause the next problem:
  After the cancel press next time I press the Add Item or Edit Item
  the
  data that I see is the old data (The one I press cancel on)
  Changing setDefaultFormProcessing(true) for the cancel fix that problem.
 
  Maybe you could change the cancel button
 
  addItemForm.add(new Button(cancel, new Model(Cancel)) {
  public void onSubmit() {
   onCanceItem();
  }
  }.setDefaultFormProcessing(false));
 
  to be a Link in Wicket? That way it would definitely not
  submit any form data to the server, so nothing should be
  stored in between requests.
 
  Best wishes,
  Timo
 
  --
  Timo Rantalaiho
  Reaktor Innovations OyURL: http://www.ri.fi/ 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

 --
 View this message in context:
 http://www.nabble.com/problem-with-PropertyModel-and-setDefaultFormProcessing%28false%29-for-button-tp20209348p20404643.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




-- 
Christopher J Lyth
[EMAIL PROTECTED]


Help: webApplication can not go to loginPage,directory go to HomePage

2008-11-10 Thread wch2001

Dear all,

Can you help  me to look at my webapplication, it can not call
loginpage(LoginPage.class) first, but directly call
homepage(IndexPage.class), thanks a lot

package sg.sphsearch.people.selfupdate.wicket.application;

import java.net.MalformedURLException;
import org.acegisecurity.AuthenticationManager;
import org.apache.wicket.Page;
import org.apache.wicket.Request;
import org.apache.wicket.RequestCycle;
import org.apache.wicket.Response;
import org.apache.wicket.Session;
import org.apache.wicket.WicketRuntimeException;
import
org.apache.wicket.extensions.ajax.markup.html.form.upload.UploadWebRequest;
import org.apache.wicket.protocol.http.WebApplication;
import org.apache.wicket.security.hive.HiveMind;
import org.apache.wicket.security.hive.authentication.LoginContext;
import org.apache.wicket.security.hive.config.PolicyFileHiveFactory;
import org.apache.wicket.security.swarm.SwarmWebApplication;
import org.apache.wicket.spring.injection.annot.SpringComponentInjector;
import org.apache.wicket.util.lang.PackageName;
import org.apache.wicket.protocol.http.WebRequest;
import org.apache.wicket.protocol.http.WebRequestCycle;
import org.apache.wicket.protocol.http.WebResponse;
import sg.sphsearch.people.selfupdate.wicket.page.IndexPage;
import sg.sphsearch.people.selfupdate.wicket.page.RegistrationPage;
import sg.sphsearch.people.selfupdate.wicket.security.AcegiLoginContext;
import sg.sphsearch.people.selfupdate.wicket.security.LoginPage;
import
sg.sphsearch.people.selfupdate.wicket.security.SelfupdateRequestCycle;
import javax.servlet.http.HttpServletRequest;
import sg.sphsearch.people.selfupdate.wicket.security.ErrorPage;
import sg.sphsearch.people.selfupdate.wicket.security.ExpiredPage;
/**
 * 
 * @author jmulyadi
 *
 */
public class PeopleSelfUpdateApplication extends SwarmWebApplication
implements AcegiApplication {

private AuthenticationManager authenticationManager;

@Override
protected void init() {
super.init();
addComponentInstantiationListener(new
SpringComponentInjector(this));
getMarkupSettings().setCompressWhitespace(true);
getMarkupSettings().setStripComments(true);
getMarkupSettings().setStripWicketTags(true);
getRequestCycleSettings().setResponseRequestEncoding(UTF-8);

getResourceSettings().addResourceFolder(/WEB-INF/html/);
getResourceSettings().setResourceStreamLocator(new
CustomResourceStreamLocator());
getResourceSettings().setThrowExceptionOnMissingResource(false);

// mountBookmarkablePage(/register, RegistrationPage.class); 
// mountBookmarkablePage(/app, IndexPage.class);

mount(/app, PackageName.forPackage(IndexPage.class.getPackage()));

// mount(/register,
PackageName.forPackage(PeopleRegistrationPage.class.getPackage()));

}

@Override
public Class getHomePage() {
return IndexPage.class;
}

@Override
public Session newSession(Request request, Response response) {
return new SelfupdateAuthenticatedWebSession(this, request);
}

@Override
protected WebRequest newWebRequest(HttpServletRequest servletRequest) {
return new UploadWebRequest(servletRequest);
}

@Override
protected void setUpHive() {
//PolicyFileHiveFactory factory = new
PolicyFileHiveFactory(getActionFactory());  
PolicyFileHiveFactory factory = new
PolicyFileHiveFactory(getActionFactory());
try {
   
factory.addPolicyFile(getServletContext().getResource(/WEB-INF/policy/selfupdate.hive));
factory.setAlias(principal,
sg.sphsearch.auth.domain.Principal);
factory.setAlias(base,
sg.sphsearch.people.selfupdate.wicket);

//this application currently uses 1 policy file but you can add as
many as you like
//factory.addPolicyFile(...);
} catch (MalformedURLException e) {
throw new WicketRuntimeException(e);
}
HiveMind.registerHive(getHiveKey(), factory);
}

@Override
protected Object getHiveKey() {
return getServletContext().getContextPath();

}
@Override
public Class getLoginPage() {
 return LoginPage.class;
}
public LoginContext getLogoffContext() {
return new AcegiLoginContext();
}

@Override
public AuthenticationManager getAuthenticationManager() {
return authenticationManager;
}

public void setAuthenticationManager(final AuthenticationManager
authenticationManager) {
this.authenticationManager = authenticationManager;
}

@Override
public RequestCycle newRequestCycle(final Request request, final
Response response) {

return new WebRequestCycle((WebApplication) this, (WebRequest)
request, (WebResponse) response) {
@Override
public Page onRuntimeException(Page page, RuntimeException e) {
if (page == null) {
return new 

Re: AutoCompleteTextField: Making Wicket call getChoices method on 'onClick' event

2008-11-10 Thread bruno . borges
Take a look at the source code of AutoCompleteTextField and find out which  
JS method is called to display the list of choices.
Then from this point, you can use the onFocus javascript event  
(http://www.w3schools.com/jsref/jsref_onfocus.asp).


Cheers,
Bruno

On Nov 9, 2008 9:01pm, m_salman [EMAIL PROTECTED] wrote:



Hi,



I need some help with the AutoCompleteTextField. I would like it to show

the choice list when some one clicks in the field not just when the user

type a letter or two. I find that, atleast in my case, when I click on the

field getChoices method is not called.



I have tried some thing such as adding 'onClick' ajax event. But it does  

not


seem to work.



Below is my code and I will gretaly appreciate any help.



Thanks,



-Mohammad





private void addAutoCompleteTextField(

final PresenterParameterText presenter)

{

AutoCompleteSettings autoCompleteSettings = new AutoCompleteSettings();

autoCompleteSettings.setShowListOnEmptyInput(true);





final AutoCompleteTextField textField

= new AutoCompleteTextField(

value,

new PropertyModel(presenter, value),

autoCompleteSettings)

{

@Override

protected Iterator getChoices(String input)

{

List list;

try

{

//list = ..

//return list.iterator();

}

catch (Throwable t)

{

getRequestCycle().setRedirect(true);

throw new RestartResponseException(new ErrorPage(t));

}

}

};



add(textField);



textField.setOutputMarkupPlaceholderTag(true);

textField.add( new AjaxEventBehavior(onclick)

{

@Override

protected void onEvent(AjaxRequestTarget

target)

{

presenter.setValue();

target.addComponent(textField);



// How do I fire the event to call

the textFields getChoices method ???

}

});





}

--

View this message in context:  

http://www.nabble.com/AutoCompleteTextField%3A-Making-Wicket-call-getChoices-method-on-%27onClick%27-event-tp20411983p20411983.html


Sent from the Wicket - User mailing list archive at Nabble.com.





-

To unsubscribe, e-mail: [EMAIL PROTECTED]

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





Wicket Ajax doesn't work in Websynergy

2008-11-10 Thread Nayak Vishal

Hello,

Ajax works fine in Open portal. But it doesn't work in Websynergy.

Does anyone have any clue ? 


Regards
Vishal Nayak


ListItemMultipleChoice : How to get the selected values on submit

2008-11-10 Thread Nav Che
Hello All,

I have 2 listmultiplechoice components with AvailableUsers  SelectedUsers.
I had written a javascript to move the items from one listbox to another. (
Similar to palette ). ...But then onSubmit() I am not getting the selected
list values to remove or add to the selectedusers list. Could someone please
let me know if they have implemented the palette way using 2
listmultiplechoice components.

Thanks.

Naveen
PS : I know this was asked earlier but then there were no proper suggestions


Re: problem with PropertyModel and setDefaultFormProcessing(false) for button

2008-11-10 Thread itayh

Thank you all for all the help. Changing the type of the button to button
instead of submit fix that problem.

itayh wrote:
 
 The first line is actually name = item.getName(); there was a copy typo
 when I paste here the code. Any Idea?
 
 Pablo Abad wrote:
 
 Seems a typo either in the code you pasted or in your actual code, but
 shouldn't the first line be something like name = item.getName(); ?
 (gameItem -- item)
 On Tue, Oct 28, 2008 at 11:41 AM, itayh [EMAIL PROTECTED]
 wrote:
 
 protected void onEditItem(Item item) {
name = gameitem.getName();
addItemsForm.setVisible(true);
 }
   
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 
 

-- 
View this message in context: 
http://www.nabble.com/problem-with-PropertyModel-and-setDefaultFormProcessing%28false%29-for-button-tp20209348p20419618.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: IDataProvider and Session related data.

2008-11-10 Thread James Carman
First of all, the userid probably isn't much information (a string,
I'd imagine), so it sounds like you may be prematurely optimizing.
Anyway, you can always get the current session by doing:

MySession sess = (MySession)Session.get();





On Mon, Nov 10, 2008 at 4:23 PM, Graeme Knight [EMAIL PROTECTED] wrote:

 Hi.

 Just learning about IDataProvider and DataViews.

 I've scoped out the repeaters examples but this may be a little different...

 If I have a userId (for example stored in the Session) of the user as he is
 logged in and I wish to use that userId as a criteria for getting hold of
 the correct data using a IDataProvider (for a DataView list), then should I
 pass in the userID to the IDataProvider implementation and just store as a
 private variable?

 Is there a better way of getting hold of (or passing this) information into
 the IDataProvider implementation to limit storage/serialization?

 Many thanks, Graeme.
 --
 View this message in context: 
 http://www.nabble.com/IDataProvider-and-Session-related-data.-tp20428354p20428354.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



Re: IDataProvider and Session related data.

2008-11-10 Thread Jeremy Thomerson
In the data provider, you can do:
YourCustomSession.get().getUser().getID().  Then this doesn't have to be
serialized with the data provider, granted the cost will be very small.

-- 
Jeremy Thomerson
http://www.wickettraining.com

On Mon, Nov 10, 2008 at 3:23 PM, Graeme Knight [EMAIL PROTECTED] wrote:


 Hi.

 Just learning about IDataProvider and DataViews.

 I've scoped out the repeaters examples but this may be a little
 different...

 If I have a userId (for example stored in the Session) of the user as he is
 logged in and I wish to use that userId as a criteria for getting hold of
 the correct data using a IDataProvider (for a DataView list), then should I
 pass in the userID to the IDataProvider implementation and just store as a
 private variable?

 Is there a better way of getting hold of (or passing this) information into
 the IDataProvider implementation to limit storage/serialization?

 Many thanks, Graeme.
 --
 View this message in context:
 http://www.nabble.com/IDataProvider-and-Session-related-data.-tp20428354p20428354.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




Re: combining target.addComponent and javascript

2008-11-10 Thread Timo Rantalaiho
On Mon, 10 Nov 2008, Steve Swinsburg wrote:
 I am wanting to combine an AjaxRequestTarget addComponent call with a  
 javascript call as well so that the component is added to the page by  
 wicket, but displayed using a jQuery effect. The component adds to the  
 page fine, but the jQuery effect doesn't seem to be working, the  
 component just appears. Is it something to do with the order of when  
 its set to be visible/prepend/append javascript?

Do you have the normal markup of changePicture in the 
HTML?

You can check with the Ajax debug console (visible when 
running Wicket in development mode, -Dwicket.configuration=DEVELOPMENT) 
but I think that probably when you do this

   public void onClick(AjaxRequestTarget target) {
   
   //add the full changePicture component to the page 
   dynamically
   target.addComponent(changePicture);
   changePicture.setVisible(true);
   String js = $('# + changePicture.getMarkupId() +  
 ').fadeIn('slow');
   target.appendJavascript(js);
 
   }

making changePicture visible with normal Wicket ajax will
just write it normally in the DOM tree. Remember that the
Wicket invisibility is stronger than the Javascript
visibility in the sense that non-visible Wicket components
are not rendered at all (just a placeholder tag is outputted
if you set setOutputMarkupPlaceHolderTag(true)).

I think that in order to be able to make changePicture
visible via Javascript (that manipulates DOM objects), you
have to make it invisible but available on the DOM level,
i.e. set display: none either in the markup or via
Javascript before the fadeIn javascript.

It would be interesting to hear a working solution.

Best wishes,
Timo

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

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



PageLink or BookmarkablePageLink

2008-11-10 Thread David R Robison

Is there any advantage to using PageLink over BookmarkablePageLink? David

--

David R Robison
Open Roads Consulting, Inc.
103 Watson Road, Chesapeake, VA 23320
phone: (757) 546-3401
e-mail: [EMAIL PROTECTED]
web: http://openroadsconsulting.com
blog: http://therobe.blogspot.com
book: http://www.xulonpress.com/book_detail.php?id=2579







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



Re: PageLink or BookmarkablePageLink

2008-11-10 Thread bruno . borges

I don't think so. They have different purposes.

On Nov 10, 2008 7:50pm, David R Robison [EMAIL PROTECTED]  
wrote:

Is there any advantage to using PageLink over BookmarkablePageLink? David



--



David R Robison

Open Roads Consulting, Inc.

103 Watson Road, Chesapeake, VA 23320

phone: (757) 546-3401

e-mail: [EMAIL PROTECTED]

web: http://openroadsconsulting.com

blog: http://therobe.blogspot.com

book: http://www.xulonpress.com/book_detail.php?id=2579















-

To unsubscribe, e-mail: [EMAIL PROTECTED]

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





Size of session cache

2008-11-10 Thread David R Robison

Is there a convenient way to tell the size of user's session cache? David

--

David R Robison
Open Roads Consulting, Inc.
103 Watson Road, Chesapeake, VA 23320
phone: (757) 546-3401
e-mail: [EMAIL PROTECTED]
web: http://openroadsconsulting.com
blog: http://therobe.blogspot.com
book: http://www.xulonpress.com/book_detail.php?id=2579

This e-mail communication (including any attachments) may contain confidential and/or privileged material intended solely for the individual or entity to which it is addressed.  If you are not the intended recipient, you should immediately stop reading this message and delete it from all computers that it resides on. Any unauthorized reading, distribution, copying or other use of this communication (or its attachments) is strictly prohibited.  If you have received this communication in error, please notify us immediately.  









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



Re: IDataProvider and Session related data.

2008-11-10 Thread Graeme Knight

Hey guys,

Thanks! Being dumb I forgot about YourCustomSession.get().getUser().getID()
for the second time this week (and yes, its only Monday)

That totally answers my questions!

Cheers, Graeme.


Graeme Knight wrote:
 
 Hi. 
 
 Just learning about IDataProvider and DataViews.
 
 I've scoped out the repeaters examples but this may be a little
 different...
 
 If I have a userId (for example stored in the Session) of the user as he
 is logged in and I wish to use that userId as a criteria for getting hold
 of the correct data using a IDataProvider call to a database (for a
 DataView list), then should I pass in the userID to the IDataProvider
 implementation and just store as a private variable? 
 
 Is there a better way of getting hold of (or passing this) information
 into the IDataProvider implementation to limit storage/serialization?
 
 Many thanks, Graeme.
 

-- 
View this message in context: 
http://www.nabble.com/IDataProvider-and-Session-related-data.-tp20428354p20429027.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



mounts and resources

2008-11-10 Thread Craig Tataryn

If one were to mount a page like so:

mount(new QueryStringUrlCodingStrategy(foo/ 
HomePage.html,HomePage.class));


How would you go about having it so resources referenced in  
HomePage.html are relative to foo/ and not /?  So if there was an img  
src=images/myimage.jpg / inside HomePage.html, currently the server  
would get a request for context for webapp/images/myimage.jpg,  
whereas the goal is to have it requested as context of webapp/foo/ 
images/myimage.jpg.


Thought base href=foo// would do the trick, but it didn't seem to.


Craig.

--
Craig Tataryn
site: http://www.basementcoders.com/
podcast:http://feeds.feedburner.com/TheBasementCoders
irc: ThaDon on freenode #basementcoders, ##wicket, #papernapkin
im: [EMAIL PROTECTED], skype: craig.tataryn


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



Re: Re: AutoCompleteTextField and wicket 1.3.5

2008-11-10 Thread ulrik

IE 7


Bruno Borges wrote:
 
 Not really. What version of IE are you using?
 
 On Nov 10, 2008 2:19pm, ulrik [EMAIL PROTECTED] wrote:


 Is that a joke?





 Bruno Borges wrote:

 

  use firefox

 





 --

 View this message in context:  
 http://www.nabble.com/AutoCompleteTextField-and-wicket-1.3.5-tp20422758p20423025.html

 Sent from the Wicket - User mailing list archive at Nabble.com.





 -

 To unsubscribe, e-mail: [EMAIL PROTECTED]

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



 
 
 -
 Bruno Borges
 blog.brunoborges.com.br
 +55 21 76727099
 
 The glory of great men should always be
 measured by the means they have used to
 acquire it.
 - Francois de La Rochefoucauld
 

-- 
View this message in context: 
http://www.nabble.com/Re%3A-Re%3A-AutoCompleteTextField-and-wicket-1.3.5-tp20423114p20434192.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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