wicket

Modify Attribute of Wicket ComponentTag Parent

纵然是瞬间 提交于 2020-01-05 02:53:29
问题 I have a Wicket Form. Within this form there are a few input tags. These input tags are put into div containers. These div containers "make" the style (i.e. they have style classes). I want to access this style of the div tag, if the validation of the child input fails. I tried to do this with a Behavior, but I cannot access the div tag (which would be the parent of the input tag). Any ideas how I can modify the style of the parent div tag if validation fails? <div style="myStyle"> <label

How to change Wicket behaviour on Page Expired

前提是你 提交于 2020-01-04 13:42:08
问题 We have a wicket application for our main website. Lately we have implemented a mobile version of the site. The mobile version is special in that it is deployed inside a native app wrapper to some mobile devices and not connected to the rest of the page through links because it is not supposed to be normally visible to web users. The mobile page makes use of ajax and is therefore prone to receive "Page expired" errors for example when we restart the application on the server. Since that page

How to change Wicket behaviour on Page Expired

断了今生、忘了曾经 提交于 2020-01-04 13:41:50
问题 We have a wicket application for our main website. Lately we have implemented a mobile version of the site. The mobile version is special in that it is deployed inside a native app wrapper to some mobile devices and not connected to the rest of the page through links because it is not supposed to be normally visible to web users. The mobile page makes use of ajax and is therefore prone to receive "Page expired" errors for example when we restart the application on the server. Since that page

Customizing IndicatingAjaxLink in wicket

社会主义新天地 提交于 2020-01-03 09:10:14
问题 in my current project i've faced a problem of customizing IndicatingAjaxLink in wicket, is there any solution to change standart gif image to my own? For example we have following listeneer add(new IndicatingAjaxLink("closeReceivedBillspanel") { public void onClick(AjaxRequestTarget art) { // some timeconsuming calculations } }); as user clicks this link, the gif with loading appears, and i want to change this gif, is there any solution for this problem? 回答1: Have your page implements the

Open new Tab when button is clicked

有些话、适合烂在心里 提交于 2020-01-03 03:13:11
问题 using wicket I want to open a new tab when a button or link is clicked, how can I achieve it? what I have managed to do is to open it in a pop up like this: PopupSettings popupSettings = new PopupSettings("popuppagemap").setLeft(0).setHeight(500).setWidth(500).setHeight(0); // Popup example final Link<Void> setPopupSettings = new BookmarkablePageLink<Void>("searchBtn", HomePage.class) .setPopupSettings(popupSettings); but this opens it in a new window. 回答1: no problem to open a link in a new

How can I begin using Wicket? [closed]

给你一囗甜甜゛ 提交于 2020-01-02 07:30:07
问题 As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. Closed 8 years ago . I installed Wicket per the rules of the Wicket site. How do I run Wicket within my IDE, Eclipse? I have added all the necessary plug

How to send binary multipart formdata as base64? [duplicate]

蓝咒 提交于 2020-01-01 03:12:49
问题 This question already has answers here : Closed 7 years ago . Possible Duplicate: How can you encode to Base64 using Javascript? I have a web application based on Java, Wicket and JQuery which has a function to enable users to upload files (images, pdfs, rtf) through multipart/form-data. Our web security infrastructure does filtering of all http traffic to pick up possibly malicious content e.g. XSS attacks, SQL injection, buffer overruns etc The filter doesn't distinguish between normal text

Wicket checkbox that automatically submits its changed value to domain object

我怕爱的太早我们不能终老 提交于 2020-01-01 02:45:10
问题 What's the cleanest way I can make a checkbox automatically submit the form it belongs to in Wicket? I don't want to include a submit button at all. The checkbox is backed by a boolean field in a domain object ("Account" in this case). Simplified example with irrelevant parts omitted: EntityModel<Account> accModel = new EntityModel<Account>(Account.class, id); PropertyModel<Boolean> model = new PropertyModel<Boolean>(accModel, "enabled"); CheckBox checkBox = new CheckBox("cb", model); Form

How to intercept custom HTTP header value and store it in Wicket's WebSession?

泄露秘密 提交于 2019-12-30 07:53:10
问题 I need to grab a certain custom HTTP header value from every request and put it in WebSession so that it will be available on any WebPage later on. (I believe the Wicket way to do this is to have a custom class extending WebSession that has appropriate accessors.) My question is, what kind of Filter (or other mechanism) I need to be able to both intercept the header and access the WebSession for storing the value? I tried to do this with a normal Java EE Filter, using CustomSession session =

Wicket: how to redirect to another page?

烈酒焚心 提交于 2019-12-29 14:16:49
问题 How do I redirect to another page using Wicket? IIRC, some exception has to be thrown in the constructor, but I don't remember which one. Thanks in advance. 回答1: Throwing a RestartResponseAtInterceptPageException will do it, as you noted in your own answer, but that's really part of a system for allowing a redirect with an eventual continuation at the current page (frequently part of an authorization process). If that's not your situation, but you still have to do something that interrupts