heh.. this reminds me of the old days where people would misspell
wicket:id as wicked:id
Martijn
On 2/4/07, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> The line in your markup: <form id="manageColorsForm">
>
> should be:
> <form WICKET:id="manageColorsForm">
>
> Martijn
>
> On 2/4/07, Gregg Bolinger <[EMAIL PROTECTED]> wrote:
> > I can't figure out what the heck I am doing wrong. Been reading Pro
> > Wicket and the examples and running through documentation. Trying to
> > make a very simple admin screen for a Color object. I keep getting the
> > following exception:
> >
> > /*
> >
> > WicketMessage: Unable to find component with id 'name' in
> > [MarkupContainer [Component id = _<body>, page =
> > com.pnp.test.ManageColors, path = 134:_<body>.HtmlBodyContainer,
> > isVisible = true, isVersioned = true]]. This means that you declared
> > wicket:id=name in your markup, but that you either did not add the
> > component to your page at all, or that the hierarchy does not match.
> > [markup =
> > file:/home/gdboling/projects/pnp-wicket/pnp/WEB-INF/classes/com/pnp/test/ManageColors.html,
> > index = 10, current = '<input wicket:id="name" />' (line 12, column 8)]
> >
> > Root cause:
> >
> > wicket.markup.MarkupException: Unable to find component with id 'name'
> > in [MarkupContainer [Component id = _<body>, page =
> > com.pnp.test.ManageColors, path = 134:_<body>.HtmlBodyContainer,
> > isVisible = true, isVersioned = true]]. This means that you declared
> > wicket:id=name in your markup, but that you either did not add the
> > component to your page at all, or that the hierarchy does not match.
> > [markup =
> > file:/home/gdboling/projects/pnp-wicket/pnp/WEB-INF/classes/com/pnp/test/ManageColors.html,
> > index = 10, current = '<input wicket:id="name" />' (line 12, column 8)]
> > at wicket.markup.MarkupStream.throwMarkupException(MarkupStream.java:290)
> >
> > */
> >
> > public class Color implements Serializable
> > {
> > private Integer id;
> > private String name;
> > private String description;
> >
> > // getters and setters ommitted for brevity
> > }
> >
> > I've been through several iterations of a WebPage class. Here is the
> > latest including some commented trial code that wasn't working either.
> >
> > public class ManageColors extends WebPage
> > {
> > @SpringBean
> > private ColorDAO colorDAO;
> >
> > public ManageColors()
> > {
> > final FeedbackPanel feedback = new FeedbackPanel("feedback");
> > add(feedback);
> > Form manageColorsForm = new ManageColorsForm("manageColorsForm");
> > //TextField name = new TextField("name");
> > //TextArea desc = new TextArea("description");
> > //manageColorsForm.setModel(new CompoundPropertyModel(new Color()));
> > //manageColorsForm.add(name);
> > //manageColorsForm.add(desc);
> > add(manageColorsForm);
> > }
> >
> > public final class ManageColorsForm extends Form
> > {
> > public ManageColorsForm(String id)
> > {
> > super(id);
> > Color color = new Color();
> > TextField name = new TextField("name", new
> > PropertyModel(color, "name"));
> > TextArea desc = new TextArea("description", new
> > PropertyModel(color, "description"));
> > add(name);
> > add(desc);
> > }
> >
> > @Override
> > public void onSubmit()
> > {
> >
> > }
> > }
> >
> > }
> >
> > <html>
> > <head>
> > <title>Manage Colors</title>
> > </head>
> > <body>
> > <span wicket:id="feedback"></span>
> > <form id="manageColorsForm">
> >
> > <table>
> > <tr>
> > <td>Color Name:</td>
> > <td><input wicket:id="name" /></td>
> > </tr>
> > <tr>
> > <td>Color Desc</td>
> > <td><textarea wicket:id="description"></textarea></td>
> > </tr>
> > <tr>
> > <td><input type="submit" value="Save" /></td>
> > </tr>
> > </table>
> > </form>
> > </body>
> > </html>
> >
> > Thanks for any tips:
> >
> > Gregg Bolinger
> >
> > -------------------------------------------------------------------------
> > Using Tomcat but need to do more? Need to support web services, security?
> > Get stuff done quickly with pre-integrated technology to make your job
> > easier.
> > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
> > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> > _______________________________________________
> > Wicket-user mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/wicket-user
> >
>
>
> --
> Vote for Wicket at the http://www.thebeststuffintheworld.com/vote_for/wicket
> Wicket 1.2.4 is as easy as 1-2-4. Download Wicket now!
> http://wicketframework.org
>
--
Vote for Wicket at the http://www.thebeststuffintheworld.com/vote_for/wicket
Wicket 1.2.4 is as easy as 1-2-4. Download Wicket now!
http://wicketframework.org
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Wicket-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-user