Re: Wicket / Liferay help
Yes I had success. I obtained the jar wicket-portlet-1.5.7.2.jar and added it to my local repo. $MVN_CMD install:install-file \ -DgroupId=org.apache.wicket.portlet \ -DgeneratePom=true \ -DartifactId=wicket-portlet \ -Dversion=1.5.7.2 \ -Dpackaging=jar \ -Dfile=wicket-portlet-1.5.7.2.jar Make sure your pom has the following entries: 1.5.7 7.5.0.v20110901 javax.portlet portlet-api 2.0 provided org.apache.wicket wicket-core ${wicket.version} org.apache.wicket wicket-extensions ${wicket.version} org.apache.portals.bridges portals-bridges-common 2.0 org.apache.wicket.portlet wicket-portlet 1.5.7.2 I followed the naming convention of naming convention outlined on the Wicket Wiki. With Liferay 6.1.1, I also had to include WEB-INF/liferay-plugin-package.properties and add liferay-web-xml-enabled=false If need be I can send my quick start / test app so you can see. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-Liferay-help-tp4651140p4651289.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: Portlet / ServetWebRequest / WICKET-4387 fix - Introduced a bug???
Closure on this one. Peter Pastrnak did indicate that there was a bug with the "latest" distribution. There is a fix that will be available in the next release from my understanding. Peter did send me the updated files and I confirmed that it did fix my issue. Thanks Peter! -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Portlet-ServetWebRequest-WICKET-4387-fix-Introduced-a-bug-tp4651153p4651159.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
Portlet / ServetWebRequest / WICKET-4387 fix - Introduced a bug???
Troubleshooting my issue where my portlet won't work upon a page refresh, I came across this in ServletWebRequest. if (forwardAttributes != null || errorAttributes != null) { if (LOG.isDebugEnabled()) { LOG.debug("Setting filterPrefix('{}') to '' because there is either an error or a forward. {}, {}", new Object[] {filterPrefix, forwardAttributes, errorAttributes}); } // the filter prefix is not needed when the current request is internal // see WICKET-4387 this.filterPrefix = ""; <<< HERE } else { this.filterPrefix = filterPrefix; } This results in not creating the proper URLs for standard resource classes such as wicket-ajax.js. The filterPrefix is needed to load the resources. When actually set to this.filterPrefix = filterPrefix; My portlet works as expected. Any idea how to work around this as this is wicket core? Can this code check if in a portal and not clear out this value? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Portlet-ServetWebRequest-WICKET-4387-fix-Introduced-a-bug-tp4651153.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 / Liferay help
Here is the generated HTML code that is being sent to the browser. What I had commented above was the resulting HTTP request. But this may shed some light on why that url is being called. The portlet-name, wicketFilterPath, and filter-mapping/url-pattern are set to wickettest. However I don't see the portlet references in the above script call. Here is my web.xml: org.apache.wicket.detectPortletContext true wickettest org.apache.wicket.portlet.PortletFilter applicationClassName com.apolloglobal.WicketApplication detectPortletContext true filterMappingUrlPattern /wickettest/* wickettest /wickettest/* REQUEST INCLUDE FORWARD Here is my portlet.xml: Wicket Test wickettest Wicket Test org.apache.wicket.portlet.WicketPortlet wicketFilterPath /wickettest viewPage /wickettest text/html VIEW */* VIEW Wicket Test Wicket Test Is there anything that stands out why this is not behaving properly on a page refresh? It appears that Wicket is not getting the indication that it is in a portlet and generating the proper URL to reference the resource. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-Liferay-help-tp4651140p4651152.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 / Liferay help
Got my portlet to show up in the Portal. Had my liferay-portlet.xml incorrect. But there weren't any errors. Now I have a weird situation. I can add the portlet to my page and it works. I do a page refresh and now it won't. I was able to track down at least why it is not. But I don't know how to fix it. The issue is the resulting URL that is generated for calls for the portlet. This works: (just added to the page) http://localhost:/wickettest-portlet/wickettest/ps:d2lja2V0dGVzdF9XQVJfd2lja2V0dGVzdHBvcnRsZXRfTEFZT1VUXzEwNjE3/wicket/resource/org.apache.wicket.ajax.WicketAjaxReference/wicket-ajax-ver-1338396584000.js This does not work: (after a page refresh) http://localhost:/wickettest-portlet/ps:d2lja2V0dGVzdF9XQVJfd2lja2V0dGVzdHBvcnRsZXRfTEFZT1VUXzEwNjE3/wicket/resource/org.apache.wicket.ajax.WicketAjaxReference/wicket-ajax-ver-1338396584000.js The difference is that the second request does not have wickettest after the portlet name (wickettest-portlet) I believe this is now more a liferay question but I thought that if any one that has liferay/wicket experience could help out in this as the two are very finicky together. 1) why does this occur? 2) how do I fix it? Thank Doug -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-Liferay-help-tp4651140p4651143.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
Wicket / Liferay help
I have followed what I think is necessary to get a wicket portlet in liferay. However, I have not been able to add the portlet to a page. I am by no means a liferay expert so I may be missing something. Note: liferay 6.1 This is what I have done so far. Can someone point out what I have done wrong? - installed liferay / tomcat - created a simple wicket (v1.5.7) webapp via the quick start - created portlet.xml and modified web.xml per http://www.paykin.info/java/wicket_liferay_portlets/ http://www.paykin.info/java/wicket_liferay_portlets/ - mvn package - copied war to /deploy Go to the Liferay Control Panel -> Update Manager indicates that the portlet is there But how do I add it to a page? I can't seem to find the portlet anywhere. What have I done wrong? Any help is greatly appreciated. Thanks Doug -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-Liferay-help-tp4651140.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: After 1 minute the Pagemap null is still locked by: Thread how to kill this request ?
There are a lot more threads that are running within a Weblogic container. The thread you are showing is not the thread that is creating the lock. It is the thread that is indicating the page map is locked. Also, I don't believe there is a way to kill a particular thread in weblogic. It only shows the threads in use with little or no management capability. Consequently, not sure how you would be able to "kill" a thread -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/After-1-minute-the-Pagemap-null-is-still-locked-by-Thread-how-to-kill-this-request-tp4565091p4569113.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: AJAX upload in modal window hangs when file size is too large @L
I am assuming what you mean by hanging is that the call on the client browser doesn't complete or is interrupted for some reason. The hanging is not occurring on the server side...correct? Are there any javascript errors? I ask b/c you indicated: "INFO: Invoking pre-call handler(s)..." and before "INFO: Response parsed. Now invoking steps...". Could be that the info window is not there in the DOM any more? Not that these are answers but steps I would like to solving this problem. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/AJAX-upload-in-modal-window-hangs-when-file-size-is-too-large-L-tp4276504p4282736.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: Caching Imagages, CSS, JS in Wicket 1.5.3
Out of curiosity, why aren't you using ContextImage? That would help with the contextual path for the logout.png. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Caching-Imagages-CSS-JS-in-Wicket-1-5-3-tp4121068p4121323.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: Upgrading of Wicket application on server without losing state
We are using Weblogic 10.3 and it has a nice feature that allows two versions of the app to run concurrently. What happens is this: - V1 is running and sessions are currently active - deploy V2 - existing V1 sessions will continue to use V1 code - new request (i.e. new session) will use V2 This is OOTB nothing needed on our code or configuration. No need to bring down an app or server or cluster. Happens automatically. Very nice from a maintenance and administration stand point. Negative: WL is expensive -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Upgrading-of-Wicket-application-on-server-without-losing-state-tp3965762p3974603.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: JavaScriptReference with TextTemplate only returns the first retrieved value
I have encountered this issue as well...and I believe I know the reason for this behavior. The TextTemplateResourceReference eventually is bound to the Application shared resources. It never gets reset. So the TextTemplateResourceReference will always use the first "variables" used to substitute in the template. I believe the correct way to do achieve this behavior is to couple the text template substitution with a dynamic web resource. Am I correct on this? Has anyone done this before? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/JavaScriptReference-with-TextTemplate-only-returns-the-first-retrieved-value-tp1877334p3764346.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: CSS Change not being picked up when using TextTemplateResourceReference
I have just encountered this issue and have tried overriding the newResource but in 1.4.18 the variables textTemplate, and variablesModel are private. Any suggestion how I might be rectify this w/o creating my own TextTemplateResourceReference? BTW...Can't move to 1.5 Thanks in advance - Doug -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/CSS-Change-not-being-picked-up-when-using-TextTemplateResourceReference-tp3613064p3764050.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: StatelessForm on BookmarkablePage and its action url
Urgghhh. It does work. Just have to pass the PageParameters to the super class in the constructor. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/StatelessForm-on-BookmarkablePage-and-its-action-url-tp3761160p3763192.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
StatelessForm on BookmarkablePage and its action url
I have a stateless page (LocationPage) that contains an StatelessForm. @StatelessComponent public class LocationPage extends AppBasePage { ... } The LocationPage is mounted as: mount(new MixedParamUrlCodingStrategy("/b", LocationPage.class, new String[] { "name", "city", "state", "category", "businessID" })); I access the page via: http://localhost:8080/b/ben-bridge-jeweler/redondo-beach/ca/gift/53109 However, when I view the generated source for this page the action URL is: ../../../../../b/?wicket:interface=:0:layoutPanel:emailPanel:emailForm::IFormSubmitListener:: Shouldn't this be: ../../../../../b/ben-bridge-jeweler/redondo-beach/ca/gift/53109??wicket:interface=:0:layoutPanel:emailPanel:emailForm::IFormSubmitListener:: I am using Wicket 1.4.18 Thanks - Doug -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/StatelessForm-on-BookmarkablePage-and-its-action-url-tp3761160p3761160.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: DropDownChoice and preserving current page parameters
figured it out: My page hierarchy was not passing the PageParameters up the constructor chain. Additionally, I had to remove the containing form for the DropDownChoice. I swear this worked before...but I am not sure when it changed. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/DropDownChoice-and-preserving-current-page-parameters-tp3694641p3694687.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
DropDownChoice and preserving current page parameters
I have a "navigation area" that drives the amount of content on a DataView. One of these navigating components is a DropDownChoice which drives the number of rows to be displayed in the DataView. This page is to be stateless and is mounted as such: mount(new MixedParamUrlCodingStrategy("/categoryListings", CategoryListingPage.class, new String[] { "category" })); My DDC is implemented as: DropDownChoice pageChoice = new DropDownChoice( "rowsPerPage", new PropertyModel(ListingsByCategory.this, "displayResults"), rowsPerPageVals) { @Override protected void onSelectionChanged(Integer newSelection) { System.out.println("HERE: " + newSelection); dataView.setItemsPerPage(displayResults); PageParameters params = new PageParameters(); params.add("category", categoryId.toString()); params.add("itemsPerPage", String.valueOf(displayResults)); setResponsePage(getPage().getClass(), params); } @Override protected boolean wantOnSelectionChangedNotifications() { return true; } @Override protected boolean getStatelessHint() { return true; } }; The issue I am having is that the DDC.onComponentTag() isn't preserving the bookmarkable parameters. I am almost positive that this was occurring on a previous version of Wicket (I am currently using 1.4.17). Also, my onSelectionChanged(Integer val) is not being called (as evident by the missing "HERE" in my output) Has anyone else experienced this issue? Thanks - Doug -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/DropDownChoice-and-preserving-current-page-parameters-tp3694641p3694641.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: Pushing events to Wicket Push generated outside of Wicket
Rodolfo, Thanks for the reply. I figured that out just about an hour before you replied. Works like a charm now. - Doug -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Pushing-events-to-Wicket-Push-generated-outside-of-Wicket-tp3567200p3576891.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
Pushing events to Wicket Push generated outside of Wicket
We have a system that subscribes to events from an ESB. These events need to be then translated / added to the Wicket Push Bus so the appropriate Wicket components get updated appropriately. >From what I can see, everything in Wicket Push requires a component. Unfortunately, we need to wire up ESB event listener and subsequently the ESB/Wicket Push Bridge in the Application.init() method (so we think). The Application.init() method doens't have access to a component (unless we create a dummy component) Has someone done this? Is this possible? Any example that can referenced? Thanks in advance. - Doug -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Pushing-events-to-Wicket-Push-generated-outside-of-Wicket-tp3567200p3567200.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 push startup error messages
Never mind. I just found the cometd web site and the following post: http://cometd.org/documentation/2.x/howtos/servlet-containers I added to my web.xml: continuation org.eclipse.jetty.continuation.ContinuationFilter continuation /cometd/* and the messages disappeared. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/wicket-push-startup-error-messages-tp3538871p3538892.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
wicket push startup error messages
Not sure if any anyone else has experienced this. On startup of my wicket app...I get the following messages: I searched the web and nothing I found was conclusive. Any help would be appreciated. java.lang.IllegalStateException: STATE!=START at org.mortbay.jetty.AbstractGenerator.setVersion(AbstractGenerator.java:319) at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:870) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:558) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404) at org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:228) at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582) Then after that I consistently get the following: java.lang.IllegalStateException: STREAM at org.mortbay.jetty.Response.getWriter(Response.java:616) at org.cometd.server.transport.JSONTransport.send(JSONTransport.java:71) at org.cometd.server.transport.LongPollingTransport.handle(LongPollingTransport.java:293) at org.cometd.server.CometdServlet.service(CometdServlet.java:201) at org.cometd.server.CometdServlet.service(CometdServlet.java:165) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1166) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:370) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:388) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:440) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152) at org.mortbay.jetty.Server.handle(Server.java:326) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542) at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:943) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404) at org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:228) at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582) Any idea what I need to do to rectify these? Thanks in advance. - Doug -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/wicket-push-startup-error-messages-tp3538871p3538871.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: double validation with two different values for a text field
Found out the issue. I was always returning a null value in my converter.convertToObject(). When I returned the parsed value correctly...everything worked fine. With the null value, for some reason, my underlying object model did not set with a null value. Very bizarre. As far as removing validators...you can't. I had to create a base validator which was added to my ZipTextField and it was responsible for delegating to correct country zip validator on the fly. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/double-validation-with-two-different-values-for-a-text-field-tp3259122p3260453.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
double validation with two different values for a text field
I have created a custom zip text field that validates against several country formats, i.e. US and Canada. I have created specific country converters and validators that are utilized by this custom zip field. In my test scenario, I have a valid US address displayed. I then change the country that has a AjaxFormComponentUpdatingBehavior which sends back the zip and state fields. Note: zip field has a model reference of the country value which determines which validator/converter to use. I change the zip to be a valid Canadian zip (A#A #A#) and submit the changes. In my debug statements, I see the new value is parsed and validated with no error detected. But what is interesting, the previous US zip value is also being validated which causes an unexpected. Where did this zip value come from? Did I forget to change/refresh a value/component? Any help is much appreciated. Thanks - Doug
IndexedSharedResourceCodingStrategy.encode not being called
I have mounted an IndexedSharedResourceCodingStrategy in my WebApplication as such: getSharedResources().add("photo", new BusinessPhotoSharedResource()); mount(new IndexedSharedResourceCodingStrategy("photo", "photo") ); and I have created an Image with the appropriate resource ref and ValueMap. ValueMap valueMap = new ValueMap(); valueMap.add("0", photoId.getBusinessID().toString()); valueMap.add("1", photoId.getContentID().toString()); add( new Image( "photo", new ResourceReference(Application.class, "photo"), valueMap ) ); but the generated URL for that image is not created as expected. Generated: src="resources/app/photo?0=50824&1=1401" Expected: src="resources/app/50824/1401/photo" Is there something I am missing? I set a break point in Eclipse in the encode and it never reached that break point. Any help is appreciated. Thanks - Doug
Re: mounting SharedResource with known parameters, i.e. MixedParamUrlCodingStrategy
Never mind...IndexedSharedResourceCodingStrategy is what I needed. Missed that in my initial search. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/mounting-SharedResource-with-known-parameters-i-e-MixedParamUrlCodingStrategy-tp3071302p3072687.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
mounting SharedResource with known parameters, i.e. MixedParamUrlCodingStrategy
We are currently serving our photos from the following URL: http://mydomain.com/base/resources/app/photo?bid=53060&cid=22288 However we would like the URL to be: http://mydomain.com/base/resources/app/photo/53060/22288/image.jpg We are currently mounting our shared resource as follows: getSharedResources().add("photo", new BusinessPhotoSharedResource()); mountSharedResource("photo", "photo"); I would like to be able to something like MixedParamUrlCodingStrategy but for resources mount(new SharedResourceRequestTargetMixedParamUrlCodingStrategy("/photo", "photo", new String[] { "bid", "cid", "file" })); Is this possible? or provided currently in 1.4.x? Are there other ways to provide this behavior? Thanks - Doug
Re: Cannot create statless page
Try adding setStatelessHint( true ) in the HomePage constructor. public class HomePage extends WebPage { public HomePage() { add(new Label("label", new Model("Hello, World"))); setStatelessHint( true ); // <- new } } -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Cannot-create-statless-page-tp2996566p2997184.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: Slow wicket page on specific server
Was this thread dump taken while you were waiting for a response? Is this the complete thread dump? Does this delay occur on all pages that are doing similar things, i.e. connecting to the same DB or external resource? I don't see any waiting on any Wicket related items. With that...I don't believe it is a wicket problem. I would look at DNS, TCP connection settings on your server (s), i.e. apache, tomcat. Unfortunately, since I am not sure what that app is doing or what it is connecting to...this is very hard to offer concrete suggestions. Hopefully this will help by pointing in the right area to dive in deeper. - Doug -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Slow-wicket-page-on-specific-server-tp2914155p2956230.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: Slow wicket page on specific server
Have you tried to do a thread dump while it is responding to the request? My guess is it some network related issue, i.e. firewall, DNS or something along the lines. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Slow-wicket-page-on-specific-server-tp2914155p2916656.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: PDF generation
PD4ML -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/PDF-generation-tp2717158p2717265.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
Downloading generated PDF behavior different with apache in front of appserver
All, We have an application that generates a PDF (via PD4ML) and sends it back in the same request. This works fine and dandy when accessing our app server (weblogic/http) directly. However, when we access the same functionality but via Apache and SSL to weblogic, we get a message that the resultant file is corrupted. Not sure why this is occurring. It appears that stream is being closed before the content upload has been completed. We have static PDF served up via apache/weblogic that don't have any problems. Does anyone have any idea where I need to start looking? I am assuming this is not a Wicket issue as it works when the appserver is accessed directly but could be wrong. Thanks - Doug
Session.replaceSession() behavior
I was under the impression that when I call Session.replaceSession() a new session would be created. I am seeing a new HttpServletSession being created but not my wicket application session. I have placed a System.out.println( "new AppSession()..." ) in the constructor and I am not seeing that. Can anyone confirm this behavior as well? Is this a bug? Is there a work around? I am using Wicket 1.4.9 BTW...my use case is someone goes to the LoginPage and logs in, the previous session will be cleared. Multi-window support is also on (however...changing this doesn't affect the outcome) Thanks - Doug
Re: date picker calendar shown on text field clicked
I actually have a requirement for the Date Picker to be shown when focus is applied to the field. Is this possible too? Can this be configurable, i.e. not all fields have this onfocus behavior? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/date-picker-calendar-shown-on-text-field-clicked-tp2234853p2236054.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Getting URL for a bookmarkable page
figured it out. It wasn't wicket but PD4ML. Not sure why but I had to remove from my HTML page. When it was in there, it gave a message that it was retrying with utf-8. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Getting-URL-for-a-bookmarkable-page-tp2221421p2221693.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Getting URL for a bookmarkable page
I have changed the code to the following: String uri = "inSessionReport/" + URLEncoder.encode(jproperties.toString(), "UTF-8"); String url = RequestUtils.toAbsolutePath(uri); PD4ML pd4ml = new PD4ML(); pd4ml.setHtmlWidth(1024); pd4ml.render(new URL(url), os); But I am still seeing to Page constructor invocations with the same stack trace when I create an exception and print the stack trace. Any idea on how to not call the constructor twice? java.lang.Exception: InSessionReportPage.here 1 at com.alllocal.wicket.main.reports.InSessionReportPage$$M$caa816f0.__init__(InSessionReportPage.java:48) at com.alllocal.wicket.main.reports.InSessionReportPage$$A$caa816f0.__init__() at com.alllocal.wicket.main.reports.InSessionReportPage.(InSessionReportPage.java:123) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at org.apache.wicket.session.DefaultPageFactory.createPage(DefaultPageFactory.java:188) at org.apache.wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:89) at org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.newPage(BookmarkablePageRequestTarget.java:305) at org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.getPage(BookmarkablePageRequestTarget.java:320) at org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.processEvents(BookmarkablePageRequestTarget.java:234) at org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:92) at com.alllocal.wicket.AppApplication$1.processEvents(AppApplication.java:50001) at org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1250) at org.apache.wicket.RequestCycle.step(RequestCycle.java:1329) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1428) at org.apache.wicket.RequestCycle.request(RequestCycle.java:545) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:479) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:312) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at com.positiontech.hib.HibernateFilter.doFilter(HibernateFilter.java:70) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:295) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:503) at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:827) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:511) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:210) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:379) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:361) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442) -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Getting-URL-for-a-bookmarkable-page-tp2221421p2221494.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Getting URL for a bookmarkable page
I am doing the following to get the URL for my bookmarked page. PageParameters params = new PageParameters(); params.put("properties", URLEncoder.encode(jproperties.toString(), "UTF-8")); CharSequence url = urlFor(MyPage.class, params); WebRequest webRequest = (WebRequest) getRequest(); HttpServletRequest request = webRequest.getHttpServletRequest(); URL currUrl = new URL(request.getRequestURL().toString()); URL u = new URL(currUrl.getProtocol(), currUrl.getHost(), currUrl .getPort(), request.getContextPath() + "/" + url.toString()); PD4ML pd4ml = new PD4ML(); pd4ml.setHtmlWidth(1024); pd4ml.render(u, os); The problem I am having is that urlFor() creates and instance of MyPage.class which I don't want. Is there another or better way to get the full URL for a page in my application without calling the constructor? Thanks - Doug
GMap2 and zoom_changed
I was under the impression that when the GMap2 zoomed in/out, the Wicket GMap2 object would be updated. When I query Wicket GMap2 upon a dblclick after I had zoomed in, the zoom level had not changed. Should this be the case? If not, I would like to be able to add a zoom_changed listener on the GMap2 in my app. What is the best way to do so? Does anyone have any examples? Thanks in advance, - Doug
Gmap2 and Wicket 1.4.8
I just upgraded to Wicket 1.4.8 from 1.4.6. I am using Gmap2 (1.4.1). Upon doing so, my maps are no longer showing a map...just a blank area with the google controls that are non-functional. Has anyone else experienced this? Any work arounds? Thanks in advance, - Doug
Interstitial window prompt then open a new window
We are needing an interstitial window that prompts a user if they want to continue to another site. Additionally, we would like to provide a checkbox if they would not longer like to see this prompt again. I can prompt via a ModalWindow and capture their response...but what I am not sure what to do now is open a window with the destination URL via Ajax. I like the target="_blank" behavior on an href...but this can't apply since I am opening a modal window with that link. Do I have to create custom javascript to append to the Ajax request to open a new window with that url? Are there other options? Thanks in advance! - Doug
Anybody use Google Maps for directions?
I would like to utilize the new Google Maps v3 API for directions. Didn't know if anyone has used this in conjunction with the GMap2 package. If so, any chance of getting an example of how you did it? Thanks - Doug
Re: Feedback border when using in a repeating view
Update... I changed to a ListView and set the reuse item flag to true and I achieved what I was looking for. -- View this message in context: http://old.nabble.com/Feedback-border-when-using-in-a-repeating-view-tp28048563p28056267.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Feedback border when using in a repeating view
I am using a feedback border panel for some components (i.e. email) in a repeating view (in this case a dataview). I am using a Email validator for this component and when an error occurs it creates a red border and backround around this component. Well it is supposed to but it isn't. I do this feedback border panel on components outside a repeating view and it works fine. Should I be doing something different? I tried setting the reuse strategy but it didn't work. Any suggestions? Thanks - Doug
Re: Dynamic Image (aka Barcode) based on user input not refreshed via Ajax
Perfect! Thanks! -- View this message in context: http://old.nabble.com/Dynamic-Image-%28aka-Barcode%29-based-on-user-input-not-refreshed-via-Ajax-tp27961609p27972311.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Dynamic Image (aka Barcode) based on user input not refreshed via Ajax
I am trying to create a barcode image from a user entered value. The image is to be updated while the user types. Hence I am using Ajax (onChange event) on the text field to regenerate the image. However, the image is not getting refreshed. It appears that the browser is not recognizing that the image has been updated. Is there a way to append a "timestamp" on the image url just for this image? or should I use a different type of resource? Note: the value entered has not be persisted so I don't believe I can a ResourceReference. Please correct me if I am wrong. Thanks - Doug BTW...Here is my code that I am using to generate the bar code: barCodeValueContainer = new WebMarkupContainer("barCodeValueContainer") { @Override public void onBeforeRender() { if (coupon.getObject().getBarCodeType() == null) { codeContainer.replace(new WebMarkupContainer("barCode")); } else if (barCodeErrorMessage == null) { codeContainer.replace(new BarCodeFragment("barCode", this)); } else { codeContainer.replace(new ErrorFragment("barCode", this, barCodeErrorMessage)); } super.onBeforeRender(); } public boolean isVisible() { return coupon.getObject().getBarCodeType() != null; } }; private class BarCodeFragment extends Fragment { public BarCodeFragment(String id, MarkupContainer markupProvider) { super(id, "barCodeFragment", markupProvider); setRenderBodyOnly(true); // Create the barcode bean String barCodeType = coupon.getObject().getBarCodeType(); String barCodeValue = coupon.getObject().getBarCodeValue(); AbstractBarcodeBean bean = null; if (barCodeType.equals(BarCodeType.CODE_39.id())) { bean = new Code39Bean(); // bar width exactly one pixel ((Code39Bean) bean).setWideFactor(3); } else if (barCodeType.equals(BarCodeType.CODE_128.id())) { bean = new Code128Bean(); } else if (barCodeType.equals(BarCodeType.UPC_A.id())) { bean = new UPCABean(); } if (bean == null || barCodeValue == null) { add(new ErrorFragment("barCode", CouponDetailEditPanel.this, "Bar code value not set")); } else { final int dpi = 150; // Configure the barcode generator bean.setModuleWidth(UnitConv.in2mm(1.0f / dpi)); // makes the // narrow bean.doQuietZone(false); // Open output file ByteArrayOutputStream out = new ByteArrayOutputStream(); try { // Set up the canvas provider for monochrome PNG output BitmapCanvasProvider canvas = new BitmapCanvasProvider(out, "image/png", dpi, BufferedImage.TYPE_BYTE_BINARY, false, 0); // Generate the barcode bean.generateBarcode(canvas, barCodeValue); System.out.println("VALUE: " + barCodeValue); // Signal end of generation canvas.finish(); out.close(); final byte[] content = out.toByteArray(); Image img = new Image("barCode", new BarCodeImageResource( content)); add(img); } catch (Exception e) { add(new ErrorFragment("barCode", CouponDetailEditPanel.this, e.getMessage())); } } } } private class BarCodeImageResource extends DynamicImageResource { private byte[] content; public BarCodeImageResource(byte[] content) { super("image/png"); this.content = content; this.setLastModifiedTime(Time.now()); } @Override protected byte[] getImageData() { return content; } }
setResponsePage in AjaxButton after uploading a File
I have a simple form that has a file selection component and a submit button. I would like to submit via Ajax and then call setResponsePage if successful. The file is submitted/received fine but the setResponsePage does nothing. The Wicket Debug window indicates that there was an error getting ajax response...but there was error in the console on the server side. Has anyone else had similar issues? Thanks -Doug
Re: Too Many Open Files Wicket 1.4.1
Was a JIRA ticket ever created for this? I couldn't find any thing related to it. Is any one else seeing this issue? I just ran across it in our dev env after redeploying my web app. Not sure if this wicket, jdk, or weblogic. Weblogic 10 JRockit (BEA JRockit(R) (build R27.6.5-32_o-121899-1.6.0_14-20091001-2113-linux-ia32, compiled mode)) Linux Wicket 1.4.4 -- View this message in context: http://old.nabble.com/Too-Many-Files-Wicket-1.4.1-tp25983047p26963709.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
GMap2 and Zillow Neighborhood Overlays
Was wondering if anyone has had experience with GMap2 and Zillow Neighboorhood Overlays. Would like to find out about best practices and experiences with these. My concern is the amount of data that needs to be deployed with the app to be able to provide neighboorhood maps. Thanks in advance, - Doug - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: FileUploadField in a ModalWindow (wicket 1.4.3)?
I have created a quick start and attached it to WICKET-2595. I have also included my suggested fixes to Form.java and wicket-ajax.js. It got past the problem of not submitting in an iframe but my AjaxButton.onSubmit is not being called and there are no errors generated. Hope this helps. - Doug -- View this message in context: http://old.nabble.com/FileUploadField-in-a-ModalWindow-%28wicket-1.4.3%29--tp26577255p26652425.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: FileUploadField in a ModalWindow (wicket 1.4.3)?
1.4 trunk or 1.5 trunk? -- View this message in context: http://old.nabble.com/FileUploadField-in-a-ModalWindow-%28wicket-1.4.3%29--tp26577255p26641953.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: FileUploadField in a ModalWindow (wicket 1.4.3)?
Found the code where the iframe is being used (resources/org.apache.wicket.ajax.WicketAjaxReference/wicket-ajax.js) When looking at the generated html for the modal window in a nested form situation, it shows the submit button actually being submitted by wicketSubmitFormById(formId,...) The formId is the inner "form" but the Form class actually generates a "div" element instead of a "form" (not the root form) and removes the enctype. Since the enctype has been removed, the Javascript cannot create the iframe as it looking to see if the form has the enctype="multipart/form-data"...hence the request is being sent via Ajax still and not the iframe. So my thought is that that in the Form.onComponentTag() it should not remove the enctype if isMultiPart() is true but add a variable enctype to the div...but not sure if this is allowed. Can someone verify this as this is not my area of expertise (JavaScript or Ajax internals)? Thanks - Doug -- View this message in context: http://old.nabble.com/FileUploadField-in-a-ModalWindow-%28wicket-1.4.3%29--tp26577255p26635788.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: FileUploadField in a ModalWindow (wicket 1.4.3)?
I was also able to reproduce this issue. When I stepped through the code with NestedForm, the Form.handleMultiPart() never creates a MultipartWebRequest due to the original request is identified as an AjaxRequest (as seen by the following code snippet. protected boolean handleMultiPart() { if (isMultiPart() && !((WebRequest)getRequest()).isAjax()) { ... However, when I step through a non-nested Form example (with a File upload) but utilize an Ajax call, the isAjax() is false. Which indicates that the seamless iframe fix is working. (https://issues.apache.org/jira/browse/WICKET-2420) Back to the nested form example, I even set the Outer form to be multipart but it still doesn't work (ajax is still true). Where is this seamless Iframe fix so I can see where it is applied and why it is not being used even if the form is set to multi-part? Thanks - Doug -- View this message in context: http://old.nabble.com/FileUploadField-in-a-ModalWindow-%28wicket-1.4.3%29--tp26577255p26635765.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Ajax FileUpload in a ModalWindow
Converted to 1.4.3 and the issue is still relevant I see there was another thread created with similar issues. (not sure why Nabble didn't report this in my previous search) http://old.nabble.com/FileUploadField-in-a-ModalWindow-%28wicket-1.4.3%29--to26577255.html -- View this message in context: http://old.nabble.com/Ajax-FileUpload-in-a-ModalWindow-tp26632965p26634746.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Ajax FileUpload in a ModalWindow
BTW...I am using wicket 1.4.1 Also, I have tried just adding the NewPhotoPanel to one of my pages...changed some of the Ajax methods but still submitted via Ajax. This still didn't work. Can someone verify that FileUpload works via Ajax with 1.4.1 (as the Jira issue indicates) or should I upgrade to a new version of wicket? Thanks - Doug -- View this message in context: http://old.nabble.com/Ajax-FileUpload-in-a-ModalWindow-tp26632965p26633436.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Ajax FileUpload in a ModalWindow
I see that FileUpload is available now via Ajax (https://issues.apache.org/jira/browse/WICKET-2420). However, is it possible to upload from a ModalWindow via Ajax? In my AjaxButton, my FileUpload object is not being set. I am also not seeing an IFrame in the Wicket Debug I have attached my code if that may help. Thanks - Doug package com.alllocal.wicket.main.newBusiness.photos; import org.apache.wicket.ajax.AjaxRequestTarget; import org.apache.wicket.ajax.markup.html.AjaxLink; import org.apache.wicket.ajax.markup.html.form.AjaxButton; import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow; import org.apache.wicket.markup.html.WebMarkupContainer; import org.apache.wicket.markup.html.form.Form; import org.apache.wicket.markup.html.form.upload.FileUpload; import org.apache.wicket.markup.html.form.upload.FileUploadField; import org.apache.wicket.markup.html.panel.FeedbackPanel; import org.apache.wicket.model.CompoundPropertyModel; import org.apache.wicket.model.IModel; import org.apache.wicket.model.PropertyModel; import com.alllocal.model.AllLocalBinaryContent; import com.alllocal.model.business.BusinessLocation; import com.alllocal.model.business.BusinessPhoto; import com.positiontech.common.model.StoredImage; import com.positiontech.common.wicket.BasePanel; import com.positiontech.common.wicket.PTFeedbackPanel; public class NewPhotoPanel extends BasePanel { private BusinessPhoto photo; private IModel location; private FileUploadField fileUploadField; private FileUpload fileUpload; private FeedbackPanel feedback; private WebMarkupContainer dataContainer; public NewPhotoPanel(String id, IModel inLocation) { super(id); this.location = inLocation; photo = new BusinessPhoto(); photo.setContent(new AllLocalBinaryContent()); Form form = new Form("photoForm"); add(form); form.setMultiPart(true); dataContainer = new WebMarkupContainer("dataContainer"); form.add(dataContainer); dataContainer.setOutputMarkupId(true); feedback = new PTFeedbackPanel("feedback"); dataContainer.add(feedback); feedback.setOutputMarkupId(true); form.setDefaultModel(new CompoundPropertyModel(photo)); fileUploadField = new FileUploadField("content.fileName", new PropertyModel(this, "fileUpload")); addFormComponentWithFeedback(dataContainer, fileUploadField); // addFormComponentWithFeedback(dataContainer, new RequiredTextField( // "title")); form.add(new AjaxButton("addPhoto") { @Override protected void onSubmit(AjaxRequestTarget target, Form form) { try { AllLocalBinaryContent media = photo.getContent(); if (fileUpload != null) { String fileName = fileUpload.getClientFileName(); String contentType = fileUpload.getContentType(); byte[] content = fileUpload.getBytes(); if (StoredImage.isImageAllowed(contentType) == false) { error("File type is not supported. " + "Supported types are JPEG, GIF, and PNG."); return; } // TODO do we want to massage the image to a certain // size if // is too big media.setFileName(fileName); media.setContentType(contentType); media.setContent(content); location.getObject().getPhotos().add(photo); ModalWindow.closeCurrent(target); } else { error("Unable to upload file."); target.addComponent(feedback); } } catch (Exception e) { error(e); log(e); target.addComponent(feedback);
Re: Customized FeedbackPanel question
That is my backup plan. -- View this message in context: http://old.nabble.com/Customized-FeedbackPanel-question-tp26613644p26614645.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Customized FeedbackPanel question
We have a requirement to render the offending FormComponent with a visual change (not an indicator...but a style change such as background is red) and show the error message below the component. I have created a customized FeedbackPanel for this so this is not a problem. The problem we have is that we also have a FeedbackPanel at the top of the page which renders the error message as well. We don't the message to be rendered twice. I have attempted this behavior by playing around with the IFeedbackMessageFilter, onBeforeRenderer and markRendered method but my efforts have failed. I was hoping that there was a onBeforeXXX method that can be called so I can determine if what messages are to be renderered in the FeedbackPanel before they are actually renderered. It appears that the component is rendered right after onBeforeRender before moving on to the next child component. Has anyone else come into this requirement and have found an acceptable solution? Is there another onBeforeXXX method that is called before rendering and traverses the entire component graph that I may override and mark messages as rendrered? Thanks in advance. - Doug - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: wicket on Weblogic 10.3.1
Hmmm...a very strange stack indeed so I won't ask ;-) So urls with 127.0.0.1 work...correct? but if you initially access via localhost it doesn't? Do you have WL configured as a named virtual server by chance? Are you seeing generated urls being bounced back and forth between localhost and 127.0.0.1 when you access via localhost? If so, this may cause your session information to be lost when bouncing back/forth as 'domain name' (i believe) is used for your session key (via cookies). You can't access cookies from a different domain. -- View this message in context: http://old.nabble.com/wicket-on-Weblogic-10.3.1-tp26492655p26498557.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: wicket on Weblogic 10.3.1
We've had no problems on our implementation. Even session replication works as expected. What is your stack? Are you doing stick sessions? Have you enabled session replication? -- View this message in context: http://old.nabble.com/wicket-on-Weblogic-10.3.1-tp26492655p26495578.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: wicketstuff-minis status?
I was going to see about upgrading Prototip but the current version has moved to commercial license. Since that is the case, I won't be updating wicket-minis and will be looking at mootip. Thanks - Doug -- View this message in context: http://old.nabble.com/wicketstuff-minis-status--tp26394666p26408386.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: wicketstuff-minis status?
Richard, Thanks for the update. This was one of the items to be looked at. But since prototip has moved to commercial, then I won't update the JS. - Doug -- View this message in context: http://old.nabble.com/wicketstuff-minis-status--tp26394666p26408385.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: wicketstuff-minis status?
But wouldn't i see the timestamp change on the jars, etc change with each deployment? from http://wicketstuff.org/maven/repository/org/wicketstuff/wicketstuff-minis/1.4.0-SNAPSHOT/ maven-metadata.xml 0.3 kb Tue, 28 Oct 2008 23:16:32 GMT maven-metadata.xml.md5 0.1 kb Tue, 28 Oct 2008 23:16:32 GMT maven-metadata.xml.sha1 0.1 kb Tue, 28 Oct 2008 23:16:32 GMT wicketstuff-minis-1.4.0-SNAPSHOT.jar 116.9 kbTue, 28 Oct 2008 23:16:32 GMT wicketstuff-minis-1.4.0-SNAPSHOT.jar.md5 0.1 kb Tue, 28 Oct 2008 23:16:32 GMT wicketstuff-minis-1.4.0-SNAPSHOT.jar.sha10.1 kb Tue, 28 Oct 2008 23:16:32 GMT wicketstuff-minis-1.4.0-SNAPSHOT.pom 3.0 kb Tue, 28 Oct 2008 23:16:32 GMT wicketstuff-minis-1.4.0-SNAPSHOT.pom.md5 0.1 kb Tue, 28 Oct 2008 23:16:32 GMT wicketstuff-minis-1.4.0-SNAPSHOT.pom.sha10.1 kb Tue, 28 Oct 2008 23:16:32 GMT Also, how often do snapshots get built and distributed to the maven repositories? Thanks - Doug -- View this message in context: http://old.nabble.com/wicketstuff-minis-status--tp26394666p26396127.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
wicketstuff-minis status?
We are about to integrate wicketstuff-minis in our project. However, we noticed on Nabble that prototip is out of date based on some comments by the community. I have wicketstuff commit rights and more than willing to update to the latest. However, when I looked at the MVN repository for wicketstuff-minis (http://wicketstuff.org/maven/repository/org/wicketstuff/wicketstuff-minis/1.4.0-SNAPSHOT/), the timestamps are all in 2008. If I change/commit the necessary code, will the MVN repository be updated with the new version on the next build? or do I need to request a build to be placed out there? Or are there other options? Thanks - Doug - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: [ANN] wicket-dnd project
Thanks Sven! Got it working. -- View this message in context: http://www.nabble.com/-ANN--wicket-dnd-project-tp25727819p25873355.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: [ANN] wicket-dnd project
Sven, I have downloaded wicket-dnd and have integrated into our project. I had a few issues but got around them. The biggest is that we are using DataView instead of DataTable. While there was no exact example for DataView, I was able to get through and see what I needed to do: - needed a "container" apply the DataSource - needed to item.setOutputMarkupId( true ) in the populateItem The DropTarget is working (the UI changes when I hover over the target)...but when I initiate a drop, I get a PageExpiredException. Any thoughts? BTW..I have uploaded our simple test case for reference. Thanks - Doug http://www.nabble.com/file/p25859163/DndTestPage.java DndTestPage.java http://www.nabble.com/file/p25859163/DndTestPage.html DndTestPage.html http://www.nabble.com/file/p25859163/WicketApplication.java WicketApplication.java -- View this message in context: http://www.nabble.com/-ANN--wicket-dnd-project-tp25727819p25859163.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
[OT] Moving to SVN...best practices for project layout?
We have been using CVS for a long time now and want to move to SVN. We have an empty SVN repository created but have questions on how we should set up our multiple projects that all utilize a common project in conjunction with tags, branches, releases. To keep things somewhat consistent between the CVS/SVN, we know we want to first separate between python and Java (our 2 development languages). I believe our first SVN decision would be to have two separate repositories for these technologies and have multiple projects in these repositories. FYI: Java and Python are completely separate code bases, are not dependent upon one another, and have a different release. Now within each of these repositories, we both have a common utility project and multiple product projects. When we release/tag a product, we would like to release/tag only the common and specific product (or does it matter?). We have done some research SVN but are looking for best practices based on our requirements. We were hoping that someone might be able to point us in the right direction/place of information on achieving a manageable/effective source repository and build management. I have reviewed Wicket's project hierarchy and seems relevant to ours. However, when wicket is built/released, all projects are tagged and built which is contrary to our goal. We use Maven and its project structure. Our common project is a referenced module in each product project. Which of the following options is recommended? Are there any good specific references that would help determine this? (we have googled but a lot of information is returned) I did find this link which was helpful: http://svnbook.red-bean.com/en/1.1/ch05s04.html which is why we are leaning towards Option B. Option A: /java + trunk + common + project 1 + project N + tags + common + project 1 + project N + branches + common + project 1 + project N + releases + common + project 1 + project N Option B: /java + common + trunk + tags + branches + releases + project 1 + trunk + tags + branches + releases + project N + trunk + tags + branches + releases Option C: (this option is a separate repo for each project) /java/common + trunk + tags + branches + releases /java/project1 + trunk + tags + branches + releases /java/project2 + trunk + tags + branches + releases Thanks in advance! - Doug
GMap2 GOverlay.getJSConstructor() change request
I recently moved from 1.3.6 to 1.4.1 and came across a compile error. I believe I had a local copy of GMap2 (1.3.x) and made modifications to make the following work. Now I would like to propose a change but not sure who I need to talk. Specifically, I would like to request to change GOverlay.getJSConstructor() from protected to public (and all subsequent derived classes) I am need to send javascript back to the browser which basically rebounds the a GMap2...the following is my code snippet: private String getJSRebound() { StringBuffer buf = new StringBuffer(); buf.append("var bounds = new GLatLngBounds();\n"); buf.append("var map = " + map.getJSinvoke("map")); buf.append("bounds.extend( map.getCenter() ); \n"); int idx = 0; for (GOverlay overlay : map.getOverlays()) { if (overlay instanceof GMarker) { GMarker marker = (GMarker) overlay; GLatLng point = marker.getLatLng(); buf.append("bounds.extend( " + point.getJSconstructor() + " );\n"); } if (overlay instanceof GGeoXml) { GGeoXml xml = (GGeoXml) overlay; String var = "xml" + idx++; // this is broken with 1.4.1 // getJSconstructor has been made protected buf.append("var " + var + " = " + xml.getJSconstructor() + "; \n"); buf.append("GEvent.addListener(" + var + ", 'load', function(){ \n"); buf.append("bounds.extend( " + var + ".getDefaultBounds().getSouthWest() ); \n"); buf.append("bounds.extend( " + var + ".getDefaultBounds().getNorthEast() ); \n"); buf.append("map.setZoom( map.getBoundsZoomLevel(bounds) );\n"); buf.append("}); \n"); } } if (idx == 0) { GLatLng point = new GLatLng(location.getCentralLatitude(), location .getCentralLongitude(), false); buf.append("bounds.extend( " + point.getJSconstructor() + " );\n"); buf .append("map.setZoom( Math.min(map.getBoundsZoomLevel(bounds),8) );\n"); } else { buf.append("map.setZoom( map.getBoundsZoomLevel(bounds) );\n"); } buf.append("map.setCenter( bounds.getCenter() );\n"); return buf.toString(); } This method is called in my constructor: map.add(new HeaderContributor(new IHeaderContributor() { private static final long serialVersionUID = 1L; public void renderHead(IHeaderResponse response) { response.renderOnDomReadyJavascript(getJSRebound()); } })); Without the ability to generated the JS object and keep a reference, I don't believe I can accomplish what I need to do...rebound the map within the points I have stored. If someone has a better idea, I am all ears. If not, the accessibliity change would greatly be appreciated. Thanks - Doug
Re: [OT] OWasp Vulnerability Validation
Nino, Further searching found a lot more information...but it is scattered. I was hoping that someone may have aggregated a quick tip sheet about these vulnerabilities and how Wicket can/does help...but haven't found the "golden ticket" yet. I was also hoping that someone has had experience in using an automated tool in helping to validate a web app against these vulnerabilities. If so, do they recommend any particular one and what are the pros/cons? I will compile a list of information that specifically addresses these vulnerabilities and the different options and post to get a review from the community. Thanks - Doug BTW...I did find the following links in Wicket's Nabble that were very useful...I originally used Google to do my search...but should have gone here first to look. http://www.nabble.com/Security-Features-offered-by-Wicket-to15738864.html#a15738864 http://www.nabble.com/How-to-protect-against-Session-Fixation-attacks--tp18734278p18734278.html http://www.nabble.com/CSRF-Protection%3A-double-submitted-cookie-tp20065995p20067039.html https://issues.apache.org/jira/browse/WICKET-1767 https://issues.apache.org/jira/browse/WICKET-1782 -- View this message in context: http://www.nabble.com/-OT--OWasp-Vulnerability-Validation-tp25225742p25250738.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
[OT] OWasp Vulnerability Validation
All, Need some help here. A soon to be released Wicket application needs to validated with the Top 10 vulnerabilities that Owasp has identified. (http://www.owasp.org/index.php/Top_10_2007) Some of these cannot be validated by an outside entity...but for those can... Has anyone done this validation before? Is there a service that does this? Thanks in advance, - Doug
Replacing content in a ModalWindow issue
I have looked at the ModalWindow javadoc, searched through Nabble, and tried several different approaches but I cannot do the following. I have a ModalWindow showing a Panel A. This panel has a link that when selected, it is to show a ModalWindow with another Panel B. Ideally, ModalWindow/Panel A should go away and a ModalWindow/Panel B should only be displayed. I have tried to reuse the current ModalWindow and call through various combinations of setContent()/addOrReplaceComponent(). What results is that I have a ModalWindow showing Panel A and another ModalWindow showing Panel B. I have even tried to Panel A.setVisible()/target.addComponent(modalWindow). Does anyone know what I need to do to replace the content on a ModalWindow and only have one ModalWindow show? Thanks in advance! - Doug
Re: recommended static image/resource strategy
My issue appears to be not new... https://issues.apache.org/jira/browse/WICKET-1889 https://issues.apache.org/jira/browse/WICKET-1700 But the fix is for v1.4.x not v1.3.6 -- View this message in context: http://www.nabble.com/recommended-static-image-resource-strategy-tp24407111p24415044.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: recommended static image/resource strategy
My issue appears to be not new... https://issues.apache.org/jira/browse/WICKET-1889 https://issues.apache.org/jira/browse/WICKET-1700 But this only applies to v1.4. -- View this message in context: http://www.nabble.com/recommended-static-image-resource-strategy-tp24407111p24415043.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: recommended static image/resource strategy
I have added a quick start to exemplifies the issue at hand. Please see https://issues.apache.org/jira/browse/WICKET-2361 for those that are interested. Thanks -- View this message in context: http://www.nabble.com/recommended-static-image-resource-strategy-tp24407111p24413328.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: recommended static image/resource strategy
Thank Igor. Bug report has been created (WICKET-2361) Note: I was able to "work around" this issue by using QueryStringUrlCodingStrategy instead of the BookmarkablePageRequestTargetUrlCodingStrategy via the WebApplication.mountBookmarkablePage() method. From: Igor Vaynberg To: users@wicket.apache.org; Doug Leeper Sent: Thursday, July 9, 2009 10:13:05 AM Subject: Re: recommended static image/resource strategy it seems like a bug in ServletWebRequest#getRelativePathPrefixToWicketHandler(), you might want to subclass that, check for those two params in the url, and add an additional ../.. as a hack for right now. also open a jira issue for us to fix it. -igor On Wed, Jul 8, 2009 at 2:46 PM, Doug Leeper wrote: > Our app has been working great this past year but we recently encountered a > strange behavior and wanted to get the communities input on how to proceed. > > Background: > >* Wicket 1.3.6 >* JDK 1.5 >* Jetty (dev) / Apache and Tomcat (prod) >* The URL to our app follows this structure http://mydomain.com/APP > where APP is the web app name. >* We have our img src tags in our HTML utilize relative pathing, i.e. > "images/check.gif". >* Our images are contained in our web app off the root webapp > directory, i.e. "images". >* Some of our pages are bookmarkable utilizing > BookmarkablePageRequestTargetUrlCodingStrategy. >* We have turned on > getPageSettings().setAutomaticMultiWindowSupport(true) in our > Application.init() method >* FireFox 3.5 (is where we are seeing the odd behavior) > The recent change was the bookmarkable pages to produce "pretty URL's" such > as http://localhost:8080/APP/myPage.html. However, we have noticed that in > some cases, i.e. open link in new tab, the bookmarkable page URL changes to > http://localhost:8080/APP/myPage.html/wicket:pageMapName/wicket-1/. The > problem we are having now is that our images are not showing up. Viewing the > source the img src shows "images/check.gif" still. > > > I understand that our URL path has changed and that is why the gif does not > show up. But what is the best approach in handling static images/resources > and with our current configuration. Should we do one or more of the > following? > > >1. Don't use setAutomaticMultiWindowSupport (we really want this > feature so back button works as expected when new browser tab or window is > opened) > >2. Use absolute path for images (FYI...we want our war to be a single > deployable unit which includes the images...by doing this, would it require > the static information (images/css/js) to be deployed differently/separately? >3. Use a different mounted resource strategy? If so, which one? > BTW...no page parameters are needed on the mounted pages in question (they > can be ignored) > >4. Have all static resources be "wicketized" by using an resource > strategy, i.e. ContextRelativeResource. (this would require a lot of code > changes...not ideal) >5. Other???Thanks in advance, > - Doug > > BTW...My gut is pointing to #3 is the solution.
recommended static image/resource strategy
Our app has been working great this past year but we recently encountered a strange behavior and wanted to get the communities input on how to proceed. Background: * Wicket 1.3.6 * JDK 1.5 * Jetty (dev) / Apache and Tomcat (prod) * The URL to our app follows this structure http://mydomain.com/APP where APP is the web app name. * We have our img src tags in our HTML utilize relative pathing, i.e. "images/check.gif". * Our images are contained in our web app off the root webapp directory, i.e. "images". * Some of our pages are bookmarkable utilizing BookmarkablePageRequestTargetUrlCodingStrategy. * We have turned on getPageSettings().setAutomaticMultiWindowSupport(true) in our Application.init() method * FireFox 3.5 (is where we are seeing the odd behavior) The recent change was the bookmarkable pages to produce "pretty URL's" such as http://localhost:8080/APP/myPage.html. However, we have noticed that in some cases, i.e. open link in new tab, the bookmarkable page URL changes to http://localhost:8080/APP/myPage.html/wicket:pageMapName/wicket-1/. The problem we are having now is that our images are not showing up. Viewing the source the img src shows "images/check.gif" still. I understand that our URL path has changed and that is why the gif does not show up. But what is the best approach in handling static images/resources and with our current configuration. Should we do one or more of the following? 1. Don't use setAutomaticMultiWindowSupport (we really want this feature so back button works as expected when new browser tab or window is opened) 2. Use absolute path for images (FYI...we want our war to be a single deployable unit which includes the images...by doing this, would it require the static information (images/css/js) to be deployed differently/separately? 3. Use a different mounted resource strategy? If so, which one? BTW...no page parameters are needed on the mounted pages in question (they can be ignored) 4. Have all static resources be "wicketized" by using an resource strategy, i.e. ContextRelativeResource. (this would require a lot of code changes...not ideal) 5. Other???Thanks in advance, - Doug BTW...My gut is pointing to #3 is the solution.
Clustering on Tomcat
The Wiki info to setup clustering on Tomcat ( http://cwiki.apache.org/WICKET/tomcat-clustering.html http://cwiki.apache.org/WICKET/tomcat-clustering.html ) indicates that there is a bug in the "latest" Tomcat that causes Wicket to fail during session replication. My questions are: - what Tomcat bug is being referenced here? - what version of tomcat actually has the bug? - has anyone tried Tomcat 6.x with session replication? Thanks in advance, - Doug -- View this message in context: http://www.nabble.com/Clustering-on-Tomcat-tp22043732p22043732.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: [OT] wicket users around the world
St. Charles, IL (an hour west of Chicago) First created two new Wicket apps for production and now migrating existing apps to wicket. -- View this message in context: http://www.nabble.com/-OT--wicket-users-around-the-world-tp20962108p21186824.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Ajax Indicator Example?
I found what I was looking for. this is basically what I have done. In my page: public class FooPage extends WebPage implements IAjaxIndicatorAware { private WebMarkupContainer indicator; public FooPage() { // snip indicator = new WebMarkupContainer( "indicator" ); indicator.setOutputMarkupId(true); add( indicator ); // snip } public String getAjaxIndicatorMarkupId() { return indicator.getMarkupId(); } } in FooPage.html: resources/org.apache.wicket.ajax.AbstractDefaultAjaxBehavior/indicator.gif Processing... I implemented IAjaxIndicatorAware at the page level so all Ajax related behaviors/components will utilize this indicator. Hope that helps others... - Doug -- View this message in context: http://www.nabble.com/Ajax-Indicator-Example--tp20586418p20588406.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]
Ajax Indicator Example?
I am having problems understanding Ajax Indicators. I have search high/low for a working example and have been unsuccessful. Is there any examples that shows what I need to do get an AjaxLink or DropDownChoice w/ an AjaxFormChoiceComponentUpdatingBehavior to utilize an indicator to show something is working? Thanks - Doug -- View this message in context: http://www.nabble.com/Ajax-Indicator-Example--tp20586418p20586418.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: right click popup context menu
I just updated from SVN for projects wicketstuff-yui-examples and wicket-contrib-yui. Did a mvn eclipse:eclipse on both. in the wicketstuff-yui-examples, i did a mvn jetty:run There were no errors and I was able to access the web app and subsequently the menu2 examples. As far as your error...not sure. There has to be some other error that you are not mentioning. What other errors are you seeing in eclipse? -- View this message in context: http://www.nabble.com/right-click-popup-context-menu-tp15876468p19986080.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: initial GMap2 bounds question
I achieved what I was looking for. Here is what I did: map.add(new HeaderContributor(new IHeaderContributor() { private static final long serialVersionUID = 1L; public void renderHead(IHeaderResponse response) { StringBuffer buf = new StringBuffer(); buf.append( "var bounds = new GLatLngBounds();\n"); buf.append( "var map = " + map.getJSinvoke("map" ) ); for (CustomLocation custom : location.getCustomLocations()) { GLatLng point = new GLatLng(custom.getLatitude(), custom .getLongitude()); buf.append( "bounds.extend( " + point.getJSconstructor() + " );\n" ); } buf.append( "map.setZoom( map.getBoundsZoomLevel(bounds) );\n" ); buf.append( "map.setCenter( bounds.getCenter() );\n"); response.renderOnDomReadyJavascript(buf.toString()); } })); location is my data object that contains all my specific custom locations. Works like a charm! -- View this message in context: http://www.nabble.com/initial-GMap2-bounds-question-tp19883071p19886673.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]
initial GMap2 bounds question
Lets say I have two GLatLng Points, i.e. Chicago and Indianapolis. I would like to have the map be centered between these points and bounded to show these points. What is the best way to do this? -- View this message in context: http://www.nabble.com/initial-GMap2-bounds-question-tp19883071p19883071.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: right click popup context menu
what version of wicket are you using? I have not tested/ported any of the menu2 with wicket 1.4. -- View this message in context: http://www.nabble.com/right-click-popup-context-menu-tp15876468p19865384.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: GMap2 or Wicket Ajax issue?
I applied that change locally and it did not change the behavior/error that I was seeing. Not sure what else to try. I guess I will make it a Page rather than a ModalWindow for now to keep moving along. Thanks for the help. - Doug -- View this message in context: http://www.nabble.com/GMap2-or-Wicket-Ajax-issue--tp19859974p19862570.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: GMap2 or Wicket Ajax issue?
It could be related. One way to find out... I will apply the suggested patch and see what happens. Which patch should I try? There appears to be two suggestions. Thanks - Doug -- View this message in context: http://www.nabble.com/GMap2-or-Wicket-Ajax-issue--tp19859974p19861512.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: GMap2 or Wicket Ajax issue?
So I tried in IE 7 and this is what I get in the Ajax Debug Window. Note: the modal window does show up...but IE indicates that it has experienced an error and asks that I debug. ... INFO: Initiating Ajax GET request on http://www.google.com/jsapi?key=ABQIzaZpf6nHOd9w1PfLaM9u2xQRS2YPSd8S9D1NKPBvdB1fr18_CxR-svEYj6URCf5QDFq3i03mqrDlbA INFO: Invoking pre-call handler(s)... INFO: focus removed from setTargets15 INFO: focus set on setTargets15 INFO: Received ajax response (12326 characters) INFO: Invoking post-call handler(s)... INFO: INFO: Initiating Ajax GET request on resources/wicket.contrib.gmap.GMap2/wicket-gmap.js INFO: Invoking pre-call handler(s)... INFO: Received ajax response (7079 characters) INFO: focus removed from setTargets15 INFO: Invoking post-call handler(s)... ERROR: Exception evaluating javascript: [object Error] INFO: Response processed successfully. INFO: Invoking post-call handler(s)... INFO: focus set on setTargets15 INFO: focus removed from setTargets15 INFO: last focus id was not set INFO: focus set on wicketDebugLink INFO: focus removed from wicketDebugLink INFO: focus set on wicketDebugLink INFO: focus removed from wicketDebugLink -- View this message in context: http://www.nabble.com/GMap2-or-Wicket-Ajax-issue--tp19859974p19860544.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]
GMap2 or Wicket Ajax issue?
I am trying to get the latest GMap2 in wicketstuff to work with Wicket 1.3.4 (can't upgrade to 1.4 just yet) As the mvn repository only is applicable to 1.4, I downloaded the sources and adjusted the two places that would not compile (both specifically dealing with generics) However, when I run my application, I am trying to pop up a Modal window with a GMap2 instance in it. When I click the AjaxLink and show the window, I get the following error in my console: java.io.IOException: The filename, directory name, or volume label syntax is incorrect at java.io.WinNTFileSystem.canonicalize0(Native Method) at java.io.Win32FileSystem.canonicalize(Win32FileSystem.java:395) at java.io.File.getCanonicalPath(File.java:531) at org.mortbay.resource.FileResource.getAlias(FileResource.java:184) at org.mortbay.jetty.servlet.DefaultServlet.getResource(DefaultServlet.java:275) at org.mortbay.jetty.servlet.DefaultServlet.doGet(DefaultServlet.java:375) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:487) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1098) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:246) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at com.positiontech.hib.HibernateFilter$$M$1a2d7b4a.doFilter(HibernateFilter.java:67) at com.positiontech.hib.HibernateFilter$$A$1a2d7b4a.doFilter() at com.positiontech.hib.HibernateFilter.doFilter() at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:295) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:503) at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:827) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:511) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:210) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:379) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:361) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442) When I view the Ajax Debug Console, it contains the following information: INFO: focus set on INFO: focus removed from INFO: focus set on setTargets15 INFO: Using XMLHttpRequest transport INFO: INFO: Initiating Ajax GET request on ?wicket:interface=:4:contractForm:advertising:setTargets::IBehaviorListener:0:&random=0.5156089011856273 INFO: Invoking pre-call handler(s)... INFO: Received ajax response (4665 characters) INFO: INFO: Response parsed. Now invoking steps... INFO: INFO: Initiating Ajax GET request on http://www.google.com/jsapi?key=ABQIzaZpf6nHOd9w1PfLaM9u2xQRS2YPSd8S9D1NKPBvdB1fr18_CxR-svEYj6URCf5QDFq3i03mqrDlbA INFO: Invoking pre-call handler(s)... ERROR: Received Ajax response with code: 404 INFO: Invoking post-call handler(s)... INFO: Invoking failure handler(s)... INFO: focus removed from setTargets15 I appears that http://www.google.com/jsapi?key=ABQIzaZpf6nHOd9w1PfLaM9u2xQRS2YPSd8S9D1NKPBvdB1fr18_CxR-svEYj6URCf5QDFq3i03mqrDlbA is returning a 404 in the Ajax call. However, when I copy paste the code into a browser...it works. I then stepped through the Debugger to see what the real request was and I believe I am seeing /local/http://www.google.com/jsapi?key=ABQIzaZpf6nHOd9w1PfLaM9u2xQRS2YPSd8S9D1NKPBvdB1fr18_CxR-svEYj6URCf5QDFq3i03mqrDlbA which is invalid. I paste that in the browser and I do get the offending error message when I see in the console. So I am not sure if this is a GMap2 issue or is it a Wicket Ajax issue. I guess my real question is...does anyone know how to fix this? or where I should look to fix this? Thanks - Doug -- View this message in context: http://www.nabble.com/GMap2-or-Wicket-Ajax-issue--tp19859974p19859974.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]
Restricting Javascript entry in TextField/TextArea
Is there a way to restrict either on the front end or some validator on the backend in Wicket to identify if a field has Javascript within the submitted value? We have a requirement for this as the data will be redisplayed in HTML emails and don't want the recipients being open to malicious code. Thanks - Doug -- View this message in context: http://www.nabble.com/Restricting-Javascript-entry-in-TextField-TextArea-tp18758723p18758723.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: Checkbox tree component
I am sure there are a couple of ways to do this. First thing that comes to mind is to override the Panel2.isVisible() method and return true if there are any nodes selected in CBTree1. for instance: Panel checkBoxPanel2 = new Panel( "checkBoxPanel2" ) { public boolean isVisible() { return /** cbTree1 Selection State **/; } }; To determine the cbTree1 Selection State, either you iterator through the entire tree to determine if a node is selected via the TreeState or capture the number of nodes selected/deselected via TreeStateListener. By overridding isVisible(), no matter if you are refreshing the entire page or via Ajax, the checkBoxPanel2 visibility would be handled correctly. Hope that helps. - Doug -- View this message in context: http://www.nabble.com/Checkbox-tree-component-tp13433102p18327178.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: wicketstuff yui context menu clashes with YUI menu
Karen, I am the original author of the menu2 package. What I believe is happening (as I haven't looked at this in awhile) is that YUI menu that is created originally is losing the 'reference' of the item that had the context menu associated with it. This happens because you are using Ajax to refresh data view and not the menu too. I believe to fix you will need to add the menu component that contains the YuiContextMenuBehavior to the AjaxTarget. If this doesn't work, please post some example code or send me a quick start to reproduce so I can take a look. - Doug -- View this message in context: http://www.nabble.com/wicketstuff-yui-context-menu-clashes-with-YUI-menu-tp18305922p18320478.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: Checkbox tree component
If the tree is pre-loaded, it is easier. When the checkbox is selected, iterate through the children nodes and set its state to selected. The dynamically loaded is alot trickier...as you would have to load the tree from the selected node and then iterate and set the children notes to selected. Are you sure you want to select the children nodes or is it the parent nodes you want to select? -- View this message in context: http://www.nabble.com/Checkbox-tree-component-tp13433102p18173927.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: Checkbox tree component
It depends. Are you building the entire tree up front or are you building the child nodes dynamically (i.e. when the parent node is selected/expanded)? -- View this message in context: http://www.nabble.com/Checkbox-tree-component-tp13433102p18147561.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]
ModalWindow / zindex
Is there a way to programatically change the zindex for the modalwindow? I am having issue where the ModalWindow is being placed behind images on my page (actually behind an iframe). I search in this forum but I have tried several suggestions but they didn't work. -- View this message in context: http://www.nabble.com/ModalWindow---zindex-tp17154922p17154922.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: Fragment issue
Here is something interesting... I changed my DataView to ListView and now it works. Any known issue in using a DataView over a ListView in this given circumstance? -- View this message in context: http://www.nabble.com/Fragment-issue-tp17116545p17117671.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: Fragment issue
Sorry...I forgot to add the first time. Here it is. org.apache.wicket.WicketRuntimeException: component replacements:replacement:1:replacementFragment:editPhone not found on page com.positiontech.local.wicket.main.advertiser.advertiser.newCampaign.NewCampaignReplacements[id = 6], listener interface = [RequestListenerInterface name=ILinkListener, method=public abstract void org.apache.wicket.markup.html.link.ILinkListener.onLinkClicked()] at org.apache.wicket.request.AbstractRequestCycleProcessor.resolveListenerInterfaceTarget(AbstractRequestCycleProcessor.java:416) at com.positiontech.local.wicket.LocalApplication$1.resolveListenerInterfaceTarget() at org.apache.wicket.request.AbstractRequestCycleProcessor.resolveRenderedPage(AbstractRequestCycleProcessor.java:461) at com.positiontech.local.wicket.LocalApplication$1.resolveRenderedPage() at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:139) at com.positiontech.local.wicket.LocalApplication$1.resolve() at org.apache.wicket.RequestCycle.step(RequestCycle.java:1224) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1331) at org.apache.wicket.RequestCycle.request(RequestCycle.java:493) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:363) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:194) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at com.positiontech.hib.HibernateFilter$$M$d0d29e4c.doFilter(HibernateFilter.java:67) at com.positiontech.hib.HibernateFilter$$A$d0d29e4c.doFilter() at com.positiontech.hib.HibernateFilter.doFilter() at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:295) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:503) at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:827) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:511) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:210) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:379) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:361) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442) -- View this message in context: http://www.nabble.com/Fragment-issue-tp17116545p17117641.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]
Fragment issue
Sorry for duplicate post...selected the wrong button. I have a DataView and for each 'row', I add a different fragment based on the object model type. However, in each fragment I have a link (edit). The page displays fine. But when I select on the link, wicket indicates that that link interface is not found. What is even more interesting, when I had the link as an AjaxLink, the first click produces the same error.. but when I back button and select again, the AjaxLink works. If anyone knows what I need to look at, please let me know. I am perplexed where to start looking. Thanks - Doug FYI...some additional information that may be handy... The resultant interface path is: replacements:replacement:1:replacementFragment:editPhone where editPhone is the link. The replacementFragment is actually replaced with a phoneFragment to display the editPhone link. The offending code is as follows: (only applicable code and hopefully the HTML will be displayed nicely) dataView = new DataView("replacement", new ListDataProvider(dataList)) { public void populateItem(Item item) { item.setRenderBodyOnly(true); ReplacementElement data = (ReplacementElement) item .getModelObject(); if (data instanceof PhoneReplacement) { item.add(new PhoneFragment("replacementFragment", NewCampaignReplacementsEditPanel.this, (PhoneReplacement) data)); } else if (data instanceof ImageReplacement) { item.add(new ImageFragment("replacementFragment", NewCampaignReplacementsEditPanel.this, (ImageReplacement) data)); } else if (data instanceof FlashReplacement) { item.add(new FlashFragment("replacementFragment", NewCampaignReplacementsEditPanel.this, (FlashReplacement) data)); } else { throw new RuntimeException( "Unexpected replacement element: " + data); } } }; add(dataView); private class PhoneFragment extends Fragment { public PhoneFragment(String id, MarkupContainer markupProvider, final PhoneReplacement phone) { super(id, "phoneFragment", markupProvider); this.setRenderBodyOnly(true); add(new ListSelectAjaxCheckBox("id", new ListSelectCheckBoxModel(selectedIds, phone .getTransformID(; add(new Label("from", new PropertyModel(phone, "fromPhone.formatted"))); add(new Label("type", new PropertyModel(phone, "phoneType.label"))); add(new Label("to", new PropertyModel(phone, "toPhone.formatted"))); Link edit = new Link("editPhone") { public void onClick() { setResponsePage(new PhoneReplacementDetailPage(getPage(), phone)); } }; add(edit); } } < table> < tr> < td class="tableHeader">Use < td class="tableHeader" width="50">Type < td class="tableHeader" width="100">From < td class="tableHeader" width="100">To < td class="tableHeader" width="50"> < /tr> < div wicket:id="replacement"> < tr wicket:id="replacementFragment"> < /div> < /table> < wicket:fragment wicket:id="phoneFragment"> < tr> < td> < td>Phone < td> < td>[] < td align="center"> # Edit < /tr> < /wicket:fragment> -- View this message in context: http://www.nabble.com/Fragment-issue-tp17116545p17116545.html Sent from the Wicket - User mailing list archive at Nabble.com. -
Form submit with a FileUploadField appears not to work
I just recently upgraded to 1.3.3 from 1.3.2 as there was a bug that was fixed in 1.3.2 (https://issues.apache.org/jira/browse/WICKET-1442) that I was getting. However, in my AjaxButton.onSubmit( AjaxRequestTarget target, Form form ) when I call my FileUploadField.getFileUpload() it is always null. Any suggestions? Note: I submitting my form in a ModalWindow. Here is my code: public class NewImageTransformPanel extends LocalBasePanel { private FileUploadField fileUpload; private ImageTransform image; public NewImageTransformPanel(final ModalWindow window, final Integer campaignId) { super(window.getContentId()); image = new ImageTransform(); Form form = new Form("transformForm"); form.setOutputMarkupId(true); add(form); form.add(new PTFeedbackPanel("feedback").setOutputMarkupId(true)); form.setModel(new CompoundPropertyModel(image)); form.add( new RequiredTextField( "imageFileName" )); fileUpload = new FileUploadField("imageFile"); form.setMultiPart( true ); form.add(fileUpload); form.add(new AjaxButton("addTransform") { public void onSubmit(AjaxRequestTarget target, Form form) { try { String fileName = fileUpload.getFileUpload() .getClientFileName(); <=== NPE every time String contentType = fileUpload.getFileUpload() .getContentType(); byte[] content = fileUpload.getFileUpload().getBytes(); if (StoredImage.isAllowed(contentType) == false) { error("File type is not supported. " + "Supported types are JPEG, GIF, and PNG."); target.addComponent(form); return; } image.setImageContentType(contentType); image.setImageContent(content); CampaignMgr.getInstance().addImageTransform(campaignId, image); info("Image transformation was added successfully."); window.close(target); } catch (Exception e) { e.printStackTrace(); error(e); target.addComponent(form); } } @Override protected void onError(AjaxRequestTarget target, Form form) { target.addComponent(form); } }); form.add(new AjaxLink("cancel") { public void onClick(AjaxRequestTarget target) { window.close(target); } }); } } -- View this message in context: http://www.nabble.com/Form-submit-with-a-FileUploadField-appears-not-to-work-tp16795627p16795627.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 as a template generator
I believe the following is the correct way (it works from my point of view). Are there any issues that I need to be aware of? Is there a better way? Thanks - Doug Note: this method is called in either a Link or Button: public BaseTemplate extends WebPage { public String generateHTML() { StringResponse stringResponse = new StringResponse(); WebResponse originalResponse = (WebResponse) RequestCycle.get() .getResponse(); try { RequestCycle.get().setResponse(stringResponse); this.render(); } finally { RequestCycle.get().setResponse(originalResponse); } return stringResponse.toString(); } } -- View this message in context: http://www.nabble.com/Wicket-as-a-template-generator-tp16609133p16610499.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 as a template generator
I believe this is possible but want to be sure and be efficient about it. Is it possible to create a Wicket Page and capture the generated HTML text from with-in a Button.onSubmit()? The page will not be displayed in the current wicket app. This page is only a 'template' to generate the HTML. The resultant HTML will not have any links back into a wicket based app. It will be served from another web server. If so, what is the best way to do this? TIA, - Doug -- View this message in context: http://www.nabble.com/Wicket-as-a-template-generator-tp16609133p16609133.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: [vote] Release 1.4 with only generics and stop support for 1.3
[ X ] +1, Wicket 1.4 is 1.3 + generics, drop support for 1.3 [ ] -1, I need a supported version running on Java 1.4 -- View this message in context: http://www.nabble.com/-vote--Release-1.4-with-only-generics-and-stop-support-for-1.3-tp16090054p16100542.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: Conditional markup
There are actually many ways to what you want: 1) use fragments. to be used during the construction of the containing component 2) utilize isVisible() add( new Label( "myLabel" ) { public boolean isVisible() { return (if equal to my condition); } } ); This way dynamically adjusts the display without having to recreate the containing component. The drawback is that it is always added to the component hierarchy (but is that a drawback ;-) I am sure there are other ways but these I have used to date. - Doug -- View this message in context: http://www.nabble.com/Conditional-markup-tp16048105p16048355.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: right click popup context menu
In the populateItem, you will need to do the following: contextMenuBehavior.applyAttributes(item, popupMenu, new Model( rowId)); Where rowId is the value you are looking for when the action has been selected (the targetId in the onClick method) private class MyAction extends AbstractYuiMenuAction implements IYuiMenuAjaxAction { public void onClick(AjaxRequestTarget target, String targetId) { // targetId == the rowId in applyAttributes } } -- View this message in context: http://www.nabble.com/right-click-popup-context-menu-tp15876468p15908004.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]