Re: Problem making Panel visible using AJAX
http://google.com/search?q=wicket+ajax+visible On Sat, Jul 12, 2008 at 12:44 AM, vishy_sb [EMAIL PROTECTED] wrote: Hi all, I have a page where I have put an AjaxFallBackButton() and also have a Panel on it. I want to make the panel visible or invisible by clicking the button. Kindly refer to the code below: //Code for the TestPage public TestPage() { Form form = new Form(form); add(form); button = new AjaxFallbackButton(button, form) { private static final long serialVersionUID = 1L; @Override protected void onSubmit(AjaxRequestTarget target, Form form) { target.addComponent(testPanel); testPanel.setVisible(!testPanel.isVisible()); } }; form.add(button); testPanel = new TestPanel(testPanel); form.add(testPanel); testPanel.setOutputMarkupId(true); } //Code for the Panel public TestPanel(String id) { super(id); add(new Label(testPanel, Testing New Panel)); } The problem is that when I click the button, the Panel becomes invisible. However when I click it again the panel doesn't show up until or unless the entire page is refreshed. I am newbie to Wicket and I know I am making a basic mistake but I havn't been able to figure this out. Kindly let me know where I am going wrong. Thank in advance!!! vishy -- View this message in context: http://www.nabble.com/Problem-making-Panel-visible-using-AJAX-tp18413807p18413807.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] -- Become a Wicket expert, learn from the best: http://wicketinaction.com Apache Wicket 1.3.4 is released Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Hiding table columns in DataViews?
See DataTable and friends. Martijn On Sat, Jul 12, 2008 at 4:19 AM, Michael Mehrle [EMAIL PROTECTED] wrote: I build a table like this: table width=100% cellpadding=0 cellspacing=0 border=0 tr td class=pad5 bldwicket:message key=dateTitle//td tdwicket:message key=timeTitle//td tdwicket:message key=statusTitle//td tdnbsp;/td /tr tr wicket:id=recurringEvents td wicket:id=date class=grytop pad5[Date]/td td wicket:id=time class=grytop[Time]/td td wicket:id=status class=grytop[Status]/td td a wicket:id=replyNow class=guestlinkspan wicket:id=reply //anbsp;/td /tr /table Now, there are certain columns I need to hide in certain circumstances. I have no problem hiding the 'content' of certain columns by setting the particular value to empty in my dataprovider. However, I would like to hide the entire column including the header - how can that be done? Thanks! Michael -- Become a Wicket expert, learn from the best: http://wicketinaction.com Apache Wicket 1.3.4 is released Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Totally new to Wicket and planning on using Wicket 1.4
Hi, I've seen some examples of using Wicket and I must say it looks nice, clean and simple. I do have some questions I was hoping someone could answer. I just thought I'd ask about which is the preferred way of learning Wicket 1.4? Personally I've always been a fan of getting a good book, reading it and doing the examples/exercises. As there are only three books published on Wicket, and two of them relates to Wicket 1.3, I'm wondering if there are lots of differences between 1.3 and 1.4 and if I should wait for an updated book? There was some (old) posts about memory problems. I'm planning to write an application which will have roughly 1000 users, the application is pretty simple and they mostly input text into forms and view text from the database. In other words, there won't be much application logic. I was wondering about the current state of Wicket when it comes to performance in terms of CPU and memory usage? How does it compare to using plain Servlets+JSP and how does it compare to JSF? One of the things I liked about the Wicket examples was their simplicity and that it felt you as a developer was in total control of what's going in the output which the client reads. I saw that there are AJAX components now, and I'm wondering when/if I should use them? I was planning to use the JavaScript library jQuery for dynamic content. But when it comes to fetching/posting XML from/to the server that sort of interaction might be best suited for the native components? What I'm afraid of is some sort of situation where I do not control the output as much any more. Should I use Wicket 1.4 instead of 1.3? Lastly I'm wondering about Maven2. I looked at it a while ago but it seemed too complex for me wanting to learn it. Are both ways of retrieving Wicket equal or is there any reason to prefer one of them (maven2/normal jar-download) for me as a user? Thanks for reading my post! Best regards, Kent - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Totally new to Wicket and planning on using Wicket 1.4
2008/7/12 Kent Larsson [EMAIL PROTECTED]: I just thought I'd ask about which is the preferred way of learning Wicket 1.4? Personally I've always been a fan of getting a good book, reading it and doing the examples/exercises. As there are only three books published on Wicket, and two of them relates to Wicket 1.3, I'm wondering if there are lots of differences between 1.3 and 1.4 and if I should wait for an updated book? It's well worth picking up a copy of Wicket in Action. There is basically no difference between 1.3 and 1.4 apart from the addition of generics. Updating a 1.3 project to use 1.4 is therefore really trivial. I'd get a copy of Wicket in Action, have a play around with Wicket 1.3, then maybe try out Wicket 1.4M2 if you're keen to see the direction things are going in. Bear in mind it's a pre-release version and things may change. Don't wait for an updated book. Firstly there's no point. Secondly you'll probably be waiting a little while - the first edition of WIA has only recently come off the presses. There was some (old) posts about memory problems. I'm planning to write an application which will have roughly 1000 users, the application is pretty simple and they mostly input text into forms and view text from the database. In other words, there won't be much application logic. I was wondering about the current state of Wicket when it comes to performance in terms of CPU and memory usage? How does it compare to using plain Servlets+JSP and how does it compare to JSF? 1000 users? Or 1000 simultaneous users? The latter is obviously the more important metric. The short answer is to try it and see, and do some load-testing so you know how your app will behave if it suddenly gets swamped with traffic. People successfully use Wicket on much larger scale sites than that. People worry far too much about performance, far too early, usually with no good reason. You sound like one of these people. Write it, test it, tweak it, in that order. There are tools in Wicket to optimise things (stateless pages, etc.) so you can achieve the same kind of level of performance and scalability as raw servlets if you need it. One of the things I liked about the Wicket examples was their simplicity and that it felt you as a developer was in total control of what's going in the output which the client reads. I saw that there are AJAX components now, and I'm wondering when/if I should use them? I was planning to use the JavaScript library jQuery for dynamic content. But when it comes to fetching/posting XML from/to the server that sort of interaction might be best suited for the native components? What I'm afraid of is some sort of situation where I do not control the output as much any more. AJAX in Wicket is generally trivial to implement using the built-in support. You're obviously not far enough down the road here for me to say much more. Look at some of the AJAX examples to see how things work. You probably don't need control in the way you think you do, Wicket will likely take care of most of it for you without you ever having to write a line of JavaScript. Should I use Wicket 1.4 instead of 1.3? You already asked this. See above. Lastly I'm wondering about Maven2. I looked at it a while ago but it seemed too complex for me wanting to learn it. Are both ways of retrieving Wicket equal or is there any reason to prefer one of them (maven2/normal jar-download) for me as a user? It doesn't really make any difference. Maven 2 will make your life slightly easier - it's quicker and easier to upgrade your project between versions, easier to add Spring or whatever. Most people really like it and won't go back once they've started using it. It's really not very hard to use. For example, see here: http://herebebeasties.com/2007-10-07/wicket-quickstart/(although it's become easier since then - there's a copy/paste widget on the wicket web site to generate the command line for the archetype stuff now). Q4E is good if you're using Eclipse with it. Best regards, Alastair
Re: Reading files
2008/7/11 David Nedrow [EMAIL PROTECTED]: Here's what I've have... IResourceStream resStream = new PackageResourceStream(WicketApplication.class, protocols.csv); InputStream inStream = resStream.getInputStream(); InputStreamReader isr = new InputStreamReader(inStream); ListString[] protocolList = new CSVReader(isr).readAll(); inStream.close(); You don't need to involve Wicket in this. Reader reader = new InputStreamReader(WicketApplication.class.getResourceAsStream(protocols.csv)); ListString[] protocolList = new CSVReader(reader).readAll(); reader.close(); Regards, Al
Re: Regarding getting html checkbox values?
On Fri, 11 Jul 2008, Edi wrote: in the same page, i have wicket AjaxLink delete Button. during the delete button clicking, i want to get the checked checkbox values in the same page? is it possible? if yes, please advise. Yes, with either a submit component or by adding an AjaxFormSubmitBehavior to your AjaxLink. Best wishes, Timo -- Timo Rantalaiho Reaktor Innovations OyURL: http://www.ri.fi/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Totally new to Wicket and planning on using Wicket 1.4
On Sat, Jul 12, 2008 at 10:37 AM, Alastair Maw [EMAIL PROTECTED] wrote: 2008/7/12 Kent Larsson [EMAIL PROTECTED]: I'd get a copy of Wicket in Action, have a play around with Wicket 1.3, then maybe try out Wicket 1.4M2 if you're keen to see the direction things are going in. Bear in mind it's a pre-release version and things may change. 1.4m3 is just out, waiting for the mirrors to catch up. M3 is much more in the way we like generics to be heading. Don't wait for an updated book. Firstly there's no point. Secondly you'll probably be waiting a little while - the first edition of WIA has only recently come off the presses. We won't be able to update WIA for a long time though. Our wives won't let us. Martijn -- Become a Wicket expert, learn from the best: http://wicketinaction.com Apache Wicket 1.3.4 is released Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
LocaleUrlsEncodingStrategy ?
Hi Im trying to get locale prepended to every url in the application. I need this to be able to cache my pages. However it does not work, I get an request not found when I hit one of the encoded pages: forexample: /da/products Should actually just be the same as : /products Because of the way wicket handles locale, it's only for the cache's sake... Whats wrong with my approach, the code are below link. http://papernapkin.org/pastebin/view/1635/ -- -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 1.4 - Localizer getCacheKey BUG
Hi, I migrate my app from wicket 1.3 to wicket 1.4. Everything works fine, but one thing behaves strange. I have BasePage and all others pages in my app extends this page. BasePage have some responsibilities and one of them is set correct page title. Example: public class BasePage ext WebPage { public BasePage() { add(new Label(title, getTitle())); } protected IModel getTitle() { return new ResourceModel(pageTitle); } } All pages, which extends BasePage need to define properties file with key pageTitle if want to declare own page title. In Wicket 1.3 everythigs works correct, but in Wicket 1.4 NOT. The problem is in constructing CacheKey for localizer's properties cache. In Wicket 1.3 CacheKey containts: 1. component.getPageRelativePath() 2. component.findPage() - page.getClass().getName() There is all suffcient information for correct cashing properties. But in Wicket 1.4 it changed and page class name missed in constructing CacheKey. CacheKey containts: 1. resourceKey 2. component class name 3. component id 4. locale 5. style Result : If page identifier missed, title on my pages are still same, they are cached. Reason is that CacheKey is same for all my pages, although they contains properties file with own declared pageTitle. CacheKey is: pageTitle-org.apache.wicket.markup.html.basic.Label:title-en_EN-null This CacheKey is same for Page1, Page2, Page3 because it don't care about page. What are you think about it? Thanks -- View this message in context: http://www.nabble.com/wicket-1.4---Localizer-getCacheKey-BUG-tp18421093p18421093.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 1.4 - Localizer getCacheKey BUG
should be fixed in m3 which is coming out any hour -igor On Sat, Jul 12, 2008 at 9:07 AM, FakeBoy [EMAIL PROTECTED] wrote: Hi, I migrate my app from wicket 1.3 to wicket 1.4. Everything works fine, but one thing behaves strange. I have BasePage and all others pages in my app extends this page. BasePage have some responsibilities and one of them is set correct page title. Example: public class BasePage ext WebPage { public BasePage() { add(new Label(title, getTitle())); } protected IModel getTitle() { return new ResourceModel(pageTitle); } } All pages, which extends BasePage need to define properties file with key pageTitle if want to declare own page title. In Wicket 1.3 everythigs works correct, but in Wicket 1.4 NOT. The problem is in constructing CacheKey for localizer's properties cache. In Wicket 1.3 CacheKey containts: 1. component.getPageRelativePath() 2. component.findPage() - page.getClass().getName() There is all suffcient information for correct cashing properties. But in Wicket 1.4 it changed and page class name missed in constructing CacheKey. CacheKey containts: 1. resourceKey 2. component class name 3. component id 4. locale 5. style Result : If page identifier missed, title on my pages are still same, they are cached. Reason is that CacheKey is same for all my pages, although they contains properties file with own declared pageTitle. CacheKey is: pageTitle-org.apache.wicket.markup.html.basic.Label:title-en_EN-null This CacheKey is same for Page1, Page2, Page3 because it don't care about page. What are you think about it? Thanks -- View this message in context: http://www.nabble.com/wicket-1.4---Localizer-getCacheKey-BUG-tp18421093p18421093.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: LocaleUrlsEncodingStrategy ?
hi nino, Because of the way wicket handles locale, it's only for the cache's sake... Whats wrong with my approach, the code are below link. http://papernapkin.org/pastebin/view/1635/ i haven't really looked at your code, but i'd use an approach with a modified filter to handle this. there was a thread on a similar topic some time ago: http://www.nabble.com/Localization%2C-Bookmarkable-pages%2C-and-mounting-strategies-to16676213.html#a16682606 best regards, --- jan. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: LocaleUrlsEncodingStrategy ?
Thanks for the quick response, i'll look into that. Jan Kriesten wrote: hi nino, Because of the way wicket handles locale, it's only for the cache's sake... Whats wrong with my approach, the code are below link. http://papernapkin.org/pastebin/view/1635/ i haven't really looked at your code, but i'd use an approach with a modified filter to handle this. there was a thread on a similar topic some time ago: http://www.nabble.com/Localization%2C-Bookmarkable-pages%2C-and-mounting-strategies-to16676213.html#a16682606 best regards, --- jan. - 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]
Re: LocaleUrlsEncodingStrategy ?
did you have a java version of the filter also? I guess Sebastian has it? Jan Kriesten wrote: hi nino, Because of the way wicket handles locale, it's only for the cache's sake... Whats wrong with my approach, the code are below link. http://papernapkin.org/pastebin/view/1635/ i haven't really looked at your code, but i'd use an approach with a modified filter to handle this. there was a thread on a similar topic some time ago: http://www.nabble.com/Localization%2C-Bookmarkable-pages%2C-and-mounting-strategies-to16676213.html#a16682606 best regards, --- jan. - 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]
Re: LocaleUrlsEncodingStrategy ?
hi nino, did you have a java version of the filter also? I guess Sebastian has it? no, i switched completely to scala, sorry. maybe sebastian has implemented it in java. best regards, --- jan. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
modalWindow disable drag drop?
Hi Users, Is there a way to make the modalWindow unmovable? (disable the drag and drop?). Thanks, Allan -- The only constant in life is change. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Localization for table component
Hello, I have a page with a table component on it. I use the following keys to localize it and it works great datagrid.no-records-found NavigatorLabel On the same page I define a div which is a modal window. On the modal window I have another table component which I want to localize (with different text messages). My problem is that although I define another properties file with the name of the (modal window) panel, the properties are still read from the page properties file. How can I do what I'm looking for? Tks, Cristi Manole