Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread Sergey Olefir
As I briefly mentioned before, class aliases are, IMO, a terribly unreliable thing to maintain. Every time someone comes up with new component that uses resource reference they must not forget to go and register the alias for it. I'm predicting a 100% probability that soon enough someone will

Re: RE: How can i know when a users redirects to other page

2010-03-02 Thread Sergey Olefir
I'm not sure if session invalidation will be carried out if server stops/crashes. Although I think the session invalidation mechanism is still the most reliable of all that was proposed (my personal first reaction was you can't do it reliably -- although after reading the thread I have to agree

Re: FormTester and Select component?

2010-03-02 Thread Jan Eriksson
Thank you for the reply. Unfortunately this is not easier for me since we already have this function implemented using the Select component. If there is no way of getting FormTester to work with that component i'll have a look at your code - i really want to have this test automated without having

Re: RE: How can i know when a users redirects to other page

2010-03-02 Thread Ernesto Reinaldo Barreiro
just answered what he was asking;-). Another thing is if this is the best solution for the use case. Maybe another possibility is to have a background job that does clean unused files from time to time. Best, Ernesto On Tue, Mar 2, 2010 at 11:28 AM, Sergey Olefir solf.li...@gmail.com wrote:

Re: Re: FormTester and Select component?

2010-03-02 Thread Leo . Erlandsson
You could easily extend WicketTester and FormTester to support selecting in org.apache.wicket.extensions.markup.html.form.select.Select. Take a look at the public void select(String formComponentId, int index) method in FormTester and public FormTester newFormTester(String path, boolean

ListView + dynamic database Model

2010-03-02 Thread marioosh.net
Sorry for my poor english ;) I have ListView and model like below. I need tabs to reload sometimes, so my model is dynamic and get tabs from database. But i see that something is wrong. When i want to get Tab object by getModelObject() in populateItem method i suppoused that i got it directly,

Re: ListView + dynamic database Model

2010-03-02 Thread Thomas Kappler
On 03/02/10 11:55, marioosh.net wrote: Sorry for my poor english ;) I have ListView and model like below. I need tabs to reload sometimes, so my model is dynamic and get tabs from database. But i see that something is wrong. When i want to get Tab object by getModelObject() in populateItem

Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread bgooren
Sorry, I overlooked that part of your original post. I've been toying with the same idea, since class aliases are bound to cause problems as projects grow bigger. As long as the aliases are user-generated, they might not be unique. So I had a quick look at the source code of

Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread bgooren
Ok, scratch that comment too... I see Antoine dug up an old thread of yours where you already found out about the possibility to override WebRequestCodingStrategy. I also see that Antoine created WICKET-2731 and that it has been closed as resolved/fixed, so there should be some hooks available

Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread Sergey Olefir
Thing is, I already toyed with WebRequestCodingStrategy -- specifically I changed how resources are encoded by replacing URL path with URL parameter. And I broke CSS/relative references in the process as I found out much later :) (as you found out already in your another post ;)) Although if I

Need Help Wicket Stuff push

2010-03-02 Thread Stevenson Cunanan
I tried the wicket push chat example which i found at wicket stuff svn..wicket-stuff/wicketstuff-core/push-parent/push-examples I got the examples to work fine. Now I am trying to create something like a notification using TimerPushService. So i make 2 pages one for sending... and another for

Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread Antoine van Wel
A flag has been introduced that when set will throw an error when an fqn would be used. It will be in 1.4.7, which is currently in the voting phase, so it will be available within a week. But this would mean you'd have to alias all the classes anyway. Antoine On Tue, Mar 2, 2010 at 12:33 PM,

Re: color of message

2010-03-02 Thread Gw
OK, thx for your help, Cemal. Will try it right away... GBU On Tue, Feb 23, 2010 at 4:31 AM, Cemal Bayramoglu jweekend_for...@cabouge.com wrote: Mike, Use CSS. eg on feedback errors, Wicket puts class=feedbackPanelERROR Regards - Cemal jWeekend OO Java Technologies, Wicket Consulting,

Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread Sergey Olefir
Thanks for heads up. I guess it's back to hacking WebRequestCodingStrategy for me, the flag is better than nothing, but I'm not eager in having application crash in production because someone forgot to map something and somehow it slipped past testing. Antoine van Wel wrote: A flag has

Re: ListView + dynamic database Model

2010-03-02 Thread marioosh.net
Thomas Kappler-3 wrote: On 03/02/10 11:55, marioosh.net wrote: Sorry for my poor english ;) I have ListView and model like below. I need tabs to reload sometimes, so my model is dynamic and get tabs from database. But i see that something is wrong. When i want to get Tab object by

image from outside web application directory

2010-03-02 Thread Gw
Hi all, I'd like to know how to display an image which is located outside web application directory (eg: C:\images) . Many thanks in advance for your assists. Regards, Mike - To unsubscribe, e-mail:

Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread Martijn Dashorst
Create a unit test case that scans your application for resources and checks if the class is set. If not, fail. If set, check if it is unique, if not fail. Martijn On Tue, Mar 2, 2010 at 12:40 PM, Sergey Olefir solf.li...@gmail.com wrote: Thanks for heads up. I guess it's back to hacking

Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread Sergey Olefir
Err, I guess I don't quite understand what you're proposing... My understanding is that I need to know all class names that are used by application as part of ResourceReference (and possibly something else too). How would I scan for that? Martijn Dashorst wrote: Create a unit test case that

Re: image from outside web application directory

2010-03-02 Thread Ernesto Reinaldo Barreiro
Hi Mike, search the list this have been answered many time before. Best, Ernesto On Tue, Mar 2, 2010 at 12:46 PM, Gw not4spamm...@gmail.com wrote: Hi all, I'd like to know how to display an image which is located outside web application directory (eg: C:\images) . Many thanks in advance

Help with wicket stuff push

2010-03-02 Thread Stevenson Cunanan
Hi, I am trying to create a notify using the TimerPushService of wicket stuff push I want to send a message from 1 page and listen with another. from what i understand the basic, you need to add a listerner to poll for changes what I dont understand is what the line final IPushTarget pushTarget =

DownloadLink problem

2010-03-02 Thread Martin Asenov
Hi, guys! I experience some DownloadLink problem - I have these fields: File linkModel; DownloadLink theLink = new DownloadLink(link_id, new ModelFile(linkModel)); theLink.setOutputMarkupId(true); After another button click I have the linkModel field pointing to real file on the file system.

RE: RE: How can i know when a users redirects to other page

2010-03-02 Thread Martin Asenov
Hi, Ernesto! This is most likely the way I'll do the thing. I have a quartz scheduler and will arrange a recurring job that will clean files older than a day for instance. Thank you all! Best regards, Martin -Original Message- From: Ernesto Reinaldo Barreiro

Re: Need Help Wicket Stuff push

2010-03-02 Thread Stevenson Cunanan
On Tue, Mar 2, 2010 at 7:35 PM, Stevenson Cunanan stevenson.cuna...@gmail.com wrote: I tried the wicket push chat example which i found at wicket stuff svn..wicket-stuff/wicketstuff-core/push-parent/push-examples I got the examples to work fine. Now I am trying to create something like a

Re: autolink not work ?

2010-03-02 Thread marioosh.net
kinabalu wrote: Index1 and Index2 are generated as italics because you are on the same page. If you use autolink and you're on the same page, they show up as italics Index3 doesn't work because you've got a slash preceding the package name. And linkownia isn't one of the packages

Re: Ajax File Upload (Safari and Chrome)?

2010-03-02 Thread bgooren
Possibly this is related to http://issues.apache.org/jira/browse/WICKET-2657 WICKET-2657 ? That bug only mentions Chrome though, so it is unclear if it also occurs on Safari. Did you check if AjaxButton.onSubmit() gets called to isolate the problem area (server vs client)? Corbin, James-2

Re: DownloadLink problem

2010-03-02 Thread Ernesto Reinaldo Barreiro
Not sure... but could you try something like: DownloadLink downloadLink = new DownloadLink(link_id, new AbstractReadOnlyModelFile(){ public File getObject() { return this.linkModel; }; },myfile.xxx); downloadLink.setOutputMarkupId(true);

Re: Ajax File Upload (Safari and Chrome)?

2010-03-02 Thread Pierre Goupil
The link is broken, unfortunately: The project you are trying to view does not exist. Try browsing http://issues.apache.org/jira/browse for projects. Regards, Pierre On Tue, Mar 2, 2010 at 1:27 PM, bgooren b...@iswd.nl wrote: Possibly this is related to

Re: Ajax File Upload (Safari and Chrome)?

2010-03-02 Thread bgooren
Just perform a google search for WICKET-2657 in that case, or copy the following link http://issues.apache.org/jira/browse/WICKET-2657 Pierre Goupil wrote: The link is broken, unfortunately: The project you are trying to view does not exist. Try browsing

RE: DownloadLink problem

2010-03-02 Thread Martin Asenov
Unfortunately doesn't work this way... The model is never refreshed... -Original Message- From: Ernesto Reinaldo Barreiro [mailto:reier...@gmail.com] Sent: Tuesday, March 02, 2010 2:31 PM To: users@wicket.apache.org Subject: Re: DownloadLink problem Not sure... but could you try

Re: DownloadLink problem

2010-03-02 Thread James Carman
Use a LoadableDetachableModelFile? On Tue, Mar 2, 2010 at 8:24 AM, Martin Asenov mase...@velti.com wrote: Unfortunately doesn't work this way... The model is never refreshed... -Original Message- From: Ernesto Reinaldo Barreiro [mailto:reier...@gmail.com] Sent: Tuesday, March 02,

Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread Martijn Dashorst
Take a look at the spring component scanner for an implementation of how to search the class path. Then it is just a series of ResourceReference.class.isAssignableFrom(clz) queries and applying your specific logic. For example we use the following code to scan for specific patterns in html files

Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread Sergey Olefir
I admit I didn't research in-depth what you've suggested, but from the quoted piece it seems that your suggestion will find all subclasses of ResourceReference. But to actually test that all resources are properly mapped, it would be necessary to locate all invocations of the ResourceReference

Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread James Carman
You might also look into the scannotation project. On Tue, Mar 2, 2010 at 8:33 AM, Martijn Dashorst martijn.dasho...@gmail.com wrote: Take a look at the spring component scanner for an implementation of how to search the class path. Then it is just a series of

Re: DownloadLink problem

2010-03-02 Thread Ernesto Reinaldo Barreiro
Weird. Just try this example: import java.io.File; import org.apache.wicket.ajax.AjaxRequestTarget; import org.apache.wicket.ajax.markup.html.AjaxLink; import org.apache.wicket.markup.html.link.DownloadLink; import org.apache.wicket.markup.html.panel.Panel; import

Page Expired

2010-03-02 Thread Alexander Monakhov
Hi, guys. I've got problem with 'Page Expired' message. I'm developing application that is worked on GAE. It has one page with help content. There is two help pages. Help page contains two separated divs. One div for table of content, second - for content. When user clicks on link, page is

RE: DownloadLink problem

2010-03-02 Thread Martin Asenov
Thanks Ernesto! But I want to have the link invisible on startup (because the file's empty). So I have this: (doesn't work, but has to) exportedFileLink = new DownloadLink(exported_file_link, new LoadableDetachableModelFile() { private static final long serialVersionUID = 1L;

ResourceLink with pagerefresh(update)

2010-03-02 Thread Boydens Joeri (OZ)
Hello, I've created an ResourceLink wich shows the user a download window for the PDF resource. Now I want the page to be refreshed when the user clicks the link so I can update the page and show the user he clicked this link. How would I do this ? Regards Joeri

Re: image from outside web application directory

2010-03-02 Thread Riyad Kalla
Mike, The solution is writing a wicket component that finds the image on-disk and streams the bits back to the browser. Try these search results: http://old.nabble.com/forum/Search.jtp?forum=13974local=yquery=dynamic+image

validate

2010-03-02 Thread Ivan Dudko
Hello! I can't understand how can i validate ip address (e.g. 192.168.0.238) using UrlValidator. Thank you for help. Ivan Dudko - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail:

Re: Page Expired

2010-03-02 Thread Riyad Kalla
Alexander, Maybe this has to do with the persistence store you are using to make Wicket work on GAE not actually persisting your pages to a location that they can be retrieved again? I know by default the DiskStore that Wicket uses won't work on GAE, so I imagine you plugged something else in --

Re: validate

2010-03-02 Thread Martijn Dashorst
Why do you want to use a UrlValidator? An ip-address is not a URL? Maybe a pattern validator with http://www.regular-expressions.info/regexbuddy/ipaccurate.html would be better? Martijn On Tue, Mar 2, 2010 at 4:09 PM, Ivan Dudko ivan.du...@gmail.com wrote: Hello! I can't understand how can i

Re: validate

2010-03-02 Thread Ivan Dudko
For this expression \b(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\b eclipse says: invalid escape sequence 2010/3/2 Martijn Dashorst martijn.dasho...@gmail.com: Why do you want to use a UrlValidator? An ip-address is not a URL? Maybe a pattern

Re: validate

2010-03-02 Thread Riyad Kalla
If you have that string literally copy-pasted in some Java code somewhere, you need to double escape the escape chars... \\b and so on. On Tue, Mar 2, 2010 at 8:32 AM, Ivan Dudko ivan.du...@gmail.com wrote: For this expression

Re: Page Expired

2010-03-02 Thread Alexander Monakhov
Hi. I'm using org.apache.wicket.protocol.http.HttpSessionStore. Guess it's not cause, because other links from other pages work well. Best regards, Alexander.

Re: validate

2010-03-02 Thread Ivan Dudko
Thanks a lot! 2010/3/2 Riyad Kalla rka...@gmail.com: If you have that string literally copy-pasted in some Java code somewhere, you need to double escape the escape chars... \\b and so on. On Tue, Mar 2, 2010 at 8:32 AM, Ivan Dudko ivan.du...@gmail.com wrote: For this expression

Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread Sergey Olefir
bgooren wrote: So I had a quick look at the source code of WebRequestCodingStrategy, and I think it should be possible to create a solution for your problem quite easily: Thanks to your idea, I played around with WebRequestCodingStrategy and below is what I came up with. It uses

CompoundPropertyModel issue

2010-03-02 Thread chinedu efoagui
hello, i am added a dropdownchoice to a form. The form's model is set to a CompoundPropertyModel as shown below IModel zaModel=new CompoundPropertyModel(selected); leaveform.setModel(zaModel); Now the dropdown shows a list of Employees EmployeeDropDownChoice approvalofficers=new

[newbie] Wicket, Spring, Hibernate and transactions in views.

2010-03-02 Thread Colin Rogers
All, I've got a bit of a newbie Wicket question involving Spring, Hibernate and transactions. The question that I can't seem to find an answer to; Can a view be a created/injected/aop'd like a spring bean so that it honours @Transactional methods for hibernate? An example;

Re: How to encrypt/obfuscate resource reference?

2010-03-02 Thread bgooren
Good to know I contributed something useful to this thread haha. The code looks like the stuff I had in mind. You gotta love Wicket for making it quite easy to do this stuff; Although the URL encoding/decoding can be quite complex for beginners, but that is likely to be fixed in the future

Re: CompoundPropertyModel issue

2010-03-02 Thread Xavier López
I think the Model you are passing to the constructor refers to the choices Model. Try using EmployeeDropDownChoice(approvaloficer,new Model(), new Model()); Cheers, Xavier 2010/3/2 chinedu efoagui chinedub...@gmail.com hello, i am added a dropdownchoice to a form. The form's model is set to

RE: DownloadLink problem

2010-03-02 Thread Martin Asenov
Oh my God!!! The problem was that the button that is supposed to do the export was of type submit and it reloads the page, instead of refreshing components. I changed to type=button and everything's fine... As people say - there is no patch for human stupidity... Thank you all for the help!

Re: DownloadLink problem

2010-03-02 Thread Riyad Kalla
Martin, If it makes you feel any better, it would have been a week or longer before I thought to change that, good fine :) -R On Tue, Mar 2, 2010 at 9:32 AM, Martin Asenov mase...@velti.com wrote: Oh my God!!! The problem was that the button that is supposed to do the export was of type

Re: [newbie] Wicket, Spring, Hibernate and transactions in views.

2010-03-02 Thread Pedro Sena
I don't think so. I'd recommend you to make your transactional control in your services and call them from your pages instead of trying to control it in your view. Best Regards, On Tue, Mar 2, 2010 at 1:25 PM, Colin Rogers coli...@groundsure.com wrote: All, I've got a bit of a newbie

RE: [newbie] Wicket, Spring, Hibernate and transactions in views.

2010-03-02 Thread Colin Rogers
I'd recommend you to make your transactional control in your services and call them from your pages instead of trying to control it in your view. I'd agree in terms of good design, but I'm coding something for myself - and I'm trying to make it easy and as little time consuming as possible. So,

RE: [newbie] Wicket, Spring, Hibernate and transactions in views.

2010-03-02 Thread Josh Chappelle
If you aren't concerned with good design then I wouldn't worry about transactions at all. Especially if you are doing read only data retrieval. Once you get the code working the way you want you can always add transactions later and refactor the code into your service methods. That's the agile

Re: [newbie] Wicket, Spring, Hibernate and transactions in views.

2010-03-02 Thread Riyad Kalla
I'm not DB expert, but why are you using transactions for read only (SELECTs) queries? I've only ever seen transactions used to wrap INSERT/UPDATE/DELETE statements (writes) -R On Tue, Mar 2, 2010 at 9:46 AM, Colin Rogers coli...@groundsure.com wrote: I'd recommend you to make your

RE: DownloadLink problem

2010-03-02 Thread Martin Asenov
It doesn't... :-) Thank you anyway! :-) -Original Message- From: Riyad Kalla [mailto:rka...@gmail.com] Sent: Tuesday, March 02, 2010 6:35 PM To: users@wicket.apache.org Subject: Re: DownloadLink problem Martin, If it makes you feel any better, it would have been a week or longer before

wiQuery components with server side state - live demo

2010-03-02 Thread Cemal A Bayramoglu
We've been building a few wiQuery components [0], for clients' and internal projects. These wiQuery components typically maintain some of their state server-side, in the spirit of standard Wicket components. Here's a simple demo [1] to show some of them in action. Look carefully and you'll find

add attributes to options elements within a palette

2010-03-02 Thread wic...@geofflancaster.com
Is it possible to add attributes to elements within a palette? I'd like to assign the title attribute so i can have tooltips. mail2web.com – What can On Demand Business Solutions do for you?

RE: [newbie] Wicket, Spring, Hibernate and transactions in views.

2010-03-02 Thread Colin Rogers
I'm not DB expert, but why are you using transactions for read only (SELECTs) queries? If you aren't concerned with good design then I wouldn't worry about transactions at all Because you need the transactions for lazy fetching of child elements in hibernate. -Original Message- From:

Wicket button label

2010-03-02 Thread Metzger, Natalie J.
Hi all, I'm comparatively new to Wicket and have a question about the wizard button labels. I'm using a Wizard with an AjaxButtonBar and AjaxButtons for previous and next. I would like to change the labels on the last step of the wizard of the cancel and finish buttons. I know how to change

Re: [newbie] Wicket, Spring, Hibernate and transactions in views.

2010-03-02 Thread Pedro Santos
Consider to use OpenSessionInViewFilter http://static.springsource.org/spring/docs/1.2.9/api/org/springframework/orm/hibernate3/support/OpenSessionInViewFilter.html The doc: Intended for the Open Session in View pattern, i.e. to allow for lazy loading in web views despite the original

Re: wiQuery components with server side state - live demo

2010-03-02 Thread Roman Ilin
Great, ready for use components. On Tue, Mar 2, 2010 at 5:58 PM, Cemal A Bayramoglu ce...@jweekend.com wrote: We've been building a few wiQuery components [0], for clients' and internal projects. These wiQuery components typically maintain some of their state server-side, in the spirit of

RE: [newbie] Wicket, Spring, Hibernate and transactions in views.

2010-03-02 Thread Colin Rogers
Thats exactly what I am using, but it doesn't seem to work. I've set up as per the original posts tutorial (that includes OpenSessionInViewFilter). The log below show me calling it - and supposedly opening the transaction (although it does do everything twice); 2010-03-02 17:19:08.690::INFO:

Re: [newbie] Wicket, Spring, Hibernate and transactions in views.

2010-03-02 Thread James Carman
Introduce AspectJ and spring-aspects into your build. You can see an example of it in my wicket-advanced sample project: http://svn.carmanconsulting.com/public/wicket-advanced/trunk/ Then, AspectJ will weave the transaction support into your Page/Component classes like you want. There are

Re: Wicket button label

2010-03-02 Thread Riyad Kalla
Natalie, What have you tried thus far to change the label? Another approach might be to set the visibility on the CancelButton to false and true on another FinishButton and then refresh the whole button bar to paint that state for the last panel? -R On Tue, Mar 2, 2010 at 10:09 AM, Metzger,

Bookmarkable root page with PageParameters

2010-03-02 Thread Anthony DePalma
I added a bookmarkablePagingNavigator to my page to enhance seo, and when the homepage was bound to the context '/stories', it worked very well (http://www.luckeffect.com/stories/page/1). However I wanted to remove the stories context so the homepage was bound directly to the root, and now it

Re: Bookmarkable root page with PageParameters

2010-03-02 Thread Riyad Kalla
I *thought* I recall this being a known issue that will be addressed in 1.5 with some of the new bookmarkable work? On Tue, Mar 2, 2010 at 1:38 PM, Anthony DePalma fatef...@gmail.com wrote: I added a bookmarkablePagingNavigator to my page to enhance seo, and when the homepage was bound to the

Re: wiQuery components with server side state - live demo

2010-03-02 Thread Vladimir K
Looks great! One thing is missing - the components don't restore their state on refresh. I believe cookie, window name or dom storage can be used to keep the position and settings of components that are available for dragging/re-arrangement. Roman Ilin wrote: Great, ready for use

Re: wiQuery components with server side state - live demo

2010-03-02 Thread John Armstrong
Wow, this is fantastic. Wish I'd had it 4 months ago before I had to start dealing with GXT for its grid support :( We'll pick it up for our next project if possible, its exactly what we need. Nice stuff guys. John- PS : RowExpanders would be awesome ;) On Tue, Mar 2, 2010 at 3:10 PM,

Extended Form Question

2010-03-02 Thread Josh Chappelle
Hi, I have extended the Form component to include a visitor that adds some behaviors to required fields so that the validation errors are rendered next to the corresponding fields. My problem is that I have a form that has a form level validator that is not specific to a component. So I still

Re: Extended Form Question

2010-03-02 Thread James Carman
You would instantiate your FeedbackPanel with an IFeedbackMessageFilter: http://wicket.apache.org/docs/1.4/org/apache/wicket/feedback/IFeedbackMessageFilter.html Perhaps you would check to see if the form itself is the reporter of the message? On Tue, Mar 2, 2010 at 9:54 PM, Josh Chappelle

Re: Dynamic Generation of wicket Screen

2010-03-02 Thread sravang
Didn't understand. pls explain me. MartinM wrote: Hi! You can always use: field = new Field(...) { @Override public boolean isVisible() { return showIfVisible; } } ** Martin 2010/3/3 sravang sravangs...@gmail.com: Thank u for your reply. I will explain my

Re: Dynamic Generation of wicket Screen

2010-03-02 Thread Martin Makundi
Show me a code snipplet of component that you want to hide or show conditionally. I will do the same for that component. ** Martin 2010/3/3 sravang sravangs...@gmail.com: Didn't understand. pls explain me. MartinM wrote: Hi! You can always use: field = new Field(...) {   �...@override