Re: Wicket localization in stateful pages

2013-11-17 Thread meduolis
Thanks for help,

I used this example to make localization work as I wanted:
http://www.wicket-library.com/wicket-examples-6.0.x/pub/?0

It does not reload page after setting new locale, so no new page version is
created and when you navigate back, using browser, locale stays the same.
Also I had to update all components to use dynamic models.




--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Back-button-issue-when-localizing-in-stateful-pages-tp4662260p4662461.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: DownloadLink and ProgressBar

2013-11-17 Thread Ernesto Reinaldo Barreiro
Do you want me to build a little example for this?


On Sat, Nov 16, 2013 at 7:59 PM, seyaw seidy...@gmail.com wrote:

 Thank you Ernesto for your prompt response.
 1. is okay.
 Then for 2. I suppose I start the thread from the onclick method of the
 ajax
 link. Can you explain a bit how to start the file genaration with a thread?
 and for 3. how to pol the server for the progress?

 Thank you very much



 --
 View this message in context:
 http://apache-wicket.1842946.n4.nabble.com/DownloadLink-and-ProgressBar-tp4662451p4662460.html
 Sent from the Users forum mailing list archive at Nabble.com.

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




-- 
Regards - Ernesto Reinaldo Barreiro


Re: DownloadLink and ProgressBar

2013-11-17 Thread seyaw
Dear Ernesto
Thank you very much for your help. Your comments were very helpful.
I solve the problem as you suggested with little modification
1. follow the reference you mention [1]
2. add AjaxLink that will generate a file

 add(new AjaxLink(download)
{
@Override
public void onClick(final AjaxRequestTarget target)
{

bar.start(target);

new Thread()
{
public void run()
{
generateFile
}.
3. add a progressbar (from wicketstuff) and on its onFinsh method, trigger
the file download

 Progress = new ProgressBar(progress, new ProgressionModel()
{

protected Progression getProgression()
{
return new Progression(progress);
}
})
{

protected void onFinished(AjaxRequestTarget target)
{
download.initiate(target, fileName);
}
progress.add(download)
add(progress)

My only problem now is I have to guess the progress of file genaration , to
be dispalyed on the progress bar

thank you very much




--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/DownloadLink-and-ProgressBar-tp4662451p4662463.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: DownloadLink and ProgressBar

2013-11-17 Thread Ernesto Reinaldo Barreiro
Create a class that implements Runnable. Find how to launch a runnable
(e.g. using a thread pool). Keep a reference to this runnable and use some
property of it to track progress. Use an AJAX timer to pol for this value.


On Sun, Nov 17, 2013 at 10:14 AM, seyaw seidy...@gmail.com wrote:

 Dear Ernesto
 Thank you very much for your help. Your comments were very helpful.
 I solve the problem as you suggested with little modification
 1. follow the reference you mention [1]
 2. add AjaxLink that will generate a file

  add(new AjaxLink(download)
 {
 @Override
 public void onClick(final AjaxRequestTarget target)
 {

 bar.start(target);

 new Thread()
 {
 public void run()
 {
 generateFile
 }.
 3. add a progressbar (from wicketstuff) and on its onFinsh method, trigger
 the file download

  Progress = new ProgressBar(progress, new ProgressionModel()
 {

 protected Progression getProgression()
 {
 return new Progression(progress);
 }
 })
 {

 protected void onFinished(AjaxRequestTarget target)
 {
 download.initiate(target, fileName);
 }
 progress.add(download)
 add(progress)

 My only problem now is I have to guess the progress of file genaration , to
 be dispalyed on the progress bar

 thank you very much




 --
 View this message in context:
 http://apache-wicket.1842946.n4.nabble.com/DownloadLink-and-ProgressBar-tp4662451p4662463.html
 Sent from the Users forum mailing list archive at Nabble.com.

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




-- 
Regards - Ernesto Reinaldo Barreiro


Enfocing INPUT field names to respect hCard formats

2013-11-17 Thread Arjun Dhar
http://microformats.org/wiki/hcard-input-examples#person_billing_shipping_input

To ensure browsers can Auto fill Input form fields for E-Commerce forms and
common fields. I want to ensure the fieldNames match this convention.

I tried a test class something like


..but it does not respect the input field provided; specially if the INput
field is Bound via CompoundPropertyModel. Say shippingAddress contains city.
Then the field is still named shippingAddress:city.

How best to overcome this so I can standardize my field Names via HTML.
I dont want to be writing HTML field names in Java code. That would suck.

thanks




-
Software documentation is like sex: when it is good, it is very, very good; and 
when it is bad, it is still better than nothing!
--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Enfocing-INPUT-field-names-to-respect-hCard-formats-tp4662465.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Setting Session timezone without using getClientInfo()

2013-11-17 Thread jchappelle
I have been googling and searching this forum and haven't found an answer to
my question so I'm hoping someone can help me.

I have dates stored in a database that are stored as UTC. The application
that stores the data has the -Duser.timezone=UTC property set. My users have
a timezone that is set in the database. So when they log in I would like to
be able to set the timezone on the user and have it reflected in DateLabel. 

I can write some specific components if I need. I wanted to check to see
what would be a best practice in this scenario. If there isn't a global way
to set this, then should I just create a bean property on my Session for
timeZone and have all my components look at that?

Thanks,

Josh



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Setting-Session-timezone-without-using-getClientInfo-tp4662466.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Enfocing INPUT field names to respect hCard formats

2013-11-17 Thread Igor Vaynberg
override getInputName() and return the string you want.

-igor

On Sun, Nov 17, 2013 at 5:21 AM, Arjun Dhar dhar...@yahoo.com wrote:
 http://microformats.org/wiki/hcard-input-examples#person_billing_shipping_input

 To ensure browsers can Auto fill Input form fields for E-Commerce forms and
 common fields. I want to ensure the fieldNames match this convention.

 I tried a test class something like


 ..but it does not respect the input field provided; specially if the INput
 field is Bound via CompoundPropertyModel. Say shippingAddress contains city.
 Then the field is still named shippingAddress:city.

 How best to overcome this so I can standardize my field Names via HTML.
 I dont want to be writing HTML field names in Java code. That would suck.

 thanks




 -
 Software documentation is like sex: when it is good, it is very, very good; 
 and when it is bad, it is still better than nothing!
 --
 View this message in context: 
 http://apache-wicket.1842946.n4.nabble.com/Enfocing-INPUT-field-names-to-respect-hCard-formats-tp4662465.html
 Sent from the Users forum mailing list archive at Nabble.com.

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


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



Wicket JQuery UI Datepicker

2013-11-17 Thread Dirk Wichmann
Hi all,

at the Moment I have trouble to configure the DatePicker from JQuery UI.
I have included com.googlecode.wicket-jquery-ui Version 6.12.0
The DatePicker is shown in the UI but Date is allways displayed as
11/08/2013 and I get the error date cannot converted
What is the trick to get it running??

Thanks in advance
Dirk

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



Advice for upgrading from an old version of Wicket

2013-11-17 Thread Scott Carpenter
Hi -- I've inherited a wicket site that was first developed four years ago.
It is running on version 1.4 and I've been asked to estimate an upgrade to
a more current version, and I was hoping to get some advice from this list
about gotchas and so on.

I've been working on the site for several months but consider myself a
newcomer to Wicket. That is, I haven't done a deep dive into learning the
framework yet. I've been updating things based on what I find in the
existing code base. So please forgive me my newbieness and let me know what
details would be helpful.

Furthermore, I'm a newcomer to Java web frameworks in general. There is
Spring and Hibernate involved with this thing, which I've also been able to
update based on the existing state of affairs. The backend is an Oracle
database.

Your thoughts and advice would be greatly appreciated.

Thank you!

Scott


Re: wicket library example, but with tabs

2013-11-17 Thread eostermueller
replying to self here.

Finally got this worked out here: 
https://github.com/eostermueller/wicket-librarywithtabs

This code is a copy of the wicket library example, but it displays the book
detail in 3 different tabs on a single page.

Would you all consider including it in the distribution of wicket examples? 
Other than the filter in web.xml, you'd just need to copy:

wicket-examples/src/main/java/org/apache/wicket/examples/librarywithtabs/

...from the above repo.

Thanks,
--Erik




--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/wicket-library-example-but-with-tabs-tp4662343p4662470.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Wicket JQuery UI Datepicker

2013-11-17 Thread Sebastien
Hi Dirk,

Thank to remind me that I definitely should add a sample for DatePicker's
pattern...
The Java date pattern differs from the jQuery UI one, so you have to make
sure both are matching:

For instance:
new DatePicker(date, dd.MM., new Options(dateFormat,
Options.asString(dd.mm.)));

jQuery UI doc: http://api.jqueryui.com/datepicker/

Best regards,
Sebastien.




On Sun, Nov 17, 2013 at 10:26 PM, Dirk Wichmann dir...@team-wichmann.dewrote:

 Hi all,

 at the Moment I have trouble to configure the DatePicker from JQuery UI.
 I have included com.googlecode.wicket-jquery-ui Version 6.12.0
 The DatePicker is shown in the UI but Date is allways displayed as
 11/08/2013 and I get the error date cannot converted
 What is the trick to get it running??

 Thanks in advance
 Dirk

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




Re: Enfocing INPUT field names to respect hCard formats

2013-11-17 Thread Arjun Dhar
Sir i get that, but what I'd like is that I supply the field name as an
attribute in the Comonent itself in the HTML and that is fed to
getInputName()  to return.

This way I can supply the names in HTML itself.
If you see


..am trying to derive the tag attribute name from the html and then
supplying it to:

But in getInputName is coming null

Overriding getInputName does work. However im trying to make it clean by
supplying the name via HTML.
thanks




-
Software documentation is like sex: when it is good, it is very, very good; and 
when it is bad, it is still better than nothing!
--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Enfocing-INPUT-field-names-to-respect-hCard-formats-tp4662465p4662475.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Image Tag Wicket Processing

2013-11-17 Thread arronlee
Hi, Thanks for your sharing. But I wonder whether there are some differences
between the  image processor
http://www.yiigo.com/guides/csharp/how-to-process-image.shtml   I am
testing about and the one you mentioned above?



Best regards,
Arron



-
Best Regards,
Arron



| Image Processing SDK  |


Next Tomorrow is Another Day.
--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Image-Tag-Wicket-Processing-tp3258703p4662476.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: problem dynamic image - explorer

2013-11-17 Thread arronlee
So I wonder which format is the one you prefer? PNG? BMP? I think you can
totally take it easy because there are so many conversion tools online for
users to choose from. I hope you success. Good luck.



Best regards,
Arron



-
Best Regards,
Arron



| Image Processing SDK  |


Next Tomorrow is Another Day.
--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/problem-dynamic-image-explorer-tp1849071p4662477.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Enfocing INPUT field names to respect hCard formats

2013-11-17 Thread Martin Grigorov
Hi,

I guess #getInputName() is called before #onComponentTag() where you set
the variable.
Try by using org.apache.wicket.Component#getMarkupAttributes in
#getInputName().


On Mon, Nov 18, 2013 at 7:45 AM, Arjun Dhar dhar...@yahoo.com wrote:

 Sir i get that, but what I'd like is that I supply the field name as an
 attribute in the Comonent itself in the HTML and that is fed to
 getInputName()  to return.

 This way I can supply the names in HTML itself.
 If you see


 ..am trying to derive the tag attribute name from the html and then
 supplying it to:

 But in getInputName is coming null

 Overriding getInputName does work. However im trying to make it clean by
 supplying the name via HTML.
 thanks




 -
 Software documentation is like sex: when it is good, it is very, very
 good; and when it is bad, it is still better than nothing!
 --
 View this message in context:
 http://apache-wicket.1842946.n4.nabble.com/Enfocing-INPUT-field-names-to-respect-hCard-formats-tp4662465p4662475.html
 Sent from the Users forum mailing list archive at Nabble.com.

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