Re: [Wicket-user] [Question] wicket.markup.html.form.Radio

2007-08-13 Thread Igor Vaynberg
because browsers suck :)

-igor


On 8/13/07, jq58 [EMAIL PROTECTED] wrote:


 Yep, that did it.  Still  a little confused as to why the onchange did not
 work.

 Thanks to everyone for their suggestions.



 Alex Objelean wrote:
 
  You mean that in IE you have to click twice?
  Use onclick event instead...
 
 
 
  jq58 wrote:
 
  This works to an extent.  It appears that sometimes (totally random as
  far as I can tell) I have to click twice to get it to actually invoke
 the
  ajax action.
 
  But, once it is invoked, I am trying to enable the drop down and
 disable
  the text box via:
  [code]
private void setupAjaxRadio(final Panel panel,
final RadioGroup radioGroup,
final Radio radio) {
  radioGroup.add(radio.add(new AjaxEventBehavior(onchange) {
 
   private static final long serialVersionUID = 1L;
   protected void onEvent(AjaxRequestTarget target) {
   radioGroup.processInput();
   if
  (radioGroup.getConvertedInput().equals(
 Component.getApplyToRadioGroupChoices().get(Component.AMOUNT_TYPE_GLOBAL))
  ) {
   radioGroup.get
 (percentGFId).setEnabled(true);
   radioGroup.get
 (amount).setEnabled(false);
   } else {
   radioGroup.get
 (percentGFId).setEnabled(false);
   radioGroup.get(amount).setEnabled(true);
   }
   target.addComponent(panel);
   }
  [/code]
 
  However, the enabling and disabling of the controls under the radio
 group
  are being ignored.
  Any idea why?
 
  Thanks.
 
  Kent Tong wrote:
 
  Alex Objelean alexandru.objelean at isdc.ro writes:
 
  Thank you Jan! Sad thing is that 1.2.x branch will never support this
  feature.
 
  Try:
 
  Form f = ...;
  RadioGroup rg2 = new RadioGroup(rg2, ...);
  rg2.setOutputMarkupId(true);
  setupAjaxRadio(f, rg2, new Radio(r3, new Model(abc)));
  setupAjaxRadio(f, rg2, new Radio(r4, new Model(def)));
  ...
 
private void setupAjaxRadio(final Form form,
final RadioGroup radioGroup,
final Radio radio) {
  radioGroup.add(radio.add(new AjaxEventBehavior(onchange) {
protected void onEvent(AjaxRequestTarget target) {
  radioGroup.processInput();
  target.addComponent(form);
}
protected CharSequence getEventHandler() {
  return getCallbackScript(new AppendingStringBuffer(
  wicketAjaxPost(').append(getCallbackUrl()).append(
  ', wicketSerialize(document.getElementById('
  + radio.getMarkupId() + '))), null, null);
}
 
  }));
}
 
 
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 
 
 
 

 --
 View this message in context:
 http://www.nabble.com/-Question--wicket.markup.html.form.Radio-tf3926549.html#a12126632
 Sent from the Wicket - User (OLD) mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Custom ISessionStore

2007-08-09 Thread Igor Vaynberg
DiskPageStore , SecondLevelCacheSessionStore in core

-igor


On 8/9/07, Seldon, Richard [EMAIL PROTECTED] wrote:


 Hello. Does anyone have any working example implementations of a custom
 ISessionStore.
 Perhaps writing to disk / database etc. Hoping to get up to speed
 v.quickly.
 Best regards,

 Richard.


 This e-mail (and any attachments) may contain privileged and/or
 confidential information. If you are not the intended recipient please do
 not disclose, copy, distribute, disseminate or take any action in reliance
 on it. If you have received this message in error please reply and tell us
 and then delete it. Should you wish to communicate with us by e-mail we
 cannot guarantee the security of any data outside our own computer systems.
 For the protection of Legal  General's systems and staff, incoming emails
 will be automatically scanned.

 Any information contained in this message may be subject to applicable
 terms and conditions and must not be construed as giving investment advice
 within or outside the United Kingdom.

 The following companies are subsidiary companies of the Legal  General
 Group Plc which are authorised and regulated by the Financial Services
 Authority for advising and arranging the products shown: Legal  General
 Partnership Services Limited (insurance and mortgages), Legal  General
 Insurance Limited (insurance), Legal  General Assurance Society Limited
 (life assurance, pensions and investments), Legal  General Unit Trust
 Managers Limited and Legal  General Portfolio Management Services Limited
 (investments).

 They are registered in England under numbers shown.
 The registered office is Temple Court, 11 Queen Victoria Street, London
 EC4N 4TP.

 Legal  General Partnership Services Limited: 5045000 Legal  General
 Assurance Society Limited: 166055 Legal  General (Unit Trust Managers)
 Limited: 1009418 Legal  General (Portfolio Management Services) Limited:
 2457525 Legal  General Insurance Limited: 423930

 They are registered with the Financial Services Authority under numbers
 shown. You can check this at www.fsa.gov.uk/register

 Legal  General Partnership Services Limited: 300792 Legal  General
 Assurance Society Limited: 117659 Legal  General (Unit Trust Managers)
 Limited: 119273 Legal  General (Portfolio Management Services) Limited:
 146786 Legal  General Insurance Limited: 202050


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Replace non-wicket attributed sections of a html document

2007-08-08 Thread Igor Vaynberg
it is a global thing, so it will be applied to all request.

getRequestCycleSettings().getResponseFilters().add(new MyFIlter());

-igor


On 8/8/07, Tremelune [EMAIL PROTECTED] wrote:


 Hm, still a good question. How do you get the IResponseFilter in there?
 There
 doesn't seem to be a way to do anything with the RequestCycle, and
 getApplication().getRequestCycleSettings() doesn't seem to have a place to
 set the IResponseFilter...I would also like to ensure that the custom
 response filter that does the FreeMarkering is only applied to the current
 request. Any tips/snippets?




 Andrew Moore wrote:
 
  Thanks again igor (you always seem to be able to fix any problems I'm
  having getting to grasps with wicket)
  I've now got a basic IResponseFilter running that will stick data into
  freemarker tags.
 
  At the moment though I'm creating a HashMap of values to put into
  freemarker directly in the Filter (just for testing purposes), whereas I
  really want to create a HashMap in the page I'm currently generating and
  either pass, or make it available to the filter, but I can't think how I
  would do that.
 
  So, how to I get data from the Page Class I have to the IResponseFilter?
  All the examples I could find, just use data directly available from the
  FilterClass (like system time).
 
  Thanks again,
  Andrew
 
 
 
 

 --
 View this message in context:
 http://www.nabble.com/Replace-non-wicket-attributed-sections-of-a-html-document-tf3636913.html#a12063101
 Sent from the Wicket - User (OLD) mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] wicketstuff-hibernate-behavior

2007-08-08 Thread Igor Vaynberg
some projects have small scope, and once that scope is covered there is
simply nothing more to do. have you checked it out - does something not work
for you?

-igor


On 8/8/07, Craig Lenzen [EMAIL PROTECTED] wrote:


 Does anyone know if this project is active or not? IE, is someone actively
 doing development on this project?

 Thanks
 Craig
 --
 View this message in context:
 http://www.nabble.com/wicketstuff-hibernate-behavior-tf4240106.html#a12064913
 Sent from the Wicket - User (OLD) mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Replace non-wicket attributed sections of a html document

2007-08-08 Thread Igor Vaynberg
you couldve used a freemarkerpanel i suppose. depends on the usecase.

-igor


On 8/8/07, Andrew Moore [EMAIL PROTECTED] wrote:


 Hi,
 I didn't find a solution, I ended up just using freemarker and servlets
 for
 pages where I needed to do this which isn't too bad for me as I've two
 main
 sections to my application one uses wicket and the other uses freemarker.



 Have you come up with workable code? I'm about to do what you have just
 done
 with freemarker.




 Andrew Moore wrote:
 
  Thanks again igor (you always seem to be able to fix any problems I'm
  having getting to grasps with wicket)
  I've now got a basic IResponseFilter running that will stick data into
  freemarker tags.
 
  At the moment though I'm creating a HashMap of values to put into
  freemarker directly in the Filter (just for testing purposes), whereas I
  really want to create a HashMap in the page I'm currently generating and
  either pass, or make it available to the filter, but I can't think how I
  would do that.
 
  So, how to I get data from the Page Class I have to the IResponseFilter?
  All the examples I could find, just use data directly available from the
  FilterClass (like system time).
 
  Thanks again,
  Andrew
 
 
 
 
  igor.vaynberg wrote:
 
 
 
 
 
 

 --
 View this message in context:
 http://www.nabble.com/Replace-non-wicket-attributed-sections-of-a-html-document-tf3636913.html#a12066643
 Sent from the Wicket - User (OLD) mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] How to display different input type in one column

2007-08-07 Thread Igor Vaynberg
you need to create two fragments - one with markup for a textfield, and one
with markup for a dropdown. then add the appropriate fragment.

-igor


On 8/7/07, rtow [EMAIL PROTECTED] wrote:


 I have a column that needs to display either dropDownChoice or text.

 dataViewPanel.html
   tr wicket:id=datatable
 td

 /td
 td
 input type=text wicket:id=value /
  /td
   /tr
 /table

 dataView.java
 protected void populateItem(Item item)
 {
 Config gc = (Config) item.getModelObject();
 item.setModel(new CompoundPropertyModel(gc));

 item.add(new Label(name));
 item.add(new TextField(value));
 }

 My question is: depends on value of name, I like to render the value
 column as either dropDownChoice or text.

 thanks,
 richard
 --
 View this message in context:
 http://www.nabble.com/How-to-display-different-input-type-in-one-column-tf4234287.html#a12047116
 Sent from the Wicket - User (OLD) mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Model for form with variable number of fields

2007-08-04 Thread Igor Vaynberg
dont use a compound model, that is just a shortcut for common cases.

create a model that keeps an index and a ref to the list model, and pulls
things in and out like that.

class indexedmodel implements imodel {
  private final imodel list;
  private final int index;

  getobject() { return list.getobject().get(index); }
  setobject(object o) { list.getobject().set(index, o); }
  detach() { list.detach(); }
}

and pass one of those to the dropdownchoice

-igor


On 8/4/07, Tauren Mills [EMAIL PROTECTED] wrote:

 Hello,

 I have a process that reads a CSV data file.  The data contains lists
 of people, but the number of fields, the order and the type of fields
 can vary from one CSV to another.

 Because the data in each column is unknown, a form is displayed with a
 preview of the data in a table.  The table column headers contain
 dropdown list of possible field types for each column in the csv file.
 I'm using a RepeatingView to generate the headers.

 The problem is, I'm unclear how to design the CompoundPropertyModel
 for the form.  I assume my model needs to contain a collection of some
 sort since I have a varying number of field.  But how do I map the set
 of RepeatingView-WebMarkupContainer-DropDownChoice objects to the
 model as a collection?

 Here's the code:

 preview = importer.previewImport(new FileInputStream(dataFile),10,2);
   ...
 RepeatingView headers = new RepeatingView(header);
 form.add(headers);
 int numFields = preview.getRecords()[0].getFields().length;
 for (int j = 0; j  numFields; j++) {
   WebMarkupContainer cell = new WebMarkupContainer(headers.newChildId());
   headers.add(cell);
   cell.add(new EdiCriteriaDropDownChoice(criteria).setRequired(true));
 }

 And the markup:

 table cellspacing=1
   tr
 th wicket:id=header
 select name=select
 wicket:id=criteria/select
 /th
   /tr
...
 /table

 What kind of model would work with this?

 Thanks,
 Tauren

 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] DownloadLink for an external URL

2007-08-02 Thread Igor Vaynberg
whatever streams that external file has to set a
content-disposition:attachment header so the browser pops up that box.

-igor


On 8/2/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:

 I see that DownloadLink can be used to stream a File.

 What I want to do is use DownLoadLink to redirect to  an external URL
 that should be streamed (i.e. File Save box should pop up).

 I can't use ExternalLink as the external URL's location is not pre
 determined,
 also the external URL's location lookup is a costly so I don't want to do
 it unless
 the User clicks on a link.

 So in my case I do some thing like

 class DownloadUrlLink {

 onClick() {

   URL externalUrl = getExternalURL(); //this is a costly operation, so I
 don't want to do it unless user clicks the Download link.
 getRequestCycle().setRequestTarget(new RedirectRequestTarget(url.toString
 ()));

 }

 }

 The URL points to a rather large gzipped XML file about 11MB in size.
 But instead of popping up a File Save dialog, the browser starts to
 display the XML file.
 and CPU usage jumps up to 100%, on account of the file being this large.

 Is there a way to force the browser to pop up a FileSave dialog when using
 RedirectRequestTarget

 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Showing an alert

2007-08-02 Thread Igor Vaynberg
class alert extends abstractbehavior {
 boolean istemporary() { return false; }
 void renderhead(iheaderresponse r) {
renderonloadjavascript(alert('error!');); }
}

form searchform=new form(...) {
  onerror() { add(new alert(); }
}

-igor


On 8/2/07, Federico Fanton [EMAIL PROTECTED] wrote:

 Hi everyone!
 I'm sorry, I'm looking for a way to show an alert dialog when a condition
 is met.. For example, the user fills in a search form, submits it and if
 there's no data matching the query, a no data found! should pop up.. I'd
 like to use something like the alert JavaScript function, but I'm a bit
 confused about where to put it.. ^^;
 Should I load the relevant information (wether there's data or not from
 the query) in a certain component and then look it up from an onLoad
 function that would show the alert accordingly? Is there a Wicket way to
 do this?
 Many thanks for your time!


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Updates within Panels in datatable

2007-08-01 Thread Igor Vaynberg
On 8/1/07, salmas [EMAIL PROTECTED] wrote:


 Hi Igor:

 I cannot use the AjaxSubmitButton because I need to change the button's
 model dynamically and this functionality is broken in Wicket 1.2 and I
 can't
 use the 1.3 beta because my company doesn't want to use beta software for
 a
 production release. I ended up using a regular Button and then updating
 the
 table using an AJAX Target in the buttons onSubmit method. Please do let
 me
 know if you have a better suggestion for what I can do here.


nothing other then upgrade to 1.3


I tried
 ReuseIfModelsEqualStrategy strategy = new
 ReuseIfModelsEqualStrategy();
 table.setItemReuseStrategy(strategy);

 but this did not help. Do I need to create a custom strategy? If so what
 should I do in it?


no, you need to override equals and hashcode on whatever model is returned
by idataprovider

-igor


igor.vaynberg wrote:
 
  On 7/31/07, salmas [EMAIL PROTECTED] wrote:
 
  - Even though I do nothing in onSubmit (which I know does get called)
 the
  table is reloaded (button.getRequest() shows the request for the page
 to
  reload). I'd like to stop the auto redraw and do an AJAX update from
  within
  onSubmit instead, I am not sure how to stop the table reload when the
  button
  is clicked.
 
 
  use ajax submit button
 
  - from within onSubmit() in panel2 the textfield and the radio button in
  panel1 show their original values and not the values that I typed in
  prior
  to pressing the button. The widgets have PropertyModels. To load the
  panels
  I overrode public void populateItem(Item item, String componentId,
 IModel
  model) in the table columns and then added the panels where
 appropriate.
  What can I do to update the data in panel1 when the button in Panel2 is
  clicked?
 
 
  see datatable.setitemreusestrategy(...)
 
  -igor
 
 
  --
  View this message in context:
 
 http://www.nabble.com/Updates-within-Panels-in-datatable-tf4196594.html#a11935400
  Sent from the Wicket - User (OLD) mailing list archive at Nabble.com.
 
 
 
 -
  This SF.net email is sponsored by: Splunk Inc.
  Still grepping through log files to find problems?  Stop.
  Now Search log events and configuration files using AJAX and a browser.
  Download your FREE copy of Splunk now   http://get.splunk.com/
  ___
  IMPORTANT NOTICE:
 
  This mailing list is shutting down. Please subscribe to the Apache
 Wicket
  user list. Send a message to: users-subscribe at wicket.apache.org
 and
  follow the instructions.
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 -
  This SF.net email is sponsored by: Splunk Inc.
  Still grepping through log files to find problems?  Stop.
  Now Search log events and configuration files using AJAX and a browser.
  Download your FREE copy of Splunk now   http://get.splunk.com/
  ___
  IMPORTANT NOTICE:
 
  This mailing list is shutting down. Please subscribe to the Apache
 Wicket
  user list. Send a message to: users-subscribe at wicket.apache.org and
  follow the instructions.
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

 --
 View this message in context:
 http://www.nabble.com/Updates-within-Panels-in-datatable-tf4196594.html#a11951843
 Sent from the Wicket - User (OLD) mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org 

Re: [Wicket-user] How to set a date on backing model obj from contents of drop down lists?

2007-07-31 Thread Igor Vaynberg
if you really want something that binds to the Date then create 3 models,
each adjusting the specific portion of the date, for example:

class YearModel implements IModel {
 private final IModel date;

  Object getObject() {return date.getObject().getYear();}
  void setObject(Object o) { date.getObject().setYear((Integer)o); }
   void detach() { date.detach(); }
}

-igor



On 7/31/07, David Leangen [EMAIL PROTECTED] wrote:


 One suggestion: what about having a date pojo like:

 public class MyDate
 {
   get/setMonth()
   get/setDay()
   get/setYear()

   public Date getDate()
   {
  // translate object state into a Date object
   }
 }


 Then use PropertyModel to get/set the individual fields:

 Component myComponent = new WhateverComponent( id, new
 PropertyModel( myDate, fieldOfDate );


 That should work.


 Maybe more experienced people know of a more elegant way, though this
 way's not so bad.


 Cheers,
 Dave




 On Mon, 2007-07-30 at 23:45 -0700, Justin Morgan (Logic Sector) wrote:
  Hi all,
 
  Sorry for the potentially noobish question, but I'm not sure how to
  go about this in Wicket...
 
  I need to set a Date on a form's model object by way of three drop
  down lists.  The drop downs look something like this:
 
  Drop down 1 contents:  Month, January, February, ..., December
  Drop down 2 contents:  Day, 1, 2, ..., 31
  Drop down 3 contents:  Year, 2007, 2006, ..., 1907
 
  Clicking the Submit button on the form will save a single
  java.util.Date object on the form's backing model object based on the
  aggregate values of the three lists' selections.
 
  Thanks for any suggestions,
 
  Justin
 
 
 -
  This SF.net email is sponsored by: Splunk Inc.
  Still grepping through log files to find problems?  Stop.
  Now Search log events and configuration files using AJAX and a browser.
  Download your FREE copy of Splunk now   http://get.splunk.com/
  ___
  IMPORTANT NOTICE:
 
  This mailing list is shutting down. Please subscribe to the Apache
 Wicket user list. Send a message to: users-subscribe at wicket.apache.org
 and follow the instructions.
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] QWicket

2007-07-31 Thread Igor Vaynberg
the author of qwicket is allergic to maven, so you will have to configure
the project yourself

-igor


On 7/31/07, winlaw [EMAIL PROTECTED] wrote:


 HI

 I a new to Wicket and have downloaded the QWicket quickstart but it has no
 pom file so will not allow to run mvn idea:idea to generate the Intellji
 files. Van anyone advise please?

 Many thanks.

 winlaw
 --
 View this message in context:
 http://www.nabble.com/QWicket-tf4194381.html#a11928454
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Updates within Panels in datatable

2007-07-31 Thread Igor Vaynberg
On 7/31/07, salmas [EMAIL PROTECTED] wrote:

 - Even though I do nothing in onSubmit (which I know does get called) the
 table is reloaded (button.getRequest() shows the request for the page to
 reload). I'd like to stop the auto redraw and do an AJAX update from
 within
 onSubmit instead, I am not sure how to stop the table reload when the
 button
 is clicked.


use ajax submit button

- from within onSubmit() in panel2 the textfield and the radio button in
 panel1 show their original values and not the values that I typed in prior
 to pressing the button. The widgets have PropertyModels. To load the
 panels
 I overrode public void populateItem(Item item, String componentId, IModel
 model) in the table columns and then added the panels where appropriate.
 What can I do to update the data in panel1 when the button in Panel2 is
 clicked?


see datatable.setitemreusestrategy(...)

-igor


--
 View this message in context:
 http://www.nabble.com/Updates-within-Panels-in-datatable-tf4196594.html#a11935400
 Sent from the Wicket - User (OLD) mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] onBeforeRender on every Request?

2007-07-30 Thread Igor Vaynberg
onbeforerender() works recusively

lets look at your code

protected final void onBeforeRender()
{
   super.onBeforeRender();
org.apache.wicket.markup.html.WebMarkupContainer tabPartRepeater = (
org.apache.wicket.markup.html.WebMarkupContainer)this
.get(tabPartRepeater);

tabPartRepeater.removeAll();
this.populateTabParts(tabPartRepeater);
this.setupContentPanel();
}

the problem here is you call super.onbeforerender(), then create more
components - so onbeforerender() wont be called on those newly created
components because it would cascade in super.onbeforerender().

to fix all you need to do is move super.onBeforeRender() to the end of the
method.

-igor


On 7/30/07, davor-x [EMAIL PROTECTED] wrote:


 I created a small test webapp to replicate the problem. There are source
 files and a jar package in WEB-INF/lib. Here is how to play with the app:
 Tabbed panel tabs are on top. When you click on tabs, onBeforeRender IS
 called, and the console outputs a line. Then, click on the link Go to Tab
 X - onBeforeRender is called, all ok. Then, click on the tab, where the
 clicked link was: here onBeforeRender is NOT called.

 You'll need the latest 1.3 wicket snapshot. Mine is from yesterday, built
 from svn.
 Thx cheers bye

 http://www.nabble.com/file/p11859405/test-20070730.zip test-20070730.zip


 igor.vaynberg wrote:
 
  yes it should on every request.
 
  during ajax only components being rendered (subtrees added to target)
 have
  their onbeforerender() called.
 
  -igor
 
 
  On 7/29/07, davor-x [EMAIL PROTECTED] wrote:
 
 
  Hi.
  Is Component.onBeforeRender supposed to execute on every request, ajax
 or
  not?
  Because, I have an example, where the component gets rendered, but
  onBeforeRender is not called - on the same request. And then silly
 thing
  happen. (latest 1.3 snapshot)
  Thanks for help
 
  --
  View this message in context:
 
 http://www.nabble.com/onBeforeRender-on-every-Request--tf4166588.html#a11854281
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 
 -
  This SF.net email is sponsored by: Splunk Inc.
  Still grepping through log files to find problems?  Stop.
  Now Search log events and configuration files using AJAX and a browser.
  Download your FREE copy of Splunk now   http://get.splunk.com/
  ___
  IMPORTANT NOTICE:
 
  This mailing list is shutting down. Please subscribe to the Apache
 Wicket
  user list. Send a message to: users-subscribe at wicket.apache.org
 and
  follow the instructions.
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 -
  This SF.net email is sponsored by: Splunk Inc.
  Still grepping through log files to find problems?  Stop.
  Now Search log events and configuration files using AJAX and a browser.
  Download your FREE copy of Splunk now   http://get.splunk.com/
  ___
  IMPORTANT NOTICE:
 
  This mailing list is shutting down. Please subscribe to the Apache
 Wicket
  user list. Send a message to: users-subscribe at wicket.apache.org and
  follow the instructions.
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

 --
 View this message in context:
 http://www.nabble.com/onBeforeRender-on-every-Request--tf4166588.html#a11859405
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: 

Re: [Wicket-user] OnChangeAjaxBehavior and Repeater issue on FireFox

2007-07-30 Thread Igor Vaynberg
try changing

span id=repeaterContainer3

to

div id=..

you shouldnt nest block elements (table/div) in inline elements.

-igor



On 7/30/07, Flavius [EMAIL PROTECTED] wrote:



 Greetings.

 I have a page that uses the new OnChangeAjaxBehavior.  When values
 are typed into the text field, it updates a RepeaterView.  It works
 with the first key press but, almost always, it doesn't fire the
 onUpdate()
 event on subsequent key presses, but only on FireFox (I'm using 2.0.0.5).

 It works fine with IE 7.  To make sure I didn't configure anything
 incorrectly,
 I copied the OnChangeAjaxBehaviorPage sample to my project and ran it.
 That works fine for both IE and FireFox.  Since I can reasonably eliminate
 environment, it seems like the probable issue has something to do with
 the repeater code, or its container.  In looking at the AJAX DEBUG window
 it looks like the ajax is completing successfully.

 I'm using the wicket 1.3.0-beta2 build.  I also tried now with the
 snapshot from today (561103).  The same results.

 I put up a test page at http://24.248.103.44/pages/TestAjax.  The
 page has the java code on it.

 IE works fine, but FF fails after the first key press.

 I also have the sample from examples too:

 http://24.248.103.44/pages/OnChangeAjaxBehaviorPage

 That works for IE and FF.

 I'd appreciate any insight into what I may be doing wrong.



 --
 View this message in context:
 http://www.nabble.com/OnChangeAjaxBehavior-and-Repeater-issue-on-FireFox-tf4178944.html#a11883174
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] onBeforeRender on every Request?

2007-07-29 Thread Igor Vaynberg
yes it should on every request.

during ajax only components being rendered (subtrees added to target) have
their onbeforerender() called.

-igor


On 7/29/07, davor-x [EMAIL PROTECTED] wrote:


 Hi.
 Is Component.onBeforeRender supposed to execute on every request, ajax or
 not?
 Because, I have an example, where the component gets rendered, but
 onBeforeRender is not called - on the same request. And then silly thing
 happen. (latest 1.3 snapshot)
 Thanks for help

 --
 View this message in context:
 http://www.nabble.com/onBeforeRender-on-every-Request--tf4166588.html#a11854281
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Page Expired after logout and re-login

2007-07-28 Thread Igor Vaynberg
what url causes the page expired page?

-igor


On 7/28/07, lubosp [EMAIL PROTECTED] wrote:


 Hi guys,

 my first wicket mailing list post. I just started using Wicket couple gays
 ago (after using Tapestry and ZK), and I have to say, I am impressed.
 Congratulation to great framework!

 I have tried to port my application, which uses Acegi Spring security to
 Wicket. I managed to port the core of the application, but had problem
 with
 Acegi Spring security integration. I used
 http://cwiki.apache.org/WICKET/acegi-and-wicket-auth-roles.html wiki
 article, but I couldn't figure out how to define login page and login
 error
 page in acegi configuration (I will post different question about it).

 So I decided to use plain old JSP to implement login (and login error)
 page.
 That works OK, I can login to the application. I have logout action in my
 application implemented in MyAppSession that extends
 AuthenticatedWebSession:

 setAuthentication(null);
 invalidate();

 That logs me out OK. But when I login again, after the login page
 (login.jsp), instead of application home page, I get Page Expired page
 with
 a link to my application home page.

 My question is, how to you prevent or avoid the Page Expired page.

 Thanks for great framework and for your help. Lubos

 --
 View this message in context:
 http://www.nabble.com/Page-Expired-after-logout-and-re-login-tf4162767.html#a11844379
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Page Expired after logout and re-login

2007-07-28 Thread Igor Vaynberg
hrm, i dont see how /MyApp/app can ever cause a page expired error because
it is a bookmarkable url and so a new instance of page is always created. i
would debug the request cycle and see why it cannot find the page, seems
very strange to me

-igor


On 7/28/07, lubosp [EMAIL PROTECTED] wrote:


 Igor,

 after login page (login.jsp) it is redirected to /MyApp/app which goes to
 my
 wicket home page, and that one is expired.

 Is it possible that I am missing something on logout action?
 Is it enough to do session.invalidate()?

 Note, it works properly the first time, only after I log out and then go
 to
 /MyApp/app again, I get the login page and after it the Page expired page.

 Lubos


 igor.vaynberg wrote:
 
  what url causes the page expired page?
 
  -igor
 
 
  On 7/28/07, lubosp [EMAIL PROTECTED] wrote:
 
 
  Hi guys,
 
  my first wicket mailing list post. I just started using Wicket couple
  gays
  ago (after using Tapestry and ZK), and I have to say, I am impressed.
  Congratulation to great framework!
 
  I have tried to port my application, which uses Acegi Spring security
 to
  Wicket. I managed to port the core of the application, but had problem
  with
  Acegi Spring security integration. I used
  http://cwiki.apache.org/WICKET/acegi-and-wicket-auth-roles.html wiki
  article, but I couldn't figure out how to define login page and login
  error
  page in acegi configuration (I will post different question about it).
 
  So I decided to use plain old JSP to implement login (and login error)
  page.
  That works OK, I can login to the application. I have logout action in
 my
  application implemented in MyAppSession that extends
  AuthenticatedWebSession:
 
  setAuthentication(null);
  invalidate();
 
  That logs me out OK. But when I login again, after the login page
  (login.jsp), instead of application home page, I get Page Expired page
  with
  a link to my application home page.
 
  My question is, how to you prevent or avoid the Page Expired page.
 
  Thanks for great framework and for your help. Lubos
 
  --
  View this message in context:
 
 http://www.nabble.com/Page-Expired-after-logout-and-re-login-tf4162767.html#a11844379
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 
 -
  This SF.net email is sponsored by: Splunk Inc.
  Still grepping through log files to find problems?  Stop.
  Now Search log events and configuration files using AJAX and a browser.
  Download your FREE copy of Splunk now   http://get.splunk.com/
  ___
  IMPORTANT NOTICE:
 
  This mailing list is shutting down. Please subscribe to the Apache
 Wicket
  user list. Send a message to: users-subscribe at wicket.apache.org
 and
  follow the instructions.
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 -
  This SF.net email is sponsored by: Splunk Inc.
  Still grepping through log files to find problems?  Stop.
  Now Search log events and configuration files using AJAX and a browser.
  Download your FREE copy of Splunk now   http://get.splunk.com/
  ___
  IMPORTANT NOTICE:
 
  This mailing list is shutting down. Please subscribe to the Apache
 Wicket
  user list. Send a message to: users-subscribe at wicket.apache.org and
  follow the instructions.
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

 --
 View this message in context:
 http://www.nabble.com/Page-Expired-after-logout-and-re-login-tf4162767.html#a11844509
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   

Re: [Wicket-user] Strange FeedbackPanel behaviour

2007-07-27 Thread Igor Vaynberg
are you running it on a cluster of live servers? or just one?

-igor


On 7/27/07, Mike Cripps [EMAIL PROTECTED] wrote:

 Hi all,

 On my development box, the following code works fine (I'm using a Wizard):

 productCodeField.add(new AbstractValidator() {

 @Override
 protected void onValidate(IValidatable validatable) {
 LOG.info(Validating +validatable);
 if (getProduct(validatable.getValue()) == null) {
 error(validatable, NoSuchProduct);
 LOG.debug(Feedback Messages:  + Session.get
 ().getFeedbackMessages());
 }
 }

 });

 If I enter an invalid code, the error message is correctly displayed,
 and the log correctly shows the message in the FeedbackMessages list.

 However, when I deploy the application the Validator is still called,
 and the both LOG lines appear, but the FeedbackPanel never renders on
 the page.

 I've tried running locally in DEPLOYMENT mode, and in both Tomcat and
 Jetty but it has made no difference - it always works fine on my
 computer and fails on the live servers.

 Has anyone come across this problem before - or can someone suggest a
 place to look to start fixing this?

 Many thanks,
 Mike Cripps

 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Image with AjaxSelfUpdatingTimerBehavior

2007-07-27 Thread Igor Vaynberg
the url never changes, so the browser uses its cache

use NonCachingImage

-igor


On 7/27/07, Gohan [EMAIL PROTECTED] wrote:


 I wonder how I rerender an Image using the AjaxSelfUpdatingTimerBehavior?

 I've created an image like:
 Image image = new Image(imgId, new DynamicImageResource() {
  @Override
  protected byte[] getImageData() {
   // Get the byte data
  }
 });
 image.add(new AjaxSelfUpdatingTimerBehavior(Duration.seconds(30)));
 image.setOutputMarkupId(true);

 The ajax debug window says that a request is sent every 30th second but
 the
 getImageData() is never called again. I've probably misunderstood
 something
 here, so could someone please enlighten me on how this could be achieved?

 Thanks

 --
 View this message in context:
 http://www.nabble.com/Image-with-AjaxSelfUpdatingTimerBehavior-tf4157679.html#a11828847
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Is it possible to update a single row in a table?

2007-07-27 Thread Igor Vaynberg
On 7/27/07, salmas [EMAIL PROTECTED] wrote:

 I have to mimic an application which was written using javascript/XSLT in
 which changes in a table affecting single rows are managed by updating
 only
 the affected row(s). I believe that this is done by surrounding the row in
 a
 span.




Is this possible in wicket? I am using a Datatable.


yes

-igor


Thanks
 --
 View this message in context:
 http://www.nabble.com/Is-it-possible-to-update-a-single-row-in-a-table--tf4158981.html#a11832787
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Is it possible to update a single row in a table?

2007-07-27 Thread Igor Vaynberg
On 7/27/07, salmas [EMAIL PROTECTED] wrote:


 igor.vaynberg wrote:
 
  On 7/27/07, salmas [EMAIL PROTECTED] wrote:
 
 
  Thanks Igor,
  How could I do this?


thats easy, you start by searching this list for datatable ajax row

which will find this:

http://www.nabble.com/Repaint-single-row-of-a-DataTable-tf4111859.html#a11756569

and this

http://www.nabble.com/Repaint-single-cell-of-DataTable%2C-where-cell-is-a-Fragment-tf4118377.html#a11748633

the first thread has a quickstart that demonstrates the functionality.

-igor





  I have to mimic an application which was written using javascript/XSLT
 in
  which changes in a table affecting single rows are managed by updating
  only
  the affected row(s). I believe that this is done by surrounding the row
  in
  a
  span.
 
 
 
 
  Is this possible in wicket? I am using a Datatable.
 
 
  yes
 
  -igor
 
 
  Thanks
  --
  View this message in context:
 
 http://www.nabble.com/Is-it-possible-to-update-a-single-row-in-a-table--tf4158981.html#a11832787
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 
 -
  This SF.net email is sponsored by: Splunk Inc.
  Still grepping through log files to find problems?  Stop.
  Now Search log events and configuration files using AJAX and a browser.
  Download your FREE copy of Splunk now   http://get.splunk.com/
  ___
  IMPORTANT NOTICE:
 
  This mailing list is shutting down. Please subscribe to the Apache
 Wicket
  user list. Send a message to: users-subscribe at wicket.apache.org
 and
  follow the instructions.
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 -
  This SF.net email is sponsored by: Splunk Inc.
  Still grepping through log files to find problems?  Stop.
  Now Search log events and configuration files using AJAX and a browser.
  Download your FREE copy of Splunk now   http://get.splunk.com/
  ___
  IMPORTANT NOTICE:
 
  This mailing list is shutting down. Please subscribe to the Apache
 Wicket
  user list. Send a message to: users-subscribe at wicket.apache.org and
  follow the instructions.
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

 --
 View this message in context:
 http://www.nabble.com/Is-it-possible-to-update-a-single-row-in-a-table--tf4158981.html#a11832925
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Is it possible to update a single row in a table?

2007-07-27 Thread Igor Vaynberg
you need 1.3beta2 of both

-igor


On 7/27/07, salmas [EMAIL PROTECTED] wrote:


 Igor, do I need the latest code for both wicket and extensions or just
 extensions?


 igor.vaynberg wrote:
 
  On 7/27/07, salmas [EMAIL PROTECTED] wrote:
 
 
  igor.vaynberg wrote:
  
   On 7/27/07, salmas [EMAIL PROTECTED] wrote:
  
  
   Thanks Igor,
   How could I do this?
 
 
  thats easy, you start by searching this list for datatable ajax row
 
  which will find this:
 
 
 http://www.nabble.com/Repaint-single-row-of-a-DataTable-tf4111859.html#a11756569
 
  and this
 
 
 http://www.nabble.com/Repaint-single-cell-of-DataTable%2C-where-cell-is-a-Fragment-tf4118377.html#a11748633
 
  the first thread has a quickstart that demonstrates the functionality.
 
  -igor
 
 
 
 
 
   I have to mimic an application which was written using
 javascript/XSLT
  in
   which changes in a table affecting single rows are managed by
 updating
   only
   the affected row(s). I believe that this is done by surrounding the
  row
   in
   a
   span.
  
  
  
  
   Is this possible in wicket? I am using a Datatable.
  
  
   yes
  
   -igor
  
  
   Thanks
   --
   View this message in context:
  
 
 http://www.nabble.com/Is-it-possible-to-update-a-single-row-in-a-table--tf4158981.html#a11832787
   Sent from the Wicket - User mailing list archive at Nabble.com.
  
  
  
 
 -
   This SF.net email is sponsored by: Splunk Inc.
   Still grepping through log files to find problems?  Stop.
   Now Search log events and configuration files using AJAX and a
  browser.
   Download your FREE copy of Splunk now   http://get.splunk.com/
   ___
   IMPORTANT NOTICE:
  
   This mailing list is shutting down. Please subscribe to the Apache
  Wicket
   user list. Send a message to: users-subscribe at wicket.apache.org
  and
   follow the instructions.
   ___
   Wicket-user mailing list
   Wicket-user@lists.sourceforge.net
   https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
 
 -
   This SF.net email is sponsored by: Splunk Inc.
   Still grepping through log files to find problems?  Stop.
   Now Search log events and configuration files using AJAX and a
 browser.
   Download your FREE copy of Splunk now   http://get.splunk.com/
   ___
   IMPORTANT NOTICE:
  
   This mailing list is shutting down. Please subscribe to the Apache
  Wicket
   user list. Send a message to: users-subscribe at wicket.apache.org
  and
   follow the instructions.
   ___
   Wicket-user mailing list
   Wicket-user@lists.sourceforge.net
   https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
 
  --
  View this message in context:
 
 http://www.nabble.com/Is-it-possible-to-update-a-single-row-in-a-table--tf4158981.html#a11832925
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 
 -
  This SF.net email is sponsored by: Splunk Inc.
  Still grepping through log files to find problems?  Stop.
  Now Search log events and configuration files using AJAX and a browser.
  Download your FREE copy of Splunk now   http://get.splunk.com/
  ___
  IMPORTANT NOTICE:
 
  This mailing list is shutting down. Please subscribe to the Apache
 Wicket
  user list. Send a message to: users-subscribe at wicket.apache.org
 and
  follow the instructions.
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 -
  This SF.net email is sponsored by: Splunk Inc.
  Still grepping through log files to find problems?  Stop.
  Now Search log events and configuration files using AJAX and a browser.
  Download your FREE copy of Splunk now   http://get.splunk.com/
  ___
  IMPORTANT NOTICE:
 
  This mailing list is shutting down. Please subscribe to the Apache
 Wicket
  user list. Send a message to: users-subscribe at wicket.apache.org and
  follow the instructions.
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

 --
 View this message in context:
 http://www.nabble.com/Is-it-possible-to-update-a-single-row-in-a-table--tf4158981.html#a11835522
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search 

Re: [Wicket-user] RequestCycle goes null after using WicketTester within Wicket page

2007-07-26 Thread Igor Vaynberg
because of all the threadlocals you should probably run wickettester in a
separate thread:

onclick() {
 final String[] output=new String[1];
 Runnable gen=new Runnable() {
   run() {
  WicketTester tester=new WicketTester();
  tester.startPage(new MailPage());
  output[0]=tester.getoutput();
 }
   }
   Thread thread=new Thread(gen);
   thread.start();
   thread.join();
   // output available in output[0]
 }
}

-igor


On 7/26/07, Tremelune [EMAIL PROTECTED] wrote:


 This issue is ultimately stemming from a specific issue I encountered
 during
 my trials and tribulations in

 http://www.nabble.com/How-to-get-HTML-source-code-from-a-wicket-page-tf3968790.html#a11548230
 this thread , but it was getting buried a bit in the rest of the
 thread...I
 figured I'd ask with a more specific title.

 Essentially, I'm trying to use WicketTester to hit a page in order to get
 the page's final rendered HTML (so I can use it in an email). It works,
 but
 within the process the object in RequestCycle.current disappears for some
 reason. The initial page that is being processed explodes. Is there
 something I can do to prevent this? I tried instantiating a new
 WebRequestCycle, but it resulted in an infinite loop (perhaps I
 constructed
 it poorly, though)...


 A snippet:

 class SomePage extends WebPage {
   public SomePage() {
 CaptureApplication app = new CaptureApplication();
 WicketTester tester = new WicketTester(app);
 tester.startPage(AnotherPage.class);

 //Everything's fine through here...but after...ASSPLODE!
   }



   class CaptureApplication extends WebApplication {
 public Class getHomePage() {
   return null;
 }

 protected IRequestCycleProcessor newRequestCycleProcessor() {
   return new InterceptingCycle();
 }

 class InterceptingCycle extends WebRequestCycleProcessor {
   public void respond(RequestCycle requestCycle) {
 StringResponse emailResponse = new StringResponse();
 WebResponse originalResponse = (WebResponse)
 RequestCycle.get().getResponse();
 RequestCycle.get().setResponse(emailResponse);

 super.respond(requestCycle);

 System.out.println(emailResponse.toString());

 RequestCycle.get().setResponse(originalResponse);
   }
 }
   }
 }

 --
 View this message in context:
 http://www.nabble.com/RequestCycle-goes-null-after-using-WicketTester-within-Wicket-page-tf4153591.html#a11817296
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Wicket 1.3, use of getElementById and Wicket.$() and the preservation of ids

2007-07-26 Thread Igor Vaynberg
the general problem here is that hardcoding ids into wicket markup is mostly
dangerous because things are so reusable.

if you put an id into a repeater then it will be repeated all the time -
causing multiple elements with the same id - which will lead to invalid
html.

hardcoding an id inside a panel or a fragment will lead to the same problem.
it isnt something obvious until you start reusing code and then it gets
nasty all of a sudden. so my two cents are to discourage this.

however, as a workaround for cases where you _must_ do this we have
component.setmarkupid(string) in trunk - you can use that to force any id
you want.

-igor


On 7/26/07, Kirk Israel [EMAIL PROTECTED] wrote:

 On 7/26/07, Eelco Hillenius [EMAIL PROTECTED] wrote:
   http://issues.apache.org/jira/browse/WICKET-694
   i guess there were problems when implementing this, maybe eelco can
   ellaborate more on the unforeseen side effects
 
  Yeah, they were listed in the thread that is mentioned in the issue:
 
 http://www.nabble.com/Re%3A-getMarkupId-doesn%27t-return-the-id-from-the-markup-p11294903.html
 
  I don't really know what to do with it tbh. I hope someone else has
  some suggestions.

 I'm a little surprised this isn't more of a high priority item... I
 know Repeaters et al might need some special casing, but could the
 usual cases do what the coder probably expects, i.e. if you specify
 in html markup, that id is preserved (and therefore usable in
 javascript's getElementById ??)

 Or... I'm not sure what else might depend on that Id as it gets spit
 out into what's finally sent to the browser, but maybe there could be
 a some kind of mapping function in javascript,
 .getElementByWicketId(id)? and
 getRepeaterElementByIdAndIterationNumber(id,num)
 (I tend to make my function names a bit long :-)

 As a thinking point, my group has come up with 3 possible workarounds
 until the real solution appears:
 * temporary, awful hack bandaid currently in use: our javascript
 getElementById added a 6 to the id... the fragile nature of this
 fix is not lost on us
 * go through some function along the lines of getElementByPrefixOfId()
 , so we can get what was specified
 * every form has a hidden field like input type=hidden
 name=OUR_ID value=XYZ, and then we have a specific
 getFormByOurId()

 Again, I'm not sure what getMarkupId(Component) is called by, if it's
 mostly wicket internal use or what... most of what I've talked about
 here is javascript workarounds, though i guess the underlying Java
 equivalents should be obvious.

 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Wicket 1.3, use of getElementById and Wicket.$() and the preservation of ids

2007-07-26 Thread Igor Vaynberg
On 7/26/07, Kirk Israel [EMAIL PROTECTED] wrote:

 (I started moving myself to the other list but am not quite there yet)

 Empirically, it looks like there might have been a change in behavior
 from 1.2, but I couldn't verify that on
 http://cwiki.apache.org/WICKET/migrate-13.html --

 if you're writing custom javascript (in this case an arbitrary form
 element that needs to submit a hidden form for an ajax interaction),
 is there a way that preserves the id as set in the .html
 wicket:id=XYZ as the HTML element's id? In this case, when the .html
 is processed by Wicket, the resulting id is something like XYZ6


http://issues.apache.org/jira/browse/WICKET-694
i guess there were problems when implementing this, maybe eelco can
ellaborate more on the unforeseen side effects


 Googling on
   wicket getElementById
 it seems that might be deprecated for javascript inside Wicket,
 there's that Wicket.$(id) syntax instead? But I couldn't find
 documentation on that, and both getElementById() and Wicket.$() worked
 with XYZ6 but not the original XYZ.


tbh, you are not meant to use anything inside wicket-ajax.js directly.

-igor


Pointers to the documentation I wasn't able to find appreciated as
 well as direct advise and or corrections of assumptions ...

 Thanks!

 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] FormComponentPanel with setRequired

2007-07-26 Thread Igor Vaynberg
i just made formcomponent.checkrequired() none final.

i think most implementations of formcomponentpanel will want to override it
and always return true. that way required validation will be performed on
formcomponentpanel's convertedinput rather then raw http post input. makes
sense?

-igor


On 7/26/07, Stephane Boisson [EMAIL PROTECTED] wrote:


 Hello,

 I was wondering what were the guidelines about using setRequired for a
 FormComponentPanel and for its child FormComponent..

 For example I made a FormComponentPanel made of three DropDownChoice to
 pick
 a date (easier to enter birthday date than other date pickers).

 But if i make this FormComponentPanel required it never get validated,
 because its input is always null..

 I tried to overload isInputNullable for returning false, but didn't
 seems
 a good way to me..

 Any hints?

 Regards,
 Stéphane

 --
 View this message in context:
 http://www.nabble.com/FormComponentPanel-with-setRequired-tf4151671.html#a11810604
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] To Form or not to Form

2007-07-26 Thread Igor Vaynberg
always add a form around it, wicket supports nested forms.

-igor


On 7/26/07, David Leangen [EMAIL PROTECTED] wrote:


 I have a Panel that I'd like to be able to either render as a
 FormComponent in the context of a known Form (by passing the parent Form
 in this component's constructor) or, if the parent Form is null, to
 itself render as a complete Form.

 At first, I thought this would work:

   WebMarkupContainer formHeader =
   new WebMarkupContainer( FORM_HEADER_ID );
   add( formHeader );
   formHeader.setVisible( form == null );

 but then I realised that this won't work, since only the form header (or
 footer) is not valid markup (i.e. the form tag is not properly opened
 and closed).

 I can think of a few hacks to make this work, but can somebody suggest a
 more elegant solution to this?


 Thanks!
 David




 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] question about pretty URLs

2007-07-25 Thread Igor Vaynberg
ah, i thought we had that in beta2 :|

-igor


On 7/25/07, Al Maw [EMAIL PROTECTED] wrote:

 Igor Vaynberg wrote:
  mount your homepage with indexedurlcodingstrategy

 Unfortunately, I don't think that works at the moment - you can't mount
 things on / as it's all reserved. There's an outstanding JIRA issue,
 but fixing it is slightly more complex than you'd expect. I'm looking
 into it.

 Regards,

 Al

 --
 Alastair Maw
 Wicket-biased blog at http://herebebeasties.com

 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Removing Markup Component (From HTML) using Java

2007-07-25 Thread Igor Vaynberg
simply

gridform.setvisible(false);

-igor


On 7/25/07, Durai007 [EMAIL PROTECTED] wrote:


 i have 2 forms, 1.grid-form 2. upload form. both forms have mentioned in
 html

 But initially i want to load upload-form only. So that initially how to
 remove grid-form.

 after submitting upload-form, now only i have to display grid-form.

 Tell me how to remove single markup component from the html using java.
 (i.e div wicket:id='test' in html - remove it from java)

 --
 View this message in context:
 http://www.nabble.com/Removing-Markup-Component-%28From-HTML%29-using-Java-tf4142901.html#a11784996
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Wicket customizability

2007-07-25 Thread Igor Vaynberg
sounds to me like what you need is indirection

something like

IComponentFactory { Component newComponent(String id, IModel model); }

then you can configure these in whatever context (in your case spring) and
inject those into pages/panels/etc and let them create children.

this is essentially the same as osgi or anything else would work. a named
component factory is an osgi service/spring bean/plugin/whatever

-igor


On 7/25/07, Wander Grevink [EMAIL PROTECTED] wrote:

 Hi all,

 I have just created my first wicket app: a simple JCR (jsr-170)
 browser/editor with a tree showing nodes on the left, a
 form for editing node properties on the right, and a menu with some
 actions (add, delete, save etc.) on top.
 All 100% Ajax, it just works!

 As a side note: I started from scratch (completely new to wicket), and it
 took me two weeks to learn wicket and build
 the application. Needless to say that I'm a definite a convert, thank you
 guys for creating this wonderful thing called
 wicket!

 Now for my question(s):

 What my shop actually needs is a customizable gui. We develop a core
 module and users can write plugins for it, think
 eclipse, firefox etc.

 I know of Pax Wicket which is an An OSGification of the Wicket web
 framework. It sounds very interesting and reading
 the documentation it looks like exactly the thing we need. However
 creating a 'Pax Wicket' application is something very
 different from an ordinary Wicket app. I have the impression that 'going
 OSGi' is a decision comparable to 'going J2EE'
   and should not be made overnight, but I might be wrong there.

 I would prefer a simpler way of going this. Therefore I did some
 experimenting and tried to inject a wicket Component (a
 Label) with wicket-spring, but found that injecting Wicket Components
 doesn't work. The proxy will try to access a
 protected method on Component and fail. My guess is that that is a Good
 Thing because you're not supposed to inject
 wicket Components this way, but I may be wrong there, am I? Is there
 another way?

 What I did manage with just base Wicket was a custom
 ModalWindow.PageCreator that dynamically loads a Page (using
 Class.forName) in it's createPage() method. That works, and because the
 class name is stored in the Model (it's a
 property of the selected node in the tree) I now have a 'dynamic' modal
 window whose implementation (java + markup)
 depends on the selected treenode and can be plugged in by adding a jar
 file to the project.

 However, extensibility 'just' through popup dialogs is not enough, and as
 far as I understand it is not possible to do
 the same trick for 'inline' (on the main Page) Components. Or is it?


 I guess that my question boils down to this: Am I on the right track or
 should I stop doing this and go to my boss and
 tell him that we should go OSGi (and Java 5 btw. currently we are strictly
 bound to jdk1.4)

 Regards
 Wander





 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] @EJB injection...

2007-07-25 Thread Igor Vaynberg
it might not have had a release

http://wicketstuff.org/confluence/display/STUFFWIKI/wicket-contrib-javaee

-igor


On 7/25/07, Patrick Angeles [EMAIL PROTECTED] wrote:


 I believe someone contributed code to allow for @EJB injection into Wicket
 pages, and this wound up in Wicket Stuff...

 Is this still the case? Any way I can get Wicket Stuff from Maven? Is it
 compatible with 1.3.0-beta2?

 I've tried http://wicketstuff.org/repository and could not find the javaee
 code there...

 Thanks in advance,

 - P
 --
 View this message in context:
 http://www.nabble.com/%40EJB-injection...-tf4147041.html#a11797325
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 IMPORTANT NOTICE:

 This mailing list is shutting down. Please subscribe to the Apache Wicket
 user list. Send a message to: users-subscribe at wicket.apache.org and
 follow the instructions.
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user 
list. Send a message to: users-subscribe at wicket.apache.org and follow the 
instructions.
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Custom session not working...

2007-07-24 Thread Igor Vaynberg
On 7/24/07, spencer.c [EMAIL PROTECTED] wrote:


 Thanks Eelco, that did the trick.

 Couple of follow up questions/comments that anyone can field:
 1) I understand why you would want a stateless application, however I
 don't
 understand why you would ever want your session to be regenerated on each
 request if during the request you specifically set a session value.  It
 seems like once you set a session value, the session should become bound.
 Is there a logical reason this isn't the case, or is it just a
 technological/implementation reason?  I'm just trying to understand this
 better.


after you set the value on the session did you call session.dirty() to let
wicket know you have done that? i think dirty() will bind the session as
well.

-igor




2) The location quoted for the live examples
 (http://wicketstuff.org/wicket13/) is the one I was looking at, however
 for
 the specific example stateless, it is not possible to view the source
 code
 and/or page files live.  Not sure how the site is maintained, but
 perhaps
 a download link could be added on the examples page to the build that the
 live examples demonstrate, by default.  I've got the files now however, so
 thanks again!

 Best regards,

 Spencer



 Eelco Hillenius wrote:
 
  I have a custom session class that inherits from WebSession.  I have
  overridden the newSession method in my Application class.  The session
 is
  getting used during the request, because I initialize some of its
 values
  in
  its constructor, and they show up when I attach a label to them in a
  page.
  A new session gets created with every request, however, which obviously
  is
  not the desired behavior.  For instance, I have an Integer, and I
  initialize
  it to 1 in the constructor, and increment it before each page
 display.  I
  always get back a 2 on the page.
 
  It sounds like your page is stateless, and the session instances are
  temporary. As long as a session is not 'bound', you'll get a separate
  instance per request and Wicket won't hold on to heap memory. You can
  force the creation of a session by calling Session#bind, which I think
  you should be able to call from your constructor as well.
 
  Related to this, can someone provide me a download link to the 1.3
  examples?
  The live examples page does not allow you to view the source for the
  stateless example, which seems like it may have some relevant code in
 it,
  and I cannot find a download link for the 1.3 examples.  The 1.2examples
  do
  not have that particular example, from what I can tell.
 
  Use http://wicketstuff.org/wicket13/ to look at the examples. The
  wicket-examples site is stale.
 
  As for downloading the examples for 1.3.0, at this time you can best
  get them from SVN directly, or download them from our maven repo at
 
 http://wicketstuff.org/maven/repository/org/apache/wicket/wicket-examples/1.3.0-SNAPSHOT/
 
  Eelco
 
 

 --
 View this message in context:
 http://www.nabble.com/Custom-session-not-working...-tf4132685.html#a11761829
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] question about pretty URLs

2007-07-24 Thread Igor Vaynberg
mount your homepage with indexedurlcodingstrategy

-igor


On 7/24/07, verbal evasion [EMAIL PROTECTED] wrote:

 i am trying to do something and i dont know if its possible in wicket. in
 a
 framework like django (djangoproject.com), i can do stuff like have
 http://www.mysite.com/username where username can be anything. then it
 will point to a particular page and use the URL as an argument. i am
 creating user profile pages and i would like to let people navigate to
 them
 that way.

 thanks,

 verbal
 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Regarding folder selection in Wicket

2007-07-23 Thread Igor Vaynberg
you cannot.

input type=file can only upload files.

-igor


On 7/23/07, Durai007 [EMAIL PROTECTED] wrote:


 Hi,

 In html,
 input type=file name=browser
 I can select the file path.

 But How can I select folder path?  Please explain in html and with wicket
 also

 Thanking You
 Regards
 Durai

 --
 View this message in context:
 http://www.nabble.com/Regarding-folder-selection-in-Wicket-tf4129193.html#a11742236
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Repaint single cell of DataTable, where cell is a Fragment

2007-07-23 Thread Igor Vaynberg
i believe the cause of both problems was the same

-igor


On 7/23/07, ChuckDeal [EMAIL PROTECTED] wrote:



 igor.vaynberg wrote:
 
  svn update and your quickstart will work
 
  -igor
 
 
  On 7/20/07, ChuckDeal [EMAIL PROTECTED] wrote:
 
 
  I am attempting to work around the problem I described here:
  http://www.nabble.com/Repaint-single-row-of-a-DataTable-tf4111859.html
 
  As a result, now instead of adding the row to the target, I add each
  formComponent WITHIN the row.  The cells of my DataTable are Fragments
  that
  represent a FormComponent (TextField, etc).  I declare the
  wicket:fragment
  in my Panel which contains the DataTable.  DataTable has its own
  associated
  markup, which means that when MarkupFragmentFinder attempts to find the
  markup for my components, it fails because the
  parentWithAssociatedMarkup
  is the DataTable that contains the Component (the Fragment) not the
 Panel
  that defined the fragment.
 
  So, this means that I can't repaint a DataTable by row and I also can't
  repaint individual cell Components if they are Fragments.
 
  Do you think that it is possible to resolve these shortcomings with
  DataTable or should I attempt to make my own impl of something like a
  DataTable?  Obviously, I lose the magic of the DataTable, but if
 neither
  of
  the two issues can be resolved, I guess I have no other choice.
 
  Chuck
 

 Excellent!

 Now, is the issue I describe above worthy of attention?  Since I can now
 repaint a row, this problem won't affect me, but it still seems valid.
 --
 View this message in context:
 http://www.nabble.com/Repaint-single-cell-of-DataTable%2C-where-cell-is-a-Fragment-tf4118377.html#a11748496
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] .setVisble not working for webmarkupcontainer

2007-07-23 Thread Igor Vaynberg
On 7/23/07, Eelco Hillenius [EMAIL PROTECTED] wrote:

 On 7/23/07, Christian Alejandro Marquez Grabia [EMAIL PROTECTED] wrote:
  The problem is that you have hidden the container in which the
 components
  were placed, and later when wicket attempts to add the components, it
 can't
  find the place where to.
 
  As Dipu says, you must modify the visibility of the inner components,
 not
  the container, so when wicket attempts to add the components, it can
 find
  the container to place them.

 Both suggestions are good. As far as I know,


setOutputMarkupPlaceholderTag(true) should work as well.


yep, setoutputmarkupplaceholdertag() was actually created just to make a
situation like this easier - remove the need for an extra container that was
often added just to have an always-visible tag in markup to repaint.

-igor



Eelco

 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] NPE in Session.cleanupFeedbackMessages in wicket 1.2.2

2007-07-22 Thread Igor Vaynberg
no one probably uses 1.2.2 still - like you said its ancient.

-igor

On 7/22/07, Nili Adoram [EMAIL PROTECTED] wrote:

 anyone ?

 Nili Adoram wrote:
  Hi all,
  The following error has occurred to a member of our QA team.
  He could not reproduce the scenario.
  If you look at the source files of 1.2.2 this is a very weird error,
  since a few lines  ahead we verify that feedback messages are not null.
  Could this be a race between threads? (AJAX races a non-AJAX request?)
  Please advise,
  Thanks
  Nili
  P.S.
  I know 1.2.2 is an ancient version, however I cannot upgrade at the
 moment.
 
  java.lang.NullPointerException
  at wicket.Session.cleanupFeedbackMessages(Session.java:1015)
  at wicket.RequestCycle.detach(RequestCycle.java:817)
  at wicket.RequestCycle.steps(RequestCycle.java:1058)
  at wicket.RequestCycle.request(RequestCycle.java:454)
  at wicket.protocol.http.WicketServlet.doGet(WicketServlet.java
 :216)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
  at
  org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
 ApplicationFilterChain.java:269)
  at
  org.apache.catalina.core.ApplicationFilterChain.doFilter(
 ApplicationFilterChain.java:188)
  at
 
 com.qlusters.qrm.server.api.objects.transactions.TransactionFilter.doFilter
 (TransactionFilter.java:140)
  at
  org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
 ApplicationFilterChain.java:215)
  at
  org.apache.catalina.core.ApplicationFilterChain.doFilter(
 ApplicationFilterChain.java:188)
  at
  org.apache.catalina.core.StandardWrapperValve.invoke(
 StandardWrapperValve.java:210)
  at
  org.apache.catalina.core.StandardContextValve.invoke(
 StandardContextValve.java:174)
  at
  org.apache.catalina.authenticator.AuthenticatorBase.invoke(
 AuthenticatorBase.java:433)
  at
  org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
 :127)
  at
  org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
 :117)
  at
  org.apache.catalina.core.StandardEngineValve.invoke(
 StandardEngineValve.java:108)
  at
  org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java
 :151)
  at
  org.apache.coyote.http11.Http11Processor.process(Http11Processor.java
 :870)
  at
 
 org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection
 (Http11BaseProtocol.java:665)
  at
  org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(
 PoolTcpEndpoint.java:528)
  at
  org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(
 LeaderFollowerWorkerThread.java:81)
  at
  org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(
 ThreadPool.java:685)
  at java.lang.Thread.run(Thread.java:595)
 
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

 -
 This SF.net email is sponsored by: Splunk Inc.
 Still grepping through log files to find problems?  Stop.
 Now Search log events and configuration files using AJAX and a browser.
 Download your FREE copy of Splunk now   http://get.splunk.com/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now   http://get.splunk.com/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Modal Window and Page Expired - SOLVED

2007-07-20 Thread Igor Vaynberg
On 7/19/07, Laurent Brucher [EMAIL PROTECTED] wrote:

 Ok, my bad...
 Cutting out the details, the page that included a ref to the modal window
 had a piece of javascript, which generated an IMG tag with a src
 attribute
 starting with a '#' (this is some code ported from a JSF version of the
 application). The browser was then trying to fetch the page again looking
 for the (inexistent) bookmark, hence the double hit to the page.

 Now, I'm wondering if it is normal that the framework evicts the page when
 removing one of the 2 versions of that page from the access stack since
 the
 other version is still there and may be referenced again. But I don't know
 wicket enough to make a valid statement on this.


well, the idea here is that we can evict it because it is no longer
reachable via the browser. for example you go to page A then go to page B,
then click back and go to page C. you can no longer access page B via the
browser, so wicket evicts it from pagemap since at that point its just
wasting space. however when you have the kinds of problems you have it
becomes a pita to figure out whats going on.

-igor





Many thanks for the helps here and there though.
 Laurent.



   _

 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] On Behalf Of Laurent
 Brucher
 Sent: vendredi 13 juillet 2007 22:42
 To: wicket-user@lists.sourceforge.net
 Subject: [Wicket-user] Modal Window and Page Expired.


 Hi all,

 There was a post last December about the same problem that I'm facing
 right
 now, which is getting a page expired error page after I close a modal
 window.
 The post was called Firefox and ModalWindow and seemed to talk about the
 issue for FF only.
 I've encountered the problem first with FF (2.0.0.4). After reading the
 post, I tried with IE7 and it worked ok (that was this afternoon).
 This evening, neither IE7 or FF work anymore. Darn! Clearing cookies and
 stuff don't change a thing.
 Oh, and of course, the Ajax ModalWindow example works just fine (my code
 is
 heavily inspired from that example)...
 I'm using Wicket 1.2.6, Tomcat 5.5.20, Jdk1.6u2.

 Have you guys shed any light on this issue at all?
 I've tried to trace the code, but as I'm rather new to Wicket, I couldn't
 really figure out what's going on...

 Anything I can do to help address this?
 Below is the code I use, just in case.

 Reagrds,
 Laurent.


 // Page containing the modal window
 public class MainPage extends WebPage {
 public MainPage()
 {
 ...
 add( new PreferredStationsDialog(prefStationsDialog) );
 ...
 }
 }

 // The modal window impl.
 public class PreferredStationsDialog extends ModalWindow {
 public PreferredStationsDialog(String id)
 {
 super(id);

 setTitle(xyz);
 setCookieName(prefStationsDialog);
 setPageMapName(prefStationsDialogPageMap);
 setPageCreator( new ModalWindow.PageCreator() {
 @Override
 public Page createPage() {
 return new
 PreferredStationsDialogPage(PreferredStationsDialog.this);
 }
 });

 setCloseButtonCallback(new ModalWindow.CloseButtonCallback() {
 public boolean onCloseButtonClicked(AjaxRequestTarget target)
 {
 return true;
 }
 });
 }
 }

 // The content of the modal window, as a Page
 public class PreferredStationsDialogPage extends WebPage
 {
 public PreferredStationsDialogPage( final PreferredStationsDialog
 dialog
 )
 {
 super();

 add( new AjaxLink(button.save) {
 @Override
 public void onClick(AjaxRequestTarget target) {
 dialog.close(target);
 }
 }.add( new Label(text, Save)) );

 add( new AjaxLink(button.cancel) {
 @Override
 public void onClick(AjaxRequestTarget target) {
 dialog.close(target);
 }
 }.add( new Label(text, Cancel)) );
 }
 }

 -
 This SF.net email is sponsored by: Microsoft
 Defy all challenges. Microsoft(R) Visual Studio 2005.
 http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] AttributeModifier on DropDownChoice option element

2007-07-20 Thread Igor Vaynberg
on selectoption, not directly on select

-igor


On 7/20/07, Huy Do [EMAIL PROTECTED] wrote:

 Hi,

 Is it possible to use an AttributeModifier on the DropDownChoice or
 Select option element ? i.e option class=myclass
 Thanks,

 Huy

 -
 This SF.net email is sponsored by: Microsoft
 Defy all challenges. Microsoft(R) Visual Studio 2005.
 http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Getting hold of the servlet request in a wicket WebPage

2007-07-20 Thread Igor Vaynberg
((webrequest)getrequest()).gethttpservletrequest()

-igor


On 7/20/07, Robert Young [EMAIL PROTECTED] wrote:

 Hi,

 I have a servlet filter which analyses the servlet request and then
 sets a variable to it, I need access to this inside a wicket web page.
 How can I get hold of the HttpServletRequest object (or attributes set
 in it) from a wicket page?

 Thanks
 Rob

 -
 This SF.net email is sponsored by: Microsoft
 Defy all challenges. Microsoft(R) Visual Studio 2005.
 http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Repaint single cell of DataTable, where cell is a Fragment

2007-07-20 Thread Igor Vaynberg
svn update and your quickstart will work

-igor


On 7/20/07, ChuckDeal [EMAIL PROTECTED] wrote:


 I am attempting to work around the problem I described here:
 http://www.nabble.com/Repaint-single-row-of-a-DataTable-tf4111859.html

 As a result, now instead of adding the row to the target, I add each
 formComponent WITHIN the row.  The cells of my DataTable are Fragments
 that
 represent a FormComponent (TextField, etc).  I declare the
 wicket:fragment
 in my Panel which contains the DataTable.  DataTable has its own
 associated
 markup, which means that when MarkupFragmentFinder attempts to find the
 markup for my components, it fails because the
 parentWithAssociatedMarkup
 is the DataTable that contains the Component (the Fragment) not the Panel
 that defined the fragment.

 So, this means that I can't repaint a DataTable by row and I also can't
 repaint individual cell Components if they are Fragments.

 Do you think that it is possible to resolve these shortcomings with
 DataTable or should I attempt to make my own impl of something like a
 DataTable?  Obviously, I lose the magic of the DataTable, but if neither
 of
 the two issues can be resolved, I guess I have no other choice.

 Chuck
 --
 View this message in context:
 http://www.nabble.com/Repaint-single-cell-of-DataTable%2C-where-cell-is-a-Fragment-tf4118377.html#a11712104
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Microsoft
 Defy all challenges. Microsoft(R) Visual Studio 2005.
 http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] .properties encoding

2007-07-19 Thread Igor Vaynberg
he problem here is specifying the charset, properties factory is global so
you might encode your files one way but a jar you use with components might
have them encoded in another charset - so we cannot really have a global
charset specified. i think the proper thing to do is use xml properties
format where you specify charset/file

-igor


On 7/19/07, wheleph [EMAIL PROTECTED] wrote:


 I've solved the problem in the following way:

 1. I've created CustomPropertiesFactory subclass of PropertiesFactory and
 put it in wicket.resource package (to get access to
 wicket.resource.Properties' package-private constructor)

 package wicket.resource;
 ...
 public class CustomPropertiesFactory extends PropertiesFactory {
 private String charset;

 public CustomPropertiesFactory(final String charset) {
 this.charset = charset;
 }

 private synchronized Properties loadPropertiesFile(final String
 key,
 final IResourceStream resourceStream, final Class
 componentClass,
 final String style, final Locale locale) {
 ...
 // this is the custom line
 properties.load(
 new
 InputStreamReader(
 new
 BufferedInputStream(

 resourceStream.getInputStream()),
 charset));
 //  properties.load(new
 BufferedInputStream(resourceStream

 //  .getInputStream()));
 strings = new
 ValueMap(properties);
 ...
 }
 ...
 }

 2. I've attached the instance of class given above to application:
 public class EcoApplication extends SpringWebApplication {

 ...
 @Override
 public final void init() {
 // this line is important
 // for spring-injection through annotations
 addComponentInstantiationListener(new
 SpringComponentInjector(this));
 // here is the attachment
 getSettings().setPropertiesFactory(new
 CustomPropertiesFactory(cp1251));
 }
 }
 --
 View this message in context:
 http://www.nabble.com/.properties-encoding-tf4110226.html#a11690737
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Microsoft
 Defy all challenges. Microsoft Visual Studio 2005.
 http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Download / View Attacment (like gmail)

2007-07-19 Thread Igor Vaynberg
On 7/19/07, Francisco Diaz Trepat - gmail [EMAIL PROTECTED]
wrote:

 Hello.

 Any way of doing this?


see downloadlink and popupsettings

-igor




-- Forwarded message --
 From: Francisco Diaz Trepat - gmail [EMAIL PROTECTED]
 Date: Jul 18, 2007 4:15 PM
 Subject: Download / View Attacment (like gmail)
 To: wicket-user@lists.sourceforge.net


 Hi guys is there an easy way to have, say two buttons or links, one
 downloads a txt file and the other one opens it up on a new window?

 mus be ajax.

 f(t)
 -
 This SF.net email is sponsored by: Microsoft
 Defy all challenges. Microsoft Visual Studio 2005.
 http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Question regarding dropdownchoice

2007-07-19 Thread Igor Vaynberg
On 7/19/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:

 Hello to all!

 I'm beginning to learn how to use wicket and I have a question regarding
 DropDownChoice: I have a POJO that is serving me as the model for my
 page, so my form is bind to the properties.
 My problem with the Dropdownchoice in this case is: even if the property
 in the POJO is filled exactly with the same string as the dropdown, I
 never have the proper value selected. It is always selecting that
 Choose One option. So , the question really is: what I need to do to
 have this working properly?


 Follow below the source code for this situation:
 public class User {
private String userName;
private String userType;

   public User() {
   this.userType = General User;
   }

 /* getters/setters */
 }

 Now, I'll create a page and bind this POJO in the interface:
 HTML:
 html
 headtitleTest Page/title/head
body
 form wicket:id=testForm
   User Name: input type=text wicket:id=userNamebr
  User Type: select wicket:id=userType
 optionDemo 1/option
 optionDemo 2/option
/select
/form
   /body
 /html
 JAVA:
 public class TestPage extends WebPage {
private String[] options = new String[] {new String(Test User), new
 String(General User)};
private List OPTIONS = Array.arrayAsList(options);
 public TestPage() {
  User user = new User();
 CompoundPropertyModel userModel = new
 CompoundPropertyModel(user);
  Form testForm = new Form(testForm, userModel);
  TextField userName = new TextField(userName);
  DropDownChoice userType = new DropDownChoice(userType, new
 PropertyModel(userModel,userType), OPTIONS);
 testForm.add(userName);
testForm.add(userType);
   add(testForm);
}
 }


set a breakpoint in abstractsingleselectchoice.isselected() and see why it
is returning false

futher, since you are using a compound model this

 DropDownChoice userType = new DropDownChoice(userType, new
PropertyModel(userModel,

 userType), OPTIONS);



can be changed to

 DropDownChoice userType = new DropDownChoice(userType,OPTIONS);

-igor








Regards,
 Walter Ritzel, Developer
 [EMAIL PROTECTED]

 -
 This SF.net email is sponsored by: Microsoft
 Defy all challenges. Microsoft Visual Studio 2005.
 http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Repaint single row of a DataTable

2007-07-19 Thread Igor Vaynberg
this is tricky because datatable encapsulates a lot of this stuff so it will
probably need something exposed for this usecase. if you create a quickstart
that has a datatable, some bogus data, and some links in columns that should
trigger a refresh i can play around with it and see what needs to be done.

-igor


On 7/19/07, ChuckDeal [EMAIL PROTECTED] wrote:


 I searched for answers to this problem, but most responses were to repaint
 the whole table (or more specifically, the container holding the table).

 I am trying to make an editable grid.  In addition to that, when some cell
 contents change, other cells may need to be repainted (they might contain
 computed values based upon values of one or more other cells).  For
 performance, I don't want to repaint the entire table on each keypress,
 but
 repainting the single row won't be so bad.

 What could I do to repaint a single row of a DataTable?  Don't use
 DataTable?  but I think I still want a repeater and ultimatley it is the
 repeater's fault that I can't repaint because the MarkupFragmentFinder
 can't
 grab the markup because it uses the component's id to match up to the
 markup it finds and the id of repeater children will never match.  It
 would
 need to know that it is a repeater child and use it's parent it to match
 the
 markup.  Component.renderComponent is final and new MArkupFragmentFinder
 is
 hardcoded in there, so it doesn't look like I can create a custom
 MarkupFragmentFinder impl for this special case.

 Maybe I am seeing this from the wrong perspective?  Could someone suggest
 an
 alternative to this approach?  Basically, I like Datatable because it
 allows
 me to define each cell (and any number of them), but I want the ability to
 repaint only PART of the table...

 Thanks
 Chuck
 --
 View this message in context:
 http://www.nabble.com/Repaint-single-row-of-a-DataTable-tf4111859.html#a11691581
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Microsoft
 Defy all challenges. Microsoft Visual Studio 2005.
 http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Adding markup dynamically to a container?

2007-07-19 Thread Igor Vaynberg
class applet extends webcomponent {
 oncomponenttagbody(tag) {
   strinbuilder b=new stringbuilder();
b.append(param name=foo value=bar/);
...
   replacecomponenttagbody(tag, b.tostring());
  }
}

-igor


On 7/19/07, mperham [EMAIL PROTECTED] wrote:


 I'd like to build a dynamic charting applet component so that the page can
 hardcode some presentation params but other params are generated
 dynamically.  For instance:

 applet wicket:id=applet





 /applet

 The params above are presentation and page-specific so they belong in the
 page's HTML.  However I also need to emit several params which are
 data-driven and contain the actual data to render in the chart.  I want
 the
 applet component to automatically inject any number of additional params
 at
 runtime.  How can I do this mix of static and dynamic markup?  Can the
 component subclass WebMarkupContainer and override onComponentTagBody() to
 do this somehow?  Any pointers and examples would be appreciated.  I'm
 using
 1.2.6.

 mike
 --
 View this message in context:
 http://www.nabble.com/Adding-markup-dynamically-to-a-container--tf4112871.html#a11695022
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by: Microsoft
 Defy all challenges. Microsoft(R) Visual Studio 2005.
 http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Wicket URLs in javascript

2007-07-19 Thread Igor Vaynberg
RequestCycle.urlFor(Page) will do what you want

-igor


On 7/19/07, Joel Hill [EMAIL PROTECTED] wrote:

 My app's home page is nothing more than a blank page which has an onload
 script which opens a new browser window and loads my app's main page
 into it.  I'm having trouble figuring out how to get it to work in
 wicket.  I don't want to make the page bookmarkable if at all possible,
 but I have to figure out how to get a url into my javascript call which
 will access my wicket page.  I know how to get wicket to dynamically
 create javascript using IHeaderContributor, but not how to get a url
 which will load a non-bookmarkable wicket page.  I looked into
 Component#urlFor, but the javadocs say that will make the page
 bookmarkable; and I really want to force all access to the app to go
 through the home page.  Any suggestions would be much appreciated.
 Thanks.

 Joel

 -
 This SF.net email is sponsored by: Microsoft
 Defy all challenges. Microsoft(R) Visual Studio 2005.
 http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Download / View Attacment (like gmail)

2007-07-19 Thread Igor Vaynberg
attach it to a jira issue, preferrably as a patch.

thanks,
-igor


On 7/19/07, Francisco Diaz Trepat - gmail [EMAIL PROTECTED]
wrote:

 great
 thanks
 ps: i have a first version of the extensible choice auto-complete.
 should i send you the code?


 On 7/19/07, Igor Vaynberg [EMAIL PROTECTED] wrote:
  On 7/19/07, Francisco Diaz Trepat - gmail 
 [EMAIL PROTECTED]
  wrote:
  
   Hello.
  
   Any way of doing this?
 
 
  see downloadlink and popupsettings
 
  -igor
 
 
 
 
  -- Forwarded message --
   From: Francisco Diaz Trepat - gmail [EMAIL PROTECTED]
   Date: Jul 18, 2007 4:15 PM
   Subject: Download / View Attacment (like gmail)
   To: wicket-user@lists.sourceforge.net
  
  
   Hi guys is there an easy way to have, say two buttons or links, one
   downloads a txt file and the other one opens it up on a new window?
  
   mus be ajax.
  
   f(t)
  
 -
   This SF.net email is sponsored by: Microsoft
   Defy all challenges. Microsoft Visual Studio 2005.
   http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
   ___
   Wicket-user mailing list
   Wicket-user@lists.sourceforge.net
   https://lists.sourceforge.net/lists/listinfo/wicket-user
  
 
 -
  This SF.net email is sponsored by: Microsoft
  Defy all challenges. Microsoft Visual Studio 2005.
  http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 

 -
 This SF.net email is sponsored by: Microsoft
 Defy all challenges. Microsoft(R) Visual Studio 2005.
 http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] java.util.ConcurrentModificationException with RefreshingView (AGAIN!?!?!!)

2007-07-18 Thread Igor Vaynberg
On 7/18/07, Ballist1c [EMAIL PROTECTED] wrote:


 Yep, I made some adjustments to code, to allow for any number of users to
 join a chatSession, rather then just 2.

 What I am doing is , the vector that I am using is within a particular
 class
 and the Iterators for that vector are actually stored within another
 subclass which is stored within a hashmap within this class.


w o w

I got this working before with Iterators directly declared within the class,
 but now that I have moved the iterators to a hashMap so I can store
 multiple
 iterators to the same Vector, it has gone nuts... with the same error:(

 Anyway, let me know what you think


 obviously whatever this thing is, another thread is modifying it, or you
are doing something elsewhere to modify it.

what you should do is instead of returning an iterator directly first copy
the values into an array list and return an iterator to that. java 101.

-igor



--
 chatRefreshingView = new RefreshingView(chatView, new
 PropertyModel(new PropertyModel(ChatView.this.getJumbuckSession(),
 currentChatSession), chatEntries))
 {
 protected Iterator getItemModels()
 {
 //i like cereal
 chatViewItemsIterator = new
 ModelIteratorAdapter(ChatView.this.getJumbuckSession
 ().getCurrentChatSessionIterator())
 {

 protected IModel model(Object object) {
 return new Model((Serializable) object);
 }
 };
 return chatViewItemsIterator;
 }
 protected void populateItem(Item item)
 {
 ChatViewItem chatViewItem = getItem(chatViewItem);
 item.add(chatViewItem);
 chatViewItem.setMyModels();
 }
 };

 add(chatRefreshingView);
 chatRefreshingView.setOutputMarkupId(true);


 ---
 public void setMyModels() //for chatViewItem.setMyModels() above
 {

 IModel chatViewItemModel = getParent().getModel();
 PropertyModel contentsModel = new PropertyModel(chatViewItemModel,
 contents);

 getAuthorChatImage().setModel(new ImagePathFromIdModel(new
 PropertyModel(chatViewItemModel, authorProfileId)));
 getContents().setModel(contentsModel);
 }


 --

 WicketMessage: Error attaching this container for rendering:
 [MarkupContainer [Component id = chatDisplay, page =
 jumbuck.ffweb.wicket.page.FFWeb, path =
 0:main_tabbed_panel:target_panel:tabbed_panel:target_panel:
 chatDisplay.HotListTargetPanel$1,
 isVisible = true, isVersioned = false]]

 Root cause:

 java.util.ConcurrentModificationException
 at java.util.AbstractList$Itr.checkForComodification(AbstractList.java
 :372)
 at java.util.AbstractList$Itr.next(AbstractList.java:343)
 at
 org.apache.wicket.markup.repeater.util.ModelIteratorAdapter.next(
 ModelIteratorAdapter.java:60)
 at
 org.apache.wicket.markup.repeater.DefaultItemReuseStrategy$1.next(
 DefaultItemReuseStrategy.java:71)
 at
 org.apache.wicket.markup.repeater.RefreshingView.addItems(
 RefreshingView.java:189)
 at
 org.apache.wicket.markup.repeater.RefreshingView.onBeforeRender(
 RefreshingView.java:115)
 at org.apache.wicket.Component.beforeRender(Component.java:846)
 at
 org.apache.wicket.MarkupContainer.onBeforeRenderChildren(
 MarkupContainer.java:1449)
 at org.apache.wicket.Component.beforeRender(Component.java:856)
 at
 org.apache.wicket.MarkupContainer.onBeforeRenderChildren(
 MarkupContainer.java:1449)
 at org.apache.wicket.Component.beforeRender(Component.java:856)
 at
 org.apache.wicket.MarkupContainer.onBeforeRenderChildren(
 MarkupContainer.java:1449)
 at org.apache.wicket.Component.beforeRender(Component.java:856)
 at
 org.apache.wicket.ajax.AjaxRequestTarget.respondComponent(
 AjaxRequestTarget.java:757)
 at
 org.apache.wicket.ajax.AjaxRequestTarget.respondComponents(
 AjaxRequestTarget.java:662)
 at
 org.apache.wicket.ajax.AjaxRequestTarget.respond(AjaxRequestTarget.java
 :520)
 at
 org.apache.wicket.request.AbstractRequestCycleProcessor.respond(
 AbstractRequestCycleProcessor.java:103)
 at
 org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java
 :1037)
 at org.apache.wicket.RequestCycle.step(RequestCycle.java:1107)
 at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1176)
 at org.apache.wicket.RequestCycle.request(RequestCycle.java:499)
 at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java
 :257)
 at
 org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java
 :127)
 --
 View this message in context:
 

Re: [Wicket-user] Row index in datatable

2007-07-18 Thread Igor Vaynberg

 -- Forwarded message --
 From: Pierre Coquentin [EMAIL PROTECTED]
 To: wicket-user@lists.sourceforge.net
 Date: Wed, 18 Jul 2007 09:36:44 +0200
 Subject: Row index in datatable

 hello all,

 I need to obtain row index in datatable when populating cell item.
 column = new AbstractColumn(...)
 {
  public void populateItem(Item cellItem, String componentId, IModel
 model)
  {
 cellItem.getIndex() // Index of column
 ??? // Index  of row
 cellItem.add(...);
  }
 };


 After some deep research, i found same question posted

 http://www.mail-archive.com/wicket-user@lists.sourceforge.net/msg21743.html
 but no answer except an hack which don't work with wicket 1.3b2 (and
 didn't find the feature in JIRA).
 If someone can help me :P


i guess ingram never filed that jira request :( maybe you should

if this doesnt work:
((Item)cellItem.getParent()).getIndex()
then this will
((Item)cellItem.findParent(Item.class)).getIndex()

-igor






Thanks in advance.

 Pierre

 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Random ModalWindow exception

2007-07-18 Thread Igor Vaynberg
On 7/18/07, Alex Objelean [EMAIL PROTECTED] wrote:


 I am using wicket-1.2.6.

 Here is a short background description of the problem:

 I have a page, which contains an AjaxTabbedPanel. The panel contains div
 wicket:id=modalWindow/div markup to hold the ModalWindow component.

 I think that the modal.js is included (at least for its first call), but
 have problems when the ajaxTabbedPanel is updated via ajax.

 Any thoughts?


first try 1.2.6 branch. i know this is a problem that happens somewhat
rarely, but so far no one affected by it has been able to produce a
quickstart that replicates it. so we cant fix it. maybe you are that someone
:)

-igor




Thank you,
 Alex.


 Matej Knopp-2 wrote:
 
  What wicket version are you using?
 
  -Matej
 
  On 7/18/07, Alex Objelean [EMAIL PROTECTED] wrote:
 
  I have a strange issue when using ModalWindow in my application.
  Sometimes
  (randomly), I got the following error in ajax-debug window:
 
  [MESSAGE]
 
  INFO: Response parsed. Now invoking steps...
  ERROR: Exception evaluating javascript: TypeError: Wicket.Window has no
  properties
 
  [/MESSAGE]
 
  The reason, seems to be the fact that the modal.js is not always
  included. I
  didn't manage to find out why this is happening. Can anybody help me?
 
  Thank you!
  --
  View this message in context:
 
 http://www.nabble.com/Random-ModalWindow-exception-tf4102507.html#a11666379
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

 --
 View this message in context:
 http://www.nabble.com/Random-ModalWindow-exception-tf4102507.html#a11666954
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] feature suggestion component instantiation

2007-07-18 Thread Igor Vaynberg
what does your strategy do? it redirects right? you do that with throw new
RestartResponseException - you can do the same from your constructor once
you check your model. it isnt that much later that you would fail - only
the init of super hierarchy.

-igor


On 7/18/07, Maurice Marrink [EMAIL PROTECTED] wrote:

 However besides the benefit of being more efficient it also prevents a
 lot of nasty stuff like throwing custom exceptions / NPE in the page
 constructor or redirecting, which i now have to take into account
 because the page is fully constructed. When the strategy can tell me
 for certain if the page is allowed i would not have to do that.

 Maurice

 On 7/18/07, Maurice Marrink [EMAIL PROTECTED] wrote:
  Right now i manually need to trigger
  isActionAuthorized(Component.RENDER); after the component has been
  fully initialized. I would like to abort as soon as possible.
 
  Maurice
 
  On 7/18/07, Johan Compagner [EMAIL PROTECTED] wrote:
   cant you test this with the render action check?
   that is always done also if the model is changed
  
   johan
  
  
   On 7/18/07, Maurice Marrink [EMAIL PROTECTED] wrote:
   
True you can't do setModel(foo) and expect your instantiation check
 to
work. Which imho is perfectly logical if you want to use your model
 in
the instantiation check you need to pass it in the constructor.
   
As for the example
We have a search page for students, uppon clicking on one of those
students, you go to a detail page for that student. that page also
contains several tabs to go to other relevant pages for the student
(like it's school grades). on these pages we made a quicksearch
function with contains amongst other things 2 buttons to navigate
forth and back between the searchresults of the search page, while
keeping the same view. Suppose i have sufficient rights to see the
detail pages of all students but only enough rights to see the
 grades
of my own students.
   
So if i make the search wide enough to get all students and then
select one of my own, going to the grades. That's fine. But if i
 then
navigate to another student i am not allowed to see the grades
(creating a new instance of the grades page in the process) i need
 to
know if the page in combination with the student is allowed, because
the page itself is basically allowed.
   
Maurice
   
On 7/18/07, Eelco Hillenius [EMAIL PROTECTED] wrote:
 I don't think I agree with that.

 MyComponent c = new MyComponent(); c.setModel(foo) wouldn't work
 for
 starters, and you can even set models mutliple times. Not to
 mention
 the other problems you mentioned in this thread. And finally, it
 would
 just invite people to go crazy with this functionality.

 But give us a good example of where using the model to determine
 an
 access restriction would actually be useful?

 Eelco


   
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

   
   
 -
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user
   
  
 -
   This SF.net email is sponsored by DB2 Express
   Download DB2 Express C - the FREE version of DB2 express and take
   control of your XML. No limits. Just data. Click to get it now.
   http://sourceforge.net/powerbar/db2/
   ___
   Wicket-user mailing list
   Wicket-user@lists.sourceforge.net
   https://lists.sourceforge.net/lists/listinfo/wicket-user
  
 

 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is 

Re: [Wicket-user] feature suggestion component instantiation

2007-07-18 Thread Igor Vaynberg
i am -1 on this

first of all there are already too many exception to this: it wont work if
its a wrap model, it wont work if its icomponentassignedmodel, blah blah
blah.

if i construct my component with new Component(id, foo) and foo is not
null then it is very clumsy that sometimes in the auth strategy it is all of
a sudden null and other times is not even though the exact same line is
executing. i bet a lot of people will be filing bug reports.

also i really wish we would limit passing around instances of not fully
constructed objects to users. we already do it in some places where it is
very strictly necessary, but we should not do this lightly.

i do not wish something like this introduced just to make maurice's life a
little easier, sorry maurice nothing personal.

-igor



On 7/18/07, Eelco Hillenius [EMAIL PROTECTED] wrote:

 I don't think I agree with that.

 MyComponent c = new MyComponent(); c.setModel(foo) wouldn't work for
 starters, and you can even set models mutliple times. Not to mention
 the other problems you mentioned in this thread. And finally, it would
 just invite people to go crazy with this functionality.

 But give us a good example of where using the model to determine an
 access restriction would actually be useful?

 Eelco

 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Nesting AjaxTabbedPanels when using AjaxLink

2007-07-18 Thread Igor Vaynberg
On 7/18/07, Jeff Pierce [EMAIL PROTECTED] wrote:

 I am new to Wicket and just getting my feet wet and looking for some
 advice.  I have an app I am building that contains a main row of Ajax tabs
 across the top.   Each tab's panel will have the following layout.  A set
 of
 menu's on the left and a set of tabs on the right for part of its content
 area.  I want the menu's to be Ajax links and the tabs to be Ajax tabs.
 When the user clicks on a menu choice, the content area should reload with
 a
 different set of ajax tabs.

 My question is what is the best way to hookup the ajax links to change the
 portion of the page that contains content area which includes a different
 set of tabs depending on the menu choice (stuff in red below)?  I have the
 tabs and subtabs loading OK, but not sure how to go about hooking up the
 ajax menu choices to change the subtab panel.

 Here's the basic layout:

 -
 Page header area
 -
 | *MainTab1* | MainTab2 |
 -
 |*Menu1* |
 | Menu2  || *Menu1Subtab1* |Menu1Subtab2|
 | Menu3  ||
 | Menu4  ||
 |||  Menu1Subtab1 Tab panel Content Area
 ||
 -
 Page footer area
 -


you have to replace the entire tabbedpanel that holds the menu1subtab links.

so menu1link.onclick(target) {
ajaxtabbedpanel newone=new menu1tabbedpanel(...);
menutabbedpanel.replacewith(newone);
menutabbedpanel=newone;
target.addcomponent(newone);
}

-igor




Thanks
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] feature suggestion component instantiation

2007-07-18 Thread Igor Vaynberg
On 7/18/07, Eelco Hillenius [EMAIL PROTECTED] wrote:


 Sounds to me like you have alternative ways to implement this, for
 instance, construct what's on your page according to what can be
 displayed, throw an auth exception in the page itself (doesn't sound
 like you were doing this generically to start with?) or use an
 intermediate page that functions like a switch. Also, if you really
 want to follow your approach and IComponentInstantiationListener is
 not rich enough, consider using AOP, which should give you all the
 freedom you wish for.


i think its time for you to build something that uses aop and get it out of
your system :)

-igor
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Overriding ID attributes

2007-07-18 Thread Igor Vaynberg
On 7/18/07, mperham [EMAIL PROTECTED] wrote:


 We are migrating our existing application from UI framework XXX to Wicket
 and
 we have a boatload of UI automated tests which depend on the ID attribute
 of
 our form inputs to drive the tests.  I'm trying to figure out how to get
 Wicket to use the exact same IDs when it generates the HTML as with our
 old
 system.  Here's an example of the generated HTML where I have a DropDown
 within a Form:

 td class=label
 divlabel for=form_selBusinessServiceBusiness
 Service/label/div
 /td
 td class=input
   select name=selBusinessService id=form_selBusinessService
 option selected=selected value=Choose One/option
 option value=http://www.test-sdk/sdkl#Fetch_COB;Fetch COB/option
 option value=http://www.test-sdk/sdkl#Status_Visibility;Status
 Visibility/option
 option value=http://www.test-sdk/sdkl#Claims_Submission;Claims
 Submission/option
   /select
 /td

 Now the actual ID of the select should be selBusinessService and that's
 the wicket:id of the component in Java but Wicket prepends the component
 hierarchy, I guess, when auto-generating the id attribute in HTML.  Now I
 can use an AttributeModifier to adjust the value of the ID but the
 SimpleFormComponentLabel does NOT reflect that change in the for
 attribute.

 Is it possible to do this?  Can I completely override Wicket's ID handling
 and just have it use my specified ID?


not right now, but creating setMarkupId() wont be very difficult. please add
a jira request.

-igor


mike
 --
 View this message in context:
 http://www.nabble.com/Overriding-ID-attributes-tf4105343.html#a11675275
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Overriding ID attributes

2007-07-18 Thread Igor Vaynberg
i dont remember how similar the markup id handling code is between the two
versions, but all i did was add this:

/**
 * Sets this component's markup id to a user defined value. It is up to
the
 * user to ensure this value is unique.
 * p
 * The recommended way is to let wicket generate the value
automatically,
 * this method is here to serve as an override for that value in cases
where
 * a specific id must be used.
 * p
 * If null is passed in the user defined value is cleared and markup id
 * value will fall back on automatically generated value
 *
 * @see #getMarkupId()
 *
 * @param markupId
 *markup id value or null to clear any previous user defined
 *value
 */
public void setMarkupId(String markupId)
{
if (markupId != null  Strings.isEmpty(markupId))
{
throw new IllegalArgumentException(Markup id cannot be an empty
string);
}
setMetaData(MARKUP_ID_KEY, markupId);

}


-igor


On 7/18/07, mperham [EMAIL PROTECTED] wrote:


 Igor, could you please attach a diff of your impl to WICKET-766?  I'm
 going
 to need to backport it to our private fork of 1.2.6.

 mike


 igor.vaynberg wrote:
 
 
  Now the actual ID of the select should be selBusinessService and
 that's
  the wicket:id of the component in Java but Wicket prepends the
 component
  hierarchy, I guess, when auto-generating the id attribute in HTML.  Now
 I
  can use an AttributeModifier to adjust the value of the ID but the
  SimpleFormComponentLabel does NOT reflect that change in the for
  attribute.
 
  Is it possible to do this?  Can I completely override Wicket's ID
  handling
  and just have it use my specified ID?
 
 
  not right now, but creating setMarkupId() wont be very difficult. please
  add
  a jira request.
 
 

 --
 View this message in context:
 http://www.nabble.com/Overriding-ID-attributes-tf4105343.html#a11675528
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] java.util.ConcurrentModificationException with RefreshingView (AGAIN!?!?!!)

2007-07-18 Thread Igor Vaynberg
the view doesnt keep the iterator, it just iterates over it once when it
renders. iterators arent meant to be kept, they are throwaway objects.

-igor


On 7/18/07, Ballist1c [EMAIL PROTECTED] wrote:


 It IS very possible I am going about this from the completely wrong
 angle...

 The gist of it is, that a whole bunch of users will be reading all the
 entries from the same vector in an asynchronised manner. So what I thought
 that each user would require their own Iterator to keep track of their
 progress through the Vector ...

 The only actions I performed on the vector is adding to it.  I am
 thinking,
 once the iterator is retrieved from getItemModels() does RefreshingView
 store the iterator within itself for the duration that its being
 displayed?
 cause if that is the case, i am thinking i dont even NEED to be storing
 the
 iterator with each user!




 igor.vaynberg wrote:
 
  On 7/18/07, Ballist1c [EMAIL PROTECTED] wrote:
 
 
  Yep, I made some adjustments to code, to allow for any number of users
 to
  join a chatSession, rather then just 2.
 
  What I am doing is , the vector that I am using is within a particular
  class
  and the Iterators for that vector are actually stored within another
  subclass which is stored within a hashmap within this class.
 
 
  w o w
 
  I got this working before with Iterators directly declared within the
  class,
  but now that I have moved the iterators to a hashMap so I can store
  multiple
  iterators to the same Vector, it has gone nuts... with the same error:(
 
  Anyway, let me know what you think
 
 
   obviously whatever this thing is, another thread is modifying it, or
 you
  are doing something elsewhere to modify it.
 
  what you should do is instead of returning an iterator directly first
 copy
  the values into an array list and return an iterator to that. java 101.
 
  -igor
 
 
 
 
 --
  chatRefreshingView = new RefreshingView(chatView, new
  PropertyModel(new PropertyModel(ChatView.this.getJumbuckSession(),
  currentChatSession), chatEntries))
  {
  protected Iterator getItemModels()
  {
  //i like cereal
  chatViewItemsIterator = new
  ModelIteratorAdapter(ChatView.this.getJumbuckSession
  ().getCurrentChatSessionIterator())
  {
 
  protected IModel model(Object object) {
  return new Model((Serializable) object);
  }
  };
  return chatViewItemsIterator;
  }
  protected void populateItem(Item item)
  {
  ChatViewItem chatViewItem =
 getItem(chatViewItem);
  item.add(chatViewItem);
  chatViewItem.setMyModels();
  }
  };
 
  add(chatRefreshingView);
  chatRefreshingView.setOutputMarkupId(true);
 
 
 
 ---
  public void setMyModels() //for chatViewItem.setMyModels() above
  {
 
  IModel chatViewItemModel = getParent().getModel();
  PropertyModel contentsModel = new
  PropertyModel(chatViewItemModel,
  contents);
 
  getAuthorChatImage().setModel(new ImagePathFromIdModel(new
  PropertyModel(chatViewItemModel, authorProfileId)));
  getContents().setModel(contentsModel);
  }
 
 
 
 --
 
  WicketMessage: Error attaching this container for rendering:
  [MarkupContainer [Component id = chatDisplay, page =
  jumbuck.ffweb.wicket.page.FFWeb, path =
  0:main_tabbed_panel:target_panel:tabbed_panel:target_panel:
  chatDisplay.HotListTargetPanel$1,
  isVisible = true, isVersioned = false]]
 
  Root cause:
 
  java.util.ConcurrentModificationException
  at java.util.AbstractList$Itr.checkForComodification(AbstractList.java
  :372)
  at java.util.AbstractList$Itr.next(AbstractList.java:343)
  at
  org.apache.wicket.markup.repeater.util.ModelIteratorAdapter.next(
  ModelIteratorAdapter.java:60)
  at
  org.apache.wicket.markup.repeater.DefaultItemReuseStrategy$1.next(
  DefaultItemReuseStrategy.java:71)
  at
  org.apache.wicket.markup.repeater.RefreshingView.addItems(
  RefreshingView.java:189)
  at
  org.apache.wicket.markup.repeater.RefreshingView.onBeforeRender(
  RefreshingView.java:115)
  at org.apache.wicket.Component.beforeRender(Component.java:846)
  at
  org.apache.wicket.MarkupContainer.onBeforeRenderChildren(
  MarkupContainer.java:1449)
  at org.apache.wicket.Component.beforeRender(Component.java:856)
  at
  org.apache.wicket.MarkupContainer.onBeforeRenderChildren(
  MarkupContainer.java:1449)
  at org.apache.wicket.Component.beforeRender(Component.java:856)
  at
  org.apache.wicket.MarkupContainer.onBeforeRenderChildren(
  

Re: [Wicket-user] Setting up project - images and stylesheets

2007-07-18 Thread Igor Vaynberg
simply do this

have your images be relative

img src=images/logo.png/

in runtime wicket will rewrite them to be relative to context root

in devel time put this into head

wicket:remove
base href=../../../path/to/your/webapp/folder/
/wicket:remove

so at devel time your images will also be relative to context root.

-igor


On 7/16/07, jonaqua [EMAIL PROTECTED] wrote:


 I'm just getting started with Wicket.

 I'm not sure how I should best link to stylesheets and images in my
 NetBeans
 project.

 For example, if I have the following code in my MyPage.html page:

 lt;img src=images/logo.pnggt;

 ...and I run the application, the image will reference
 web/images/logo.png.
 However, if I just quickly view that HTML file, it will reference
 src/java/package/images/logo.png and the image link will be broken.

 Is there a good way to set up the project besides keeping duplicate images
 and stylesheets both in the source code dir and the web dir?

 I realize if I move the HTML files to the web directory the problem will
 be
 solved but I'm trying to stick with the Wicket way of doing things for now
 (.HTML right next to .java in the source)

 Thanks
 --
 View this message in context:
 http://www.nabble.com/Setting-up-project---images-and-stylesheets-tf4094209.html#a11641865
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] wicket-picocontainer?

2007-07-18 Thread Igor Vaynberg
putting one together should be trivial. you can pretty much copy
wicket-spring and replace all the spring bits (of which there are only few)
with pico's

-igor


On 7/18/07, David Rosenstrauch [EMAIL PROTECTED] wrote:

 Eelco Hillenius wrote:
  On 7/18/07, David Rosenstrauch [EMAIL PROTECTED] wrote:
  I saw that the 1.3 distribution contains wicket-ioc*.jar, along with
  wicket-guice*.jar, and wicket-spring*.jar.
 
  Just wondering:  has anybody put together a wicket-picocontainer
 package
  too, perchance?
 
  That that I know of, but a contribution would be welcome :)
 
  Eelco

 Understood.  Let me dig into my project a bit more and see how much I
 need it - and how much work it would be.  If the cost/benefit looks good
 then I'll try to put one together.

 Thanks,

 DR

 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Disabling Validation, but keeping updateFormComponentModels()

2007-07-17 Thread Igor Vaynberg
On 7/17/07, Fisher, Brice A [EMAIL PROTECTED] wrote:

 An additional question.  Trying to do things the brute force way, I
 implemented the following in my form:


 @Override
 protected void validate() {
 Button b = findSubmittingButton();
 if (b == updateButton) {
 super.validate();

 // Additional validations...
 } else {
 updateFormComponentModels();
 }
 }


 If the else branch is taken, then the fields from the form are null.
 If I switch my RequiredTextFields to TextFields and force the if
 branch, then the form fields are correctly populated.  So, apparently
 there is more happening in super.validate() than is covered by
 updateFormComponentModels().

 However, if I look at super.validate(), it includes:

 validateRequired();
 validateConversion();
 validateValidators();
 validateFormValidators();

 None of which are available in the inherited class.

 So, should I plan on re-implementing the contents of one or more of
 these functions in my class or is there another method I can call to
 correctly populate the form elements?


you cannot update models without validation. a simple example:
you have TextField(number, Integer.class); and the user enters a.
obviously you cannot put a into a model that expects an Integer.

-igor
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Wicket examples question

2007-07-17 Thread Igor Vaynberg
On 7/17/07, Kirk Is [EMAIL PROTECTED] wrote:

 So, at wicket-library.com/wicket-examples I see signin and signin2.

 Signin2 is the rememberme functionality I'm trying to emulate.

 When I click on view source, it seems like the functionality I want,
 the stuff the separates signin2 from signin, is lumped in
 wicket.examples.panels.signin.SignInPanel. and yet for some reason,
 that file isn't there to be viewed.

 Why is that? And where do I go to get the information? It doesn't seem
 too well organized, though I understand not wanting to throw TOO too
 much source code at n00bs, it seems like putting in the most crucial
 stuff would make sense.


please create a jira issue. meanwhile you are free to check out the source
and browse it in your ide.

-igor



-
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] setVesible for the component after onEvent

2007-07-17 Thread Igor Vaynberg
On 7/17/07, kenixwong [EMAIL PROTECTED] wrote:


 sorry,igor... i cant get what u mean ... can u explain more? or show me
 some
 example?  thanks


you gotta learn how to use the internets

http://www.nabble.com/forum/Search.jtp?forum=13974local=yquery=visible+ajax+container

try the first result

-igor




igor.vaynberg wrote:
 
  in that case you have to call setvisible, but add the parent of the
  component to the ajaxrequesttarget instead
 
  -igor
 
 
  On 7/16/07, kenixwong [EMAIL PROTECTED] wrote:
 
 
  i m using wicket 1.2.4, setoutputmarkupplaceholdertag(true) is came
 from
  wicket 1.3.0?
 
 
 
  igor.vaynberg wrote:
  
   On 7/16/07, kenixwong [EMAIL PROTECTED] wrote:
  
  
  
   It work, but oaly the first time. Mean after i clicked on the radio
  few
   times, it nothing happen.
  
  
   try calling setoutputmarkupplaceholdertag(true) on all components you
  are
   planning to call setvisible(false) when you create them
  
   -igor
  
  
  
   thanks for help...
   --
   View this message in context:
  
 
 http://www.nabble.com/setVesible-for-the-component-after-onEvent-tf4086024.html#a11613360
   Sent from the Wicket - User mailing list archive at Nabble.com.
  
  
  
 
 -
   This SF.net email is sponsored by DB2 Express
   Download DB2 Express C - the FREE version of DB2 express and take
   control of your XML. No limits. Just data. Click to get it now.
   http://sourceforge.net/powerbar/db2/
   ___
   Wicket-user mailing list
   Wicket-user@lists.sourceforge.net
   https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
  
 
 -
   This SF.net email is sponsored by DB2 Express
   Download DB2 Express C - the FREE version of DB2 express and take
   control of your XML. No limits. Just data. Click to get it now.
   http://sourceforge.net/powerbar/db2/
   ___
   Wicket-user mailing list
   Wicket-user@lists.sourceforge.net
   https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
 
  --
  View this message in context:
 
 http://www.nabble.com/setVesible-for-the-component-after-onEvent-tf4086024.html#a11641371
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

 --
 View this message in context:
 http://www.nabble.com/setVesible-for-the-component-after-onEvent-tf4086024.html#a11661017
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Retrieve selected value from DropDown

2007-07-17 Thread Igor Vaynberg
On 7/17/07, Toscano [EMAIL PROTECTED] wrote:


 Hello,

 I have a huge form with a lot of dropdowns, and I'm using a
 CompoundPropertyModel. The form can also be changed between more than six
 languages, so everytime the user changes one value in one Dropdown, all
 the
 form is refreshed showing the DropDowns in the selected language.
 The problem is for getting the selected values of the DropDowns when
 submit...

 Here is the code:
 Declaration of one of the combos in the page class:

  defaultSystemLanguage = new
 DropDownChoice(defaultSystemLanguage,
  new LoadableDetachableModel() {protected Object load() {return
 getImplementedLanguages();}},
  new ChoiceRenderer (languageName, languageID));
 defaultSystemLanguage.setNullValid(true);

 CompoundPropertyModel:
 private String defaultSystemLanguage; (with gets/sets)

 onSubmit:
 public void onSubmit() {
System.out.println (LANGUAGE BY DEFAULT: +
 userInformation.getDefaultSystemLanguage());

 This causes the following error:

 wicket.WicketRuntimeException: No get method defined for class: class
 java.lang.String expression: languageID

 What I'm doing wrong? If I specify a CompoundPropertyModel with one
 property
 with the same name as the DropDown, isn't supposed to be mapped directly
 there?


your model object is of type String as it maps to the String
defaultSystemLanguage. your renderer however expects an object it can call
getLanguageName() and getLanaguageId() on - as you have defined. so make
defaultSystemLanguage your Language object instead of just a string.

-igor




Thanks in advance,
 Oskar

 --
 View this message in context:
 http://www.nabble.com/Retrieve-selected-value-from-DropDown-tf4100672.html#a11661363
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] AjaxRequestTarget.addComponent for a child of ListItem

2007-07-17 Thread Igor Vaynberg
On 7/17/07, Mike03 [EMAIL PROTECTED] wrote:


 Hello, I've seen the posting that refers to this wiki page
 http://cwiki.apache.org/WICKET/how-to-repaint-a-listview-via-ajax.html How
 to repaint a ListView with Ajax  but my problem is a little different and
 I'm hoping there's a solution.  I'm using wicket-1.2.6

 I've got a ListView that renders some dashboard icons.  Each ListItem of
 the
 ListView contains a BookmarkableLink which contains WebMarkupContainer
 representing a div which contains another WebMarkupContainer representing
 an
 img.  The model object backing the div can change state which should
 result
 in a change of the img source (ie: change from warning.png to error.png).
 Each div is given a unique markupId (via a SimpleAttributeModifier) that
 matches the model object's primary key in the database.

 There's an AbstractAjaxTimer registered on the ListView who's onTimer
 method
 iterates through the ListView's children and drills down to the div
 component.  If the div's model object has changed state, I call
 target.addComponent passing in the div component and the div's unique
 markupId.

 With this methodology, I can't get an individual div to refresh.  I put a
 div container around the ListView and I can get the entire ListView to
 refresh as the wiki page suggests but I'd like to get a tighter
 granularity
 of refreshing since there may be hundreds of icons on a dashboard.  Am I
 doing something wrong or is there no way to ajax refresh individual
 ListItem
 (or their children) components?


any errors in wicket ajax console? also try repeatingview - it is more
stable then listview in the sense it doesnt try to recreate its hierarchy
on every request.

-igor




Thanks,
 Mike
 --
 View this message in context:
 http://www.nabble.com/AjaxRequestTarget.addComponent-for-a-child-of-ListItem-tf4100732.html#a11661543
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] setVesible for the component after onEvent

2007-07-17 Thread Igor Vaynberg
On 7/17/07, kenixwong [EMAIL PROTECTED] wrote:


 :( sorry , igor... everytime when i faced the problem, i sure will search
 from net. Just i not sure what u going to write as above matter...


first search result is this

http://www.nabble.com/Changing-visibility-via-ajax-tf1974532.html#a5418508

which explains how to wrap something in a container and repaint that
instead.

-igor




anyway, thanks for your fast reply and help...


 igor.vaynberg wrote:
 
  On 7/17/07, kenixwong [EMAIL PROTECTED] wrote:
 
 
  sorry,igor... i cant get what u mean ... can u explain more? or show me
  some
  example?  thanks
 
 
  you gotta learn how to use the internets
 
 
 http://www.nabble.com/forum/Search.jtp?forum=13974local=yquery=visible+ajax+container
 
  try the first result
 
  -igor
 
 
 
 
  igor.vaynberg wrote:
  
   in that case you have to call setvisible, but add the parent of the
   component to the ajaxrequesttarget instead
  
   -igor
  
  
   On 7/16/07, kenixwong [EMAIL PROTECTED] wrote:
  
  
   i m using wicket 1.2.4, setoutputmarkupplaceholdertag(true) is came
  from
   wicket 1.3.0?
  
  
  
   igor.vaynberg wrote:
   
On 7/16/07, kenixwong [EMAIL PROTECTED] wrote:
   
   
   
It work, but oaly the first time. Mean after i clicked on the
 radio
   few
times, it nothing happen.
   
   
try calling setoutputmarkupplaceholdertag(true) on all components
  you
   are
planning to call setvisible(false) when you create them
   
-igor
   
   
   
thanks for help...
--
View this message in context:
   
  
 
 http://www.nabble.com/setVesible-for-the-component-after-onEvent-tf4086024.html#a11613360
Sent from the Wicket - User mailing list archive at Nabble.com.
   
   
   
  
 
 -
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user
   
   
   
  
 
 -
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user
   
   
  
   --
   View this message in context:
  
 
 http://www.nabble.com/setVesible-for-the-component-after-onEvent-tf4086024.html#a11641371
   Sent from the Wicket - User mailing list archive at Nabble.com.
  
  
  
 
 -
   This SF.net email is sponsored by DB2 Express
   Download DB2 Express C - the FREE version of DB2 express and take
   control of your XML. No limits. Just data. Click to get it now.
   http://sourceforge.net/powerbar/db2/
   ___
   Wicket-user mailing list
   Wicket-user@lists.sourceforge.net
   https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
  
 
 -
   This SF.net email is sponsored by DB2 Express
   Download DB2 Express C - the FREE version of DB2 express and take
   control of your XML. No limits. Just data. Click to get it now.
   http://sourceforge.net/powerbar/db2/
   ___
   Wicket-user mailing list
   Wicket-user@lists.sourceforge.net
   https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
 
  --
  View this message in context:
 
 http://www.nabble.com/setVesible-for-the-component-after-onEvent-tf4086024.html#a11661017
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  

Re: [Wicket-user] Retrieve selected value from DropDown

2007-07-17 Thread Igor Vaynberg
On 7/17/07, Toscano [EMAIL PROTECTED] wrote:


 Thank you for your fast answer!

 It makes sense. I made the following changes:

 CompoundPropertyModel:
 private Language defaultSystemLanguage; (with the correct gets/sets)

 Submit:
 System.out.println (LANGUAGE BY DEFAULT: +
 userInformation.getDefaultSystemLanguage().getLanguageID());

 And now the error changes to:
 wicket.util.convert.ConversionException: Can't convert value:
 languageID:14
 - languageName:Japanese to class: class
 iJoinApplication.Entity.Registration.Language for setting it on
 [EMAIL PROTECTED]

 UserInformation is the CompoundPropertyModel whose defaultSystemLanguage
 property I changed to Language object.


i dont think you understand completely how CPM works

if you do new CompoundPropertyModel(new Registration());
then that registration has to have the Language defaultSystemLanguage
property. is that the case?

-igor



Again, thank you so much for all your help.
 Oskar





 igor.vaynberg wrote:
 
  On 7/17/07, Toscano [EMAIL PROTECTED] wrote:
 
 
  Hello,
 
  I have a huge form with a lot of dropdowns, and I'm using a
  CompoundPropertyModel. The form can also be changed between more than
 six
  languages, so everytime the user changes one value in one Dropdown, all
  the
  form is refreshed showing the DropDowns in the selected language.
  The problem is for getting the selected values of the DropDowns when
  submit...
 
  Here is the code:
  Declaration of one of the combos in the page class:
 
   defaultSystemLanguage = new
  DropDownChoice(defaultSystemLanguage,
   new LoadableDetachableModel() {protected Object load() {return
  getImplementedLanguages();}},
   new ChoiceRenderer (languageName, languageID));
  defaultSystemLanguage.setNullValid(true);
 
  CompoundPropertyModel:
  private String defaultSystemLanguage; (with gets/sets)
 
  onSubmit:
  public void onSubmit() {
 System.out.println (LANGUAGE BY DEFAULT: +
  userInformation.getDefaultSystemLanguage());
 
  This causes the following error:
 
  wicket.WicketRuntimeException: No get method defined for class: class
  java.lang.String expression: languageID
 
  What I'm doing wrong? If I specify a CompoundPropertyModel with one
  property
  with the same name as the DropDown, isn't supposed to be mapped
 directly
  there?
 
 
  your model object is of type String as it maps to the String
  defaultSystemLanguage. your renderer however expects an object it can
 call
  getLanguageName() and getLanaguageId() on - as you have defined. so make
  defaultSystemLanguage your Language object instead of just a string.
 
  -igor
 
 
 
 
  Thanks in advance,
  Oskar
 
  --
  View this message in context:
 
 http://www.nabble.com/Retrieve-selected-value-from-DropDown-tf4100672.html#a11661363
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

 --
 View this message in context:
 http://www.nabble.com/Retrieve-selected-value-from-DropDown-tf4100672.html#a11661751
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Retrieve selected value from DropDown

2007-07-17 Thread Igor Vaynberg
On 7/17/07, Toscano [EMAIL PROTECTED] wrote:


 Thank you again.

 But I'm not very sure of what you are talking about... I declared the
 DropDowns that way so they are able to change the content for every
 language
 with every localization change. But as part of a Form with assigned
 CompoundPropertyModel, I supposed it should be easy to just map the
 selected
 value in the property with the same name.

 The strange is that I have exactly the same code for a different Dropdown,
 and I can retrieve the value correctly:

 Page class:
   membershipLevels = new DropDownChoice (membershipLevel,
 new LoadableDetachableModel() {protected Object load() {return
 getMembershipLevels();}},
 new ChoiceRenderer (membershipLevelName,
 membershipLevelID));

 Compound Property:
 private MembershipLevel membershipLevel;

 Submit:
System.out.println (MEMBERSHIPLEVEL: +
 userInformation.getMembershipLevel().getMembershipLevelID());

 So yes, you are right, I think I don't understand how it works...


i guess if you can paste thecode to where you createte the model and its
object it might be easier.

there is a good wiki page which goes over how models and compound models
work you might want to read.

-igor




Really... thank you!
 Oskar







 igor.vaynberg wrote:
 
  On 7/17/07, Toscano [EMAIL PROTECTED] wrote:
 
 
  Thank you for your fast answer!
 
  It makes sense. I made the following changes:
 
  CompoundPropertyModel:
  private Language defaultSystemLanguage; (with the correct gets/sets)
 
  Submit:
  System.out.println (LANGUAGE BY DEFAULT: +
  userInformation.getDefaultSystemLanguage().getLanguageID());
 
  And now the error changes to:
  wicket.util.convert.ConversionException: Can't convert value:
  languageID:14
  - languageName:Japanese to class: class
  iJoinApplication.Entity.Registration.Language for setting it on
  [EMAIL PROTECTED]
 
  UserInformation is the CompoundPropertyModel whose
 defaultSystemLanguage
  property I changed to Language object.
 
 
  i dont think you understand completely how CPM works
 
  if you do new CompoundPropertyModel(new Registration());
  then that registration has to have the Language defaultSystemLanguage
  property. is that the case?
 
  -igor
 
 
 
  Again, thank you so much for all your help.
  Oskar
 
 
 
 
 
  igor.vaynberg wrote:
  
   On 7/17/07, Toscano [EMAIL PROTECTED] wrote:
  
  
   Hello,
  
   I have a huge form with a lot of dropdowns, and I'm using a
   CompoundPropertyModel. The form can also be changed between more
 than
  six
   languages, so everytime the user changes one value in one Dropdown,
  all
   the
   form is refreshed showing the DropDowns in the selected language.
   The problem is for getting the selected values of the DropDowns when
   submit...
  
   Here is the code:
   Declaration of one of the combos in the page class:
  
defaultSystemLanguage = new
   DropDownChoice(defaultSystemLanguage,
new LoadableDetachableModel() {protected Object load()
  {return
   getImplementedLanguages();}},
new ChoiceRenderer (languageName, languageID));
   defaultSystemLanguage.setNullValid(true);
  
   CompoundPropertyModel:
   private String defaultSystemLanguage; (with gets/sets)
  
   onSubmit:
   public void onSubmit() {
  System.out.println (LANGUAGE BY DEFAULT: +
   userInformation.getDefaultSystemLanguage());
  
   This causes the following error:
  
   wicket.WicketRuntimeException: No get method defined for class:
 class
   java.lang.String expression: languageID
  
   What I'm doing wrong? If I specify a CompoundPropertyModel with one
   property
   with the same name as the DropDown, isn't supposed to be mapped
  directly
   there?
  
  
   your model object is of type String as it maps to the String
   defaultSystemLanguage. your renderer however expects an object it can
  call
   getLanguageName() and getLanaguageId() on - as you have defined. so
  make
   defaultSystemLanguage your Language object instead of just a string.
  
   -igor
  
  
  
  
   Thanks in advance,
   Oskar
  
   --
   View this message in context:
  
 
 http://www.nabble.com/Retrieve-selected-value-from-DropDown-tf4100672.html#a11661363
   Sent from the Wicket - User mailing list archive at Nabble.com.
  
  
  
 
 -
   This SF.net email is sponsored by DB2 Express
   Download DB2 Express C - the FREE version of DB2 express and take
   control of your XML. No limits. Just data. Click to get it now.
   http://sourceforge.net/powerbar/db2/
   ___
   Wicket-user mailing list
   Wicket-user@lists.sourceforge.net
   https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
 
 -
   This SF.net email is sponsored by DB2 Express
   Download DB2 Express C - the FREE version of DB2 express and 

Re: [Wicket-user] wicket-dojo StylingWebMarkupContainer / StyleAttribute

2007-07-17 Thread Igor Vaynberg
On 7/17/07, NateBot2000 [EMAIL PROTECTED] wrote:


 Alrighty, I figured it out.  Clean and very simple (let me know if there's
 a
 better way to do this):

 package com.***.web.dashboard;


http://bash.org/?244321

-igor



import org.wicketstuff.dojo.markup.html.floatingpane.DojoFloatingPane;
 import org.wicketstuff.dojo.widgets.StyleAttribute;

 public class DashboardPane extends DojoFloatingPane {

protected static final long serialVersionUID = 1L;

private final static String LEFT  = left;
private final static String TOP   = top;

private String left = 0px;
private String top = 0px;

public DashboardPane( String id )
{
   super(id);
}

public final void setLeft(String left)
{
   this.left = left;
}

public final void setTop(String top)
{
   this.top = top;
}

protected void onStyleAttribute(StyleAttribute styleAttribute)
{
   styleAttribute.put(LEFT, left);
   styleAttribute.put(TOP, top);
}
 }
 --
 View this message in context:
 http://www.nabble.com/wicket-dojo-StylingWebMarkupContainer---StyleAttribute-tf4099879.html#a11662481
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] initial Seam support in SVN

2007-07-16 Thread Igor Vaynberg

On 7/15/07, Eelco Hillenius [EMAIL PROTECTED] wrote:


On 7/15/07, Eelco Hillenius [EMAIL PROTECTED] wrote:
  Really ?!  this is cool! but on which Seam version this integration is
based
  on ?

 On their current trunk (so 2.2 beta 2 in progress I believe).

Btw, at this time, only @In annotations are supported. I first have to
*understand* what @Out annotations are for, and then we can see how we
could support that. :)



dont think @out makes sense anywhere. the ui is/should be a consumer only,
so it shouldnt be contributing back to the context. also scoping out
contributions will become difficult because wicket uses instance-scope which
is a mismatch for seam's scopes.

-igor
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] setVesible for the component after onEvent

2007-07-16 Thread Igor Vaynberg

On 7/16/07, kenixwong [EMAIL PROTECTED] wrote:




It work, but oaly the first time. Mean after i clicked on the radio few
times, it nothing happen.



try calling setoutputmarkupplaceholdertag(true) on all components you are
planning to call setvisible(false) when you create them

-igor



thanks for help...

--
View this message in context:
http://www.nabble.com/setVesible-for-the-component-after-onEvent-tf4086024.html#a11613360
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] stateless wicket?

2007-07-16 Thread Igor Vaynberg

On 7/16/07, Johan Compagner [EMAIL PROTECTED] wrote:


not directly as a session attribute
but hold on to through the pagemap.



right, so it should be replicated...we do call set on the pagemap if its
dirty right?

-igor



johan



On 7/13/07, Igor Vaynberg  [EMAIL PROTECTED] wrote:

 hrm, i thought the current page is stored in session?

 -igor


 On 7/13/07, Eelco Hillenius  [EMAIL PROTECTED]  wrote:
 
I have a question regarding this... I understand that in 1.3 ,
  previous
   page states are serialized to the file system and only the current
  page
   state stays in HttpSession. How would this work in a clustered web
  container
   that synchronizes the HttpSession object to other nodes? Do you lose
  the
   history?
  
   no. think about it - you replicate the current page every request -
  which
   means each node can save them to disk also.
 
  Except for the fact that the pages aren't actually set as sessions
  attributes to start with...
 
  Eelco
 
 
  -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 



 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] confusion about Wicket models and serialization

2007-07-16 Thread Igor Vaynberg

On 7/16/07, David Rosenstrauch [EMAIL PROTECTED] wrote:



My over-arching question at this point is:  Is it a requirement that a
model's target object be Serializable?



no



1) I tried to use a LoadableDetachableModel, partly as a way to avoid
making my data object Serializable.  But I'm wondering if that's not
correct.  Take for example a data object with gettters and setters for
the following fields:  id (int), foo (string), and bar (string).  Using
  LoadableDetachableModel, I can load the object on demand by id - and
so all I need to do is hold the id in the LoadableDetachableModel, and
can discard the object itself.  Thus the object doesn't need to be
serializable.



correct

However, lets say that a form submission by the user sets

the foo property to foo, and bar property to bar.  And let's say
further that foo is a valid value, but bar fails validation for some
reason - which will keep the user on the same form page.  In this case
won't a logic error result?  Since I'm not retaining (or serializing) my
instance of the data object, but rather loading it fresh from the
database each time, won't the foo value disappear?  Because when the
model needs to access the target object, it wouldn't be accessing a
working copy that had the value set to foo, but rather a pristine
copy from the database that had an old value?



if validation fails the models are not updated, wicket will hold on to input
for you and redisplay it in the form. model updates are atomic in regard to
validation. so you are ok. the only thing to worry when using db backed
beans directly is locking. martijn has a  great example on how to handle
optimistic locking in the form on his blog.

2) How am I to handle the situation where I want to use a new (not yet

saved) instance of a data object as the target for a model?  Since the
object is not yet saved to the database, I can't use a
LoadableDetachableModel to load it fresh from the database every time.
And I can't just have the Model create a new instance each time either,
since it looks like repeated form submissions would wind up discarding
old values?  Is there any way to handle this situation without making my
model target serializable?



see above answer. you can use an ldm and in load() return new instance every
time. also consider creating a simple serializable bean for wicket form that
maps onto your object.

I'm fairly certain that I won't be deploying

Wicket with clustering (or at least not session clustering like with
Tomcat or Terracotta - I might cluster at the database level) so why
should I need to be forced to make all my data serializable?



there are other reasons why you need to make things serializable. first -
everything you put into httpsession - where wicket stores pages - must be
serializable. that is a requirement of the servlet spec.

second, wicket versions your objects to make backbutton work - that means
taking snapshots of objects - which means serializing them.

third, for efficiency wicket takes snapshots of pages and stores them to
disk - which you guessed it, requires serialization.

IModel is in part to allow the dto beans to not be serializable if you do
not want them to.

-igor
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Efficient DynamicResource Handling

2007-07-16 Thread Igor Vaynberg

On 7/16/07, spencer.c [EMAIL PROTECTED] wrote:



I have a DynamicWebResource which is going to pull data out of a database.
Some of the downloads will end up being quite large (possibly a couple of
hundred MB).

I have successfully implemented the functionality using DynamicWebResource
and extending ResourceState to provided the correct byte array.  My
concern
is that this method will not scale, as it involves loading the entire
download byte array into memory.

Is there a way to do this more efficiently?  Looking at
DynamicWebResource,
it looks like perhaps I could just override IResourceStream
getResourceStream() instead of the getResourceState() method.  Any
problems/gotchas doing that?  Is there a more standard/wicket way of
doing
it that I should be aware of?



sounds to me like you are starting in the wrong place in the hierarchy.
perhaps you should extend WebResource, or maybe even Resource itself.

-igor



Thanks!



--
View this message in context:
http://www.nabble.com/Efficient-DynamicResource-Handling-tf4088361.html#a11620660
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] setVesible for the component after onEvent

2007-07-16 Thread Igor Vaynberg

in that case you have to call setvisible, but add the parent of the
component to the ajaxrequesttarget instead

-igor


On 7/16/07, kenixwong [EMAIL PROTECTED] wrote:



i m using wicket 1.2.4, setoutputmarkupplaceholdertag(true) is came from
wicket 1.3.0?



igor.vaynberg wrote:

 On 7/16/07, kenixwong [EMAIL PROTECTED] wrote:



 It work, but oaly the first time. Mean after i clicked on the radio few
 times, it nothing happen.


 try calling setoutputmarkupplaceholdertag(true) on all components you
are
 planning to call setvisible(false) when you create them

 -igor



 thanks for help...
 --
 View this message in context:

http://www.nabble.com/setVesible-for-the-component-after-onEvent-tf4086024.html#a11613360
 Sent from the Wicket - User mailing list archive at Nabble.com.



-
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user



-
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user



--
View this message in context:
http://www.nabble.com/setVesible-for-the-component-after-onEvent-tf4086024.html#a11641371
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] using images in wicket

2007-07-13 Thread Igor Vaynberg

On 7/12/07, verbal evasion [EMAIL PROTECTED] wrote:


thank you for the response igor, you are helpful as always. this may be a
totally stupid question, but i am using wicket.* but there seems to be
another org.apache.wicket.* and the ContextImage is only in that version?
why are there two different versions? i am getting my wicket and
wicket-extensions from maven1.x

 !-- wicket libraries --
dependency
groupIdwicket/groupId
artifactIdwicket/artifactId
version 1.2.6/version
propertieswar.bundletrue/war.bundle/properties
/dependency
dependency
groupIdwicket/groupId
artifactIdwicket-extensions/artifactId
version1.2.6/version
propertieswar.bundletrue/war.bundle/properties
/dependency



1.2.6 is hosted at sf.net and is in wicket.*

wicket moved to apache - which requires the package to be
org.apache.wicket.*

version 1.3 will be the first apache release - so 1.3 beta and snapshots are
in org.apache.wicket.*

ContextImage only exists in 1.3 version, in 1.2.6 you can use
servletresponse to reconstruct the absolute path yourself.

-igor





thanks,


verbal

On 7/12/07, Igor Vaynberg [EMAIL PROTECTED] wrote:

 then use ContextImage component

 -igor


 On 7/12/07, verbal  [EMAIL PROTECTED] wrote:
 
 
  I want to do it dynamically though. As in based on some logic, display
  1 of n files.
 
  Thanks,
 
  verbal
 
  On Jul 12, 2007, at 7:13 PM, Igor Vaynberg  [EMAIL PROTECTED]
  wrote:
 
  On 7/12/07, verbal evasion   [EMAIL PROTECTED]
  [EMAIL PROTECTED] wrote:
  
   actually, doing url.getContent() doesnt seem to work. can someone
   please help me out?
 
 
  in your markup just do img src=img/foo.gif/ wicket will rewrite
  that url to be context-relative so /mycotnext/img/foo.gif which will map to
  webapp/img/foo.gif
 
  -igor
 
 
 
  thanks,
  
   verbal
  
   On 7/12/07, verbal evasion   [EMAIL PROTECTED]
   [EMAIL PROTECTED] wrote:
   
so i realized that i probably just want to access the image via a
URL. the question now is i cant seem to access it with a relative page. 
do
you think i should just URL.getContent() and then save it in my
WebApplication? seems weird, but whatever i guess. i would still like to
find out how to figure out the header of the URL from the current 
running
context.
   
thanks,
   
verbal
   
On 7/12/07, verbal evasion   [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:

 i am deploying my web application (including website using
 wicket) in an ear. there are files in the ear under the webapp/img 
directory
 and i would like to load them to use with Image and ImageMap. I dont 
know
 how to specify the path. i do not want to use the absolute FS path. i 
would
 like to specify the path relative to the webapp directory so i can 
just do
 like /img/mypicture.png. i dont know how to do that. i can read the 
image
 from a database by using a Resource and overriding getResourceStream 
or use
 an image resource and overwrite getImageData, but what's the best way 
to
 load an image file thats in the ear? maybe this isnt such a wicket 
question
 but more of an ear question. thanks for the help anyway.

 verbal

   
   
  
  
   -
   This SF.net email is sponsored by DB2 Express
   Download DB2 Express C - the FREE version of DB2 express and take
   control of your XML. No limits. Just data. Click to get it now.
   http://sourceforge.net/powerbar/db2/http://sourceforge.net/powerbar/db2/
   ___
   Wicket-user mailing list
Wicket-user@lists.sourceforge.net
   Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user
   https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
 
  -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
 
  ___
  Wicket-user mailing list
   Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 
  -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 


 -
 This SF.net email is sponsored

Re: [Wicket-user] Regarding onchange DropDown

2007-07-13 Thread Igor Vaynberg

On 7/12/07, Edi [EMAIL PROTECTED] wrote:



Hi!

I have one drop down like

selectoptiontextbox/optionoptiontextarea/option/select

in the above case, I have 2 items, 1.textbox 2.textarea.

If I select textbox, text box should be displayed below the combo box. If
I
select textarea, textarea should be displayed but textbox should be hided.

If I did not select anything, both textbox and textarea should be hided.

I have done using javascript. But I don't know how it is in Wicket?




simplest way to do this would be to add two wicket HiddenFields - one for
value of textbox and one for textarea, and then link them to the ones you
created in the javascript.

-igor

I am newbie. So please give me your suggestions.



Thanking You.


Regards,
Edi

--
View this message in context:
http://www.nabble.com/Regarding-onchange-DropDown-tf4072549.html#a11574089
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Regarding onchange DropDown

2007-07-13 Thread Igor Vaynberg

On 7/13/07, Igor Vaynberg [EMAIL PROTECTED] wrote:


On 7/13/07, Edi [EMAIL PROTECTED] wrote:


 Could you please explain in detail manner?



whats there to explain? in form.onsubmit or onchange event copy values
from your textarea/textfield to the appropriate hiddenfield element via
javascript.

then when your form submits you can read the value out of that hiddenfield
on serverside.



im not even sure you need the hiddenfield stuff, you might be able to do it
directly on textfield/textarea wicket components. just add both of them.
afaik if the tag is hidden via javascript it will not submit its value - so
it should work automagically as long as you display:none one of them.

-igor



-igor




igor.vaynberg wrote:
 
  On 7/12/07, Edi [EMAIL PROTECTED] wrote:
 
 
  Hi!
 
  I have one drop down like
 
  selectoptiontextbox/optionoptiontextarea/option/select
 
  in the above case, I have 2 items, 1.textbox 2.textarea.
 
  If I select textbox, text box should be displayed below the combo
 box. If
  I
  select textarea, textarea should be displayed but textbox should be
  hided.
 
  If I did not select anything, both textbox and textarea should be
 hided.
 
  I have done using javascript. But I don't know how it is in Wicket?
 
 
 
  simplest way to do this would be to add two wicket HiddenFields - one
 for
  value of textbox and one for textarea, and then link them to the ones
 you
  created in the javascript.
 
  -igor
 
  I am newbie. So please give me your suggestions.
 
 
 
  Thanking You.
 
  Regards,
  Edi
 
  --
  View this message in context:
  http://www.nabble.com/Regarding-onchange-DropDown-tf4072549.html#a11574089

  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

 --
 View this message in context:
 http://www.nabble.com/Regarding-onchange-DropDown-tf4072549.html#a11574713
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -

 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Regarding onchange DropDown

2007-07-13 Thread Igor Vaynberg

On 7/13/07, Edi [EMAIL PROTECTED] wrote:



Could you please explain in detail manner?




whats there to explain? in form.onsubmit or onchange event copy values from
your textarea/textfield to the appropriate hiddenfield element via
javascript.

then when your form submits you can read the value out of that hiddenfield
on serverside.

-igor



igor.vaynberg wrote:


 On 7/12/07, Edi [EMAIL PROTECTED] wrote:


 Hi!

 I have one drop down like

 selectoptiontextbox/optionoptiontextarea/option/select

 in the above case, I have 2 items, 1.textbox 2.textarea.

 If I select textbox, text box should be displayed below the combo box.
If
 I
 select textarea, textarea should be displayed but textbox should be
 hided.

 If I did not select anything, both textbox and textarea should be
hided.

 I have done using javascript. But I don't know how it is in Wicket?



 simplest way to do this would be to add two wicket HiddenFields - one
for
 value of textbox and one for textarea, and then link them to the ones
you
 created in the javascript.

 -igor

 I am newbie. So please give me your suggestions.



 Thanking You.

 Regards,
 Edi

 --
 View this message in context:

http://www.nabble.com/Regarding-onchange-DropDown-tf4072549.html#a11574089
 Sent from the Wicket - User mailing list archive at Nabble.com.



-
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user



-
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user



--
View this message in context:
http://www.nabble.com/Regarding-onchange-DropDown-tf4072549.html#a11574713
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] stateless ajax behavior

2007-07-13 Thread Igor Vaynberg

On 7/13/07, Andrew Klochkov [EMAIL PROTECTED] wrote:


Recently we've done some performance tests and obviously we have to make
most of our pages stateless to support large number of active user
sessions.



could you publish your test results please, because it is not so obvious to
me.

-igor
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Please anyone, a hint?

2007-07-13 Thread Igor Vaynberg

why dont you create a quickstart so we can run it real quick and see

-igor


On 7/13/07, Francisco Diaz Trepat - gmail [EMAIL PROTECTED]
wrote:


Hi all, I wanted to see if I could add an autocomplete that displays a
little table (3 columns).

It is a simple locations table that shows a ZIPCODE a Provine/City and a
Canton/Kanton (CH) field. I already have it working with the default
IAutoCompleteRenderer, that renders an Unordered list:

ul
   li textvalue=800080328032 Neumünster ZH/li
etc...
/ul

I tried my own renderer putting a table on the renderHeader method. Then
the TableRow and TableData elements in the render. And finally a the end of
Table element in the renderFooter method.

This worked fine for look and feel but I lost the selection up and down
behavior. And also the Click selecting behavior that put the innerHtml on
the textfield as says in the documentation if no textvalue was available. I
put the textvalue on the tr textvalue=bla and also I tried to put it in
the td element.

Can some one help me out a bit?


Regards,

f(t)

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] stateless wicket?

2007-07-13 Thread Igor Vaynberg

On 7/13/07, Patrick Angeles [EMAIL PROTECTED] wrote:


Hi,

I have a question regarding this... I understand that in 1.3, previous
page states are serialized to the file system and only the current page
state stays in HttpSession. How would this work in a clustered web container
that synchronizes the HttpSession object to other nodes? Do you lose the
history?



no. think about it - you replicate the current page every request - which
means each node can save them to disk also.

-igor
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Please anyone, a hint?

2007-07-13 Thread Igor Vaynberg

On 7/13/07, Francisco Diaz Trepat - gmail [EMAIL PROTECTED]
wrote:


Here is the quick start. Well is actually a netbeans project without the
war and build contents.

Is that what you expected? please let me know.



i dont mind that it is a netbeans project, but i do mind that it doesnt have
a pom so i cannot do mvn eclipse:eclipse and get an eclipse project set up
quickly.

the idea way to build a quickstart is to use the new maven archetype in svn,
or checkout wicket-quickstart. once you do that modify it to reproduce the
testcase. that way all the core devs have to do is import it into eclipse
with a command and have a running project.

i dont want to spend my time setting up a project manually.

-igor





thanks,

f(t)


On 7/13/07, Igor Vaynberg [EMAIL PROTECTED] wrote:

 why dont you create a quickstart so we can run it real quick and see

 -igor


  On 7/13/07, Francisco Diaz Trepat - gmail [EMAIL PROTECTED]
 wrote:

   Hi all, I wanted to see if I could add an autocomplete that displays
  a little table (3 columns).
 
  It is a simple locations table that shows a ZIPCODE a Provine/City and
  a Canton/Kanton (CH) field. I already have it working with the default
  IAutoCompleteRenderer, that renders an Unordered list:
 
  ul
 li textvalue=800080328032 Neumünster ZH/li
  etc...
  /ul
 
  I tried my own renderer putting a table on the renderHeader method.
  Then the TableRow and TableData elements in the render. And finally a the
  end of Table element in the renderFooter method.
 
  This worked fine for look and feel but I lost the selection up and
  down behavior. And also the Click selecting behavior that put the innerHtml
  on the textfield as says in the documentation if no textvalue was available.
  I put the textvalue on the tr textvalue=bla and also I tried to put it
  in the td element.
 
  Can some one help me out a bit?
 
 
  Regards,
 
  f(t)
 
 
  -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] RepeatingView Class API

2007-07-13 Thread Igor Vaynberg

fixed

-igor


On 7/12/07, Ballist1c [EMAIL PROTECTED] wrote:



Hey guys,

Ive been reading the apidoc for RepeatingView, and there is one thing that
is completely throwing me off.

As taken from the API



http://wicket.sourceforge.net/wicket-extensions/apidocs/wicket/extensions/markup/html/repeater/RepeatingView.html


It says  A repeater view that renders all of its children, using its body
markup, in the order they were added.

Example:

Java:

RepeatingView view = new RepeatingView(repeater);
view.add(new Label(1, hello));
view.add(new Label(2, goodbye));
view.add(new Label(3, good morning));

Yet the code yields, according to the APIdoc

Yields:

  ulligoodbye/lilihello/liligood morning/li/ul

I was under the impression it would be
ullihello/liligoodbye/liligood morning/li/ul??


--
View this message in context:
http://www.nabble.com/RepeatingView-Class-API-tf4071880.html#a11572096
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] stateless wicket?

2007-07-13 Thread Igor Vaynberg

hrm, i thought the current page is stored in session?

-igor


On 7/13/07, Eelco Hillenius [EMAIL PROTECTED] wrote:


  I have a question regarding this... I understand that in 1.3, previous
 page states are serialized to the file system and only the current page
 state stays in HttpSession. How would this work in a clustered web
container
 that synchronizes the HttpSession object to other nodes? Do you lose the
 history?

 no. think about it - you replicate the current page every request -
which
 means each node can save them to disk also.

Except for the fact that the pages aren't actually set as sessions
attributes to start with...

Eelco

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Wicket 1.3.0-beta2 OutOfMemoryError

2007-07-13 Thread Igor Vaynberg

how about NonPageCachingDummyWebApplication?

-igor


On 7/13/07, Eelco Hillenius [EMAIL PROTECTED] wrote:


On 7/13/07, Scott Swank [EMAIL PROTECTED] wrote:
 That sounds like a lovely inner class for WicketTester.

 tester = new WicketTester(new WicketTester.NonCachingWebApplication());

Done. I called it NonCachingDummyWebApplication.

Eelco

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Navigator customization

2007-07-12 Thread Igor Vaynberg

On 7/11/07, nazeem [EMAIL PROTECTED] wrote:



I have the same case where I wanted to customize the navigation toolbar to
add few action menu items as well. So I have written my own version of
AjaxFallbackCustomDataTable by just copying the
AjaxFallbackDefaultDataTable
code in to my package and renaming. There I have commented all addition of
toolbars and I am adding them at the time of declaring it.


public AjaxFallbackCustomDataTable(String id, final IColumn[] columns,
SortableDataProvider dataProvider, int
rowsPerPage)
{
super(id, columns, dataProvider, rowsPerPage);
setOutputMarkupId(true);
setVersioned(false);
//addTopToolbar(new AjaxNavigationToolbar(this));
//addTopToolbar(new AjaxCustomNavigationToolbar(this));
//addTopToolbar(new AjaxFallbackHeadersToolbar(this,
dataProvider));
addBottomToolbar(new NoRecordsToolbar(this));
}

During declaration,

AjaxFallbackCustomDataTable table = new
AjaxFallbackCustomDataTable(employeesAjax, columns, dataProvider, 7);
AbstractToolbar navigationTB = new AjaxCustomNavigationToolbar(table);
navigationTB.add(new Label(newSpan));
table.addTopToolbar(navigationTB);
table.addTopToolbar(new AjaxFallbackHeadersToolbar(table, dataProvider));
AjaxPagingNavigator pgNav = new AjaxPagingNavigator(paging, table);
add(table);

From the above code, it is clear that I have customized the
AjaxDefaultNavigationToolbar to AjaxCustomNavigationToolbar. The markup
html
is also copied and renamed to the same..html. So the problem here is that
I
am trying to add some action menus to the navigation toolbar, at
declaration, but it doesn't work.
navigationTB.add(new Label(newSpan));

I have also modified the markup to contain wicket:id=newSpan.

wicket:panel
tr class=navigation
td wicket:id=span
div class=actionmenu style=float: left; width:
50%;
lt;span
wicket:id=newSpangt;lt;/spangt;
 New nbsp;nbsp;
 # Save nbsp;nbsp;
 # Delete nbsp;nbsp;nbsp;nbsp;
Filternbsp;input type=text
style=/nbsp;nbsp;
 resr/table/img/find.png
/div
div style=float: left; padding-right:
20px;[navigator-label]/div
div style=text-align: right;[navigator]/div
/td
/tr
/wicket:panel


But I am getting the error that

[2007-07-12 10:24:11,453] [ERROR] [btpool0-2]
[wicket.RequestCycle.step(1043)] - Unable to find component with id
'newSpan' in [MarkupContainer [Component id = thirdPartyDetails, page =
[...]




if you look at your markup your newspan is in toolbar.span.newspan not in
toolbar.newspan. so you need to create your own version of toolbar by adding
all the pieces yourself instead of trying to add them to the toolbar so you
have full control of composition.

-igor
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Can I show and hide a form using javascript still do form processing on the server ?

2007-07-12 Thread Igor Vaynberg

On 7/12/07, atul singh [EMAIL PROTECTED] wrote:


Hi,
I want to show and hide forms using javascript, but this will not have
components on the server.How do I process the form on the server.
What is the reccomended way to do this??
Do I have to make a server call for this?(Based on my experience I feel
ajax is the way supported in wicket, but i dont want it that way)
Thanks
atul




make your form action point to a bookmarkable page. give that page a
(PageParameters params) constructor, and you can pull form values out of
there

-igor


-

This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] TabbedPanel tabs instanciation

2007-07-12 Thread Igor Vaynberg

On 7/12/07, Xavier Hanin [EMAIL PROTECTED] wrote:


Hi,

When debugging my application which uses a TabbedPanel, I realized that
one tab was unnecessarily instanciated. After some investigation the reason
is simply because I call setSelectedTab based on the parameters of my page,
but since the instanciation of a TabbedPanel call setSelectedTab(0), the
first tab is always instanciated, even though I don't need to render it.

Do anyone know a workaround for this?



i guess tabbedpanel will have to be rewritten to call setactivettab(0) in
onattach if no explicit call has been made. patch is welcome

-igor



Xavier


--
Xavier Hanin - Independent Java Consultant
http://xhab.blogspot.com/
http://incubator.apache.org/ivy/
http://www.xoocode.org/
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Is it possible to test Wicket templates out-of-container?

2007-07-12 Thread Igor Vaynberg

On 7/12/07, mraible [EMAIL PROTECTED] wrote:



Is it possible to use Tapestry's parser in tests to verify that template
syntax is correct?



probably yes, wicket also has a pullparser implementation you can use, or
any other html parser. our tests compare string buffer of httpservletrequest
to a prerendered string which isnt ideal, but works for us.

I'd like to run tests (like you do when doing a JSP pre-compile) to verify

syntax w/o having to start the app and find out at runtime.



yeah, see how our tests work.

Also, is it possible to adjust Wicket's template caching strategy? In other

words, is it possible to make it like JSP where there's a timestamp check
to
see if a page has been updated?


I realize I can turn off page caching, but does that make Wicket slower than

a JSP-based solution? Can I provide my own implementation (or configure
the
existing one) to check every 2 minutes?



like eelco said, in devel mode this is the default for markup only. if you
want class reloading there is a reloadingwicketfilter, or whatever its
called. in production reloading templates is rarely necessary. for cases
that require them there are a few solutions: you can do what eelco said and
implement your own markup cache which will change globally how all template
caching works, if you have a requierment where only certain pages/components
need to be reloaded while the app is  deployed you can let them implement
imarkupcachekeyprovider and override the cache key.

-igor
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] using images in wicket

2007-07-12 Thread Igor Vaynberg

On 7/12/07, verbal evasion [EMAIL PROTECTED] wrote:


actually, doing url.getContent() doesnt seem to work. can someone please
help me out?



in your markup just do img src=img/foo.gif/ wicket will rewrite that url
to be context-relative so /mycotnext/img/foo.gif which will map to
webapp/img/foo.gif

-igor



thanks,


verbal

On 7/12/07, verbal evasion  [EMAIL PROTECTED] wrote:

 so i realized that i probably just want to access the image via a URL.
 the question now is i cant seem to access it with a relative page. do you
 think i should just URL.getContent() and then save it in my
 WebApplication? seems weird, but whatever i guess. i would still like to
 find out how to figure out the header of the URL from the current running
 context.

 thanks,

 verbal

 On 7/12/07, verbal evasion  [EMAIL PROTECTED] wrote:
 
  i am deploying my web application (including website using wicket) in
  an ear. there are files in the ear under the webapp/img directory and i
  would like to load them to use with Image and ImageMap. I dont know how to
  specify the path. i do not want to use the absolute FS path. i would like to
  specify the path relative to the webapp directory so i can just do like
  /img/mypicture.png. i dont know how to do that. i can read the image from
  a database by using a Resource and overriding getResourceStream or use an
  image resource and overwrite getImageData, but what's the best way to load
  an image file thats in the ear? maybe this isnt such a wicket question but
  more of an ear question. thanks for the help anyway.
 
  verbal
 



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Is it possible to test Wicket templates out-of-container?

2007-07-12 Thread Igor Vaynberg

On 7/12/07, mraible [EMAIL PROTECTED] wrote:




Is it possible to expire the page cache with JMX? Or even better, expire
individual pages from the cache with JMX?



i dont think so, but i also dont think it will be very difficult to
implement. we already have a jmx bean here [1], so all thats needed is to
just plugin that feature. the thing im not sure yet is how public the
markupcache api is, so we might have to tweak that somewhat. an rfe or a
patch are welcome.

[1]
http://svn.apache.org/repos/asf/incubator/wicket/trunk/jdk-1.5/wicket-jmx/

-igor





Thanks,


Matt
--
View this message in context:
http://www.nabble.com/Is-it-possible-to-test-Wicket-templates-out-of-container--tf4071714.html#a11572349
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] using images in wicket

2007-07-12 Thread Igor Vaynberg

then use ContextImage component

-igor


On 7/12/07, verbal [EMAIL PROTECTED] wrote:



I want to do it dynamically though. As in based on some logic, display 1
of n files.

Thanks,

verbal

On Jul 12, 2007, at 7:13 PM, Igor Vaynberg [EMAIL PROTECTED]
wrote:

On 7/12/07, verbal evasion  [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:

 actually, doing url.getContent() doesnt seem to work. can someone please
 help me out?


in your markup just do img src=img/foo.gif/ wicket will rewrite that
url to be context-relative so /mycotnext/img/foo.gif which will map to
webapp/img/foo.gif

-igor



thanks,

 verbal

 On 7/12/07, verbal evasion  [EMAIL PROTECTED]
 [EMAIL PROTECTED] wrote:
 
  so i realized that i probably just want to access the image via a URL.
  the question now is i cant seem to access it with a relative page. do you
  think i should just URL.getContent() and then save it in my
  WebApplication? seems weird, but whatever i guess. i would still like to
  find out how to figure out the header of the URL from the current running
  context.
 
  thanks,
 
  verbal
 
  On 7/12/07, verbal evasion  [EMAIL PROTECTED]
  [EMAIL PROTECTED] wrote:
  
   i am deploying my web application (including website using wicket)
   in an ear. there are files in the ear under the webapp/img directory and i
   would like to load them to use with Image and ImageMap. I dont know how to
   specify the path. i do not want to use the absolute FS path. i would like 
to
   specify the path relative to the webapp directory so i can just do like
   /img/mypicture.png. i dont know how to do that. i can read the image 
from
   a database by using a Resource and overriding getResourceStream or use an
   image resource and overwrite getImageData, but what's the best way to load
   an image file thats in the ear? maybe this isnt such a wicket question but
   more of an ear question. thanks for the help anyway.
  
   verbal
  
 
 


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.netWicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/

___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] ListViews dynamic Forms

2007-07-11 Thread Igor Vaynberg

if you enable listview.reuseitems(true) your values should stick. make
addbutton.defaultformprocessing(false).

the idea here is that reuseitems will cause the comeponentpath of textfields
not change - which will cause their name attribute not to change also -
which will cause them to pick up the submitted value from last request. make
sure that all addbutton.submit does is add a value to the ened of the
listview's model.

-igor

On 7/11/07, Jan Kriesten [EMAIL PROTECTED] wrote:



Hi,

update on this topic:

I've found a workaround to update the ListViews childrens Models by
walking the
Components below ListView with an IVisitor and do a updateModel() on all
FormComponents.

The question remains, if there's a way to do this without updating the
Model?

Best regards, --- Jan.



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] How to read HTTP headers in WebPage

2007-07-11 Thread Igor Vaynberg

((webrequest)getrequest()).gethttpservletrequest()

-igor


On 7/11/07, Goran Novak [EMAIL PROTECTED] wrote:



Hi.

How can I read http header from a subclass of WebPage?

In javax.servlet.http.HttpServlet I could get http header from
javax.servlet.http.HttpServletRequest.getHeader(headerName)

wicket.Request doesn't have similar method. And I can't find another way
to
do it.

--
Goran
--
View this message in context:
http://www.nabble.com/How-to-read-HTTP-headers-in-WebPage-tf4063402.html#a11544957
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Dead? addComponentInstantiationListener(new SpringComponentInjector(this));

2007-07-11 Thread Igor Vaynberg

On 7/11/07, Tremelune [EMAIL PROTECTED] wrote:



Bingo, thanks. I'll add that to my mavenization...That threw me for a
loop!



you dont need to reference it directly in your pom, its transient from
wicket-spring - just need to rebuild your project with mvn eclipse:eclipse

-igor



This might be caused by a missing wicket-ioc JAR in your project.  I think

sometime between before beta2, a new IOC project was introduced.  If
you're
compiling from SVN, this should be another project directory.

--
View this message in context:
http://www.nabble.com/Dead--addComponentInstantiationListener%28new-SpringComponentInjector%28this%29%29--tf4064885.html#a11550113
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Click a tree node link to load a local file

2007-07-10 Thread Igor Vaynberg

see source code of DownloadLink

-igor


On 7/9/07, kenixwong [EMAIL PROTECTED] wrote:



Hi,

is there anybody have the idea how to load a local file once click on the
tree node link. Below is the part of the ResourceLink .

ResourceLink exportAsPdf = new ResourceLink(exportAsPdf, new Resource(){

@Override
public IResourceStream getResourceStream() {
try {
exportAsPdf(newPath);

String currentFile =
System.getProperty(user.dir);
return new
UrlResourceStream(new URL(file:/// + currentFile+
/Reports/MasterFile.pdf));

} catch (Exception e) {
e.printStackTrace();
error(e.getMessage());
}

return null;
}
});


And right now i wish to change into tree node link. can anybody give me a
guide ?

thanks a lot
--
View this message in context:
http://www.nabble.com/Click-a-tree-node-link-to-load-a-local-file-tf4033801.html#a11459189
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Linking CSS

2007-07-10 Thread Igor Vaynberg

On 7/10/07, Juan Asensio Sánchez [EMAIL PROTECTED] wrote:


Hi everybody

I am trying to link a CSS file to my template using this code:

wicket:head
wicket:link
link rel=Stylesheet type=text/css href=css/main.css media=screen
/
wicket:link
/wicket:head

Also tried with:

wicket:head
link wicket:id=CSSMain rel=Stylesheet type=text/css
href=css/main.css media=screen /
/wicket:head

But in both cases i get this in the code of the response page:

link
href=/Bujero/test/resources/es.bytelecom.bujero.web.pages.common.BaseWebPage/css/main_es_ES.css
rel=stylesheet type=text/css media=screen/

That URL gets a 404 error. That long name is actually the package and
the class where the css file is stored, that is not an error being so
long.

Also, 'es_ES' is added to the filename, how to remove?

Thanks.



so your main.css is under
classes/es/bytelecom/bujero/web/pages/common/css/main.css ? from the looks
of it thats where it should be.

dont worry about es_ES in the name, since the url is pointing to a wicket
resource instead of the file itself wicket will cascade search:
main_es_ES.css, main_es.css, main.css and should find the last.

-igor



-

This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Linking CSS

2007-07-10 Thread Igor Vaynberg

On 7/10/07, Juan Asensio Sánchez [EMAIL PROTECTED] wrote:


Well i had an error in my previous mail. Actually i am using this code
(i am developing a theme engine), so i use this code in the html
template:

link wicket:id=CSSMain rel=stylesheet type=text/css
href=css/main.css media=screen /

And this in the associated webpage:

add(new StyleSheetReference(CSSMain, getClass(), css/main.css));

So, the generated code is this:

link
href=/Bujero/test/resources/es.bytelecom.bujero.web.themes.mollio.es.bytelecom.bujero.web.pages.common.BaseWebPage/css/main.css
rel=stylesheet type=text/css media=screen/

That long package name is correct (it includes the theme package name,
es.bytelecom.web.themes.mollio, and the name of the page being
rendered, es.bytelecom.bujero.web.pages.common.BaseWebPage), the file

WEB-INF/classes/es/bytelecom/bujero/web/themes/mollio/es/bytelecom/bujero/web/pages/common/css/main.css
DOES exist, but the file is not loaded and if i type that URL in the
browser i get a 404 error.

Any idea? THanks again.



set a breakpoint in the wicket filter and see exactly where it doesnt find
the file. one thing i would watch out for is the getClass() call as it
changes when you subclass, better do BaseWebPage.class instead

-igor



2007/7/10, Igor Vaynberg [EMAIL PROTECTED]:

 On 7/10/07, Juan Asensio Sánchez [EMAIL PROTECTED] wrote:

  Hi everybody
 
  I am trying to link a CSS file to my template using this code:
 
  wicket:head
  wicket:link
  link rel=Stylesheet type=text/css href=css/main.css
media=screen
 /
  wicket:link
  /wicket:head
 
  Also tried with:
 
  wicket:head
  link wicket:id=CSSMain rel=Stylesheet type=text/css
  href=css/main.css media=screen /
  /wicket:head
 
  But in both cases i get this in the code of the response page:
 
  link

href=/Bujero/test/resources/es.bytelecom.bujero.web.pages.common.BaseWebPage/css/main_es_ES.css
  rel=stylesheet type=text/css media=screen/
 
  That URL gets a 404 error. That long name is actually the package and
  the class where the css file is stored, that is not an error being so
  long.
 
  Also, 'es_ES' is added to the filename, how to remove?
 
  Thanks.

 so your main.css is under
 classes/es/bytelecom/bujero/web/pages/common/css/main.css ?
 from the looks of it thats where it should be.

 dont worry about es_ES in the name, since the url is pointing to a
wicket
 resource instead of the file itself wicket will cascade search:
 main_es_ES.css, main_es.css, main.css and should find the last.

 -igor



 

-
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 



-
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


  1   2   3   4   5   6   7   8   9   10   >