You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Matthieu <m_...@hotmail.com> on 2010/05/27 23:26:42 UTC

DropDownChoice problem

Hello,


I've a problem with the DropDownChoice (and maybe language?). 

I've a Panel who's rendering perfectly when i set the language in "english"
and not rendering when i set in "french"... 


The message from wicket :

WicketMessage: The component(s) below failed to render. A common problem is
that you have 
added a component in code but forgot to reference it in the markup (thus the
component will never be rendered).



1. [Component id = address_city]


Root cause:


org.apache.wicket.WicketRuntimeException: The component(s) below failed to
render. A common problem is that you 
have added a component in code but forgot to reference it in the markup
(thus the component will never be rendered).


1. [Component id = address_city]


My java code is :


final DropDownChoice cityChoice = new DropDownChoice("address_city", new
PropertyModel
(form.getModelObject(), "city"), cityList); (here you can see the
"address_city")


final AjaxFormComponentUpdatingBehavior updatingBehavior2 = new
AjaxFormComponentUpdatingBehavior(

				"onchange") {

			@Override

			protected void onUpdate(AjaxRequestTarget target) {

				getAddress(form, customer_address, cityChoice, the_map);

			}

		};

		cityChoice.add(updatingBehavior2);


		form.add(cityChoice);



My html code is :


<\span wicket:id="address_border"><\input

		wicket:id="address" id="address" class="address"

		title="an address in Belgium" type="text" /><\select
wicket:id="address_city">

I don't really understand why, anyone to explain me the problem?


Thank you.
-- 
View this message in context: http://apache-wicket.1842946.n4.nabble.com/DropDownChoice-problem-tp2233814p2233814.html
Sent from the Wicket - User mailing list archive at Nabble.com.

Re: DropDownChoice problem

Posted by James Carman <ja...@carmanconsulting.com>.
Make sure it's using the markup files you think it is.  Turn on the logging
for the markup finder thingy.

On May 28, 2010 5:23 PM, "Matthieu" <m_...@hotmail.com> wrote:


Hi,

thanks for you input! It's not a html problem, when i copy/paste the
"english" html code (who is working) into my _fr html file, i get the same
error...

yes, i ommited "</select>" in this mail but not in my code :)

and i write my mails in html format so i have to break the html code with \


--
View this message in context:
http://apache-wicket.1842946.n4.nabble.com/DropDownChoice-problem-tp2233814p2235230.html

Sent from the Wicket - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-...

Re: DropDownChoice problem

Posted by Matthieu <m_...@hotmail.com>.
Hi,

thanks for you input! It's not a html problem, when i copy/paste the
"english" html code (who is working) into my _fr html file, i get the same
error...

yes, i ommited "</select>" in this mail but not in my code :)

and i write my mails in html format so i have to break the html code with \


-- 
View this message in context: http://apache-wicket.1842946.n4.nabble.com/DropDownChoice-problem-tp2233814p2235230.html
Sent from the Wicket - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: DropDownChoice problem

Posted by "Dr. Wolf Blecher" <wo...@itk-engineering.de>.
Hi,

just a few guesses:
- I don't think that this is according to a language problem.
- as far as I can see in your HTML code the DropDown is inside the <span
wicket:id="adress_border">, so maybe this is an issue
- may be you just ommited it, but I don't see a closing tag for your <select
wicket:id="adress_city">
- If I remember correctly, there (has been?) is an issue about wicket and the
short format of closing tags like in your input tag. May be you can try
<input wicket:id="address" id="address" class="address" title="an address in
Belgium" type="text"></input>
- According to the error messages you presented, the error is not in the Java
Code but in the HTML markup you provided, so may be you have to look here
I'm not an HTML expert and may be this is valid HTML, but why do you use e.g.
<\span> instead of <span> as opening tag?

Good luck

Wolf

Am 27.05.2010 23:26, schrieb Matthieu:
> 
> Hello,
> 
> 
> I've a problem with the DropDownChoice (and maybe language?). 
> 
> I've a Panel who's rendering perfectly when i set the language in "english"
> and not rendering when i set in "french"... 
> 
> 
> The message from wicket :
> 
> WicketMessage: The component(s) below failed to render. A common problem is
> that you have 
> added a component in code but forgot to reference it in the markup (thus the
> component will never be rendered).
>  
> 1. [Component id = address_city]
>  
> Root cause:
>  
> org.apache.wicket.WicketRuntimeException: The component(s) below failed to
> render. A common problem is that you 
> have added a component in code but forgot to reference it in the markup
> (thus the component will never be rendered).
> 
> 
> 1. [Component id = address_city]
> 
> 
> My java code is :
> 
> 
> final DropDownChoice cityChoice = new DropDownChoice("address_city", new
> PropertyModel
> (form.getModelObject(), "city"), cityList); (here you can see the
> "address_city")
> 
> 
> final AjaxFormComponentUpdatingBehavior updatingBehavior2 = new
> AjaxFormComponentUpdatingBehavior("onchange") {
> 
>	@Override
> 	protected void onUpdate(AjaxRequestTarget target) {
> 
> 		getAddress(form, customer_address, cityChoice, the_map);
> 
> 	}
> 
> };
> 
> cityChoice.add(updatingBehavior2);
> 
> 
> form.add(cityChoice);
> 
>  
> My html code is :
> 
> 
> <\span wicket:id="address_border"><\input wicket:id="address" id="address" class="address"
> title="an address in Belgium" type="text" /><\select wicket:id="address_city">
> 
> I don't really understand why, anyone to explain me the problem?
> 
> 
> Thank you.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org