You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@wicket.apache.org by Jean-Baptiste Quenot <jb...@apache.org> on 2007/05/02 02:12:32 UTC

Re: Button does not handle

* jcompagner@apache.org:
> Author: jcompagner
> Date: Tue May  1 02:37:59 2007
> New Revision: 533985
> 
> URL: http://svn.apache.org/viewvc?view=rev&rev=533985
> Log:
> we really can't just terminate <button tag for the Button component! (it did break all our solutions!)
> i now only output the value string if it is a <input > what about the name attribute can that be always included?
> 
> Modified:
>     incubator/wicket/trunk/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/form/Button.java
> 
>  	protected void onComponentTag(final ComponentTag tag)
>  	{
> -		checkComponentTag(tag, "input");
> -
>  		// Default handling for component tag
>  		super.onComponentTag(tag);

Hi Johan,

I changed the code to enforce the use of <input> because Button
does not work with <button>, confirmed by Igor on IRC.

If you really want a <button> you should use a Link instead.  Or
if you really want Button, use <input> instead.  Currently it's
not obvious for users that Button does not handle <button>, so
please update your code so that we can bring back the <input> tag
check.

Cheers,
-- 
     Jean-Baptiste Quenot
aka  John Banana   Qwerty
http://caraldi.com/jbq/

Re: Button does not handle

Posted by Johan Compagner <jc...@gmail.com>.
it handles it fine!
it works perfectly in my solutions i have here except when you made that
check
then everything broke for me.

and see my other post <button type="submit"> is or should be the same as
<input type="submit">


johan


On 5/2/07, Jean-Baptiste Quenot <jb...@apache.org> wrote:
>
> * jcompagner@apache.org:
> > Author: jcompagner
> > Date: Tue May  1 02:37:59 2007
> > New Revision: 533985
> >
> > URL: http://svn.apache.org/viewvc?view=rev&rev=533985
> > Log:
> > we really can't just terminate <button tag for the Button component! (it
> did break all our solutions!)
> > i now only output the value string if it is a <input > what about the
> name attribute can that be always included?
> >
> > Modified:
> >     incubator/wicket/trunk/jdk-1.4
> /wicket/src/main/java/org/apache/wicket/markup/html/form/Button.java
> >
> >       protected void onComponentTag(final ComponentTag tag)
> >       {
> > -             checkComponentTag(tag, "input");
> > -
> >               // Default handling for component tag
> >               super.onComponentTag(tag);
>
> Hi Johan,
>
> I changed the code to enforce the use of <input> because Button
> does not work with <button>, confirmed by Igor on IRC.
>
> If you really want a <button> you should use a Link instead.  Or
> if you really want Button, use <input> instead.  Currently it's
> not obvious for users that Button does not handle <button>, so
> please update your code so that we can bring back the <input> tag
> check.
>
> Cheers,
> --
>      Jean-Baptiste Quenot
> aka  John Banana   Qwerty
> http://caraldi.com/jbq/
>

Re: Button does not handle

Posted by Johan Compagner <jc...@gmail.com>.
jip thats my idea.
developers shouldn't be thinking of those things that will just make it
harder
if they think they dropped a button (what ever type it is <input
type="button" or type="submit"> or <button>
it just should work.

johan


On 5/2/07, Eelco Hillenius <ee...@gmail.com> wrote:
>
> Actually, tbh, I think it's kind of ugly we Buttons and SubmitLinks as
> separate entities. Imo, a really good solution would be to just have
> Button, that works on anything Button and SubmitLink work on now.
>
> Eelco
>
> On 5/2/07, Jean-Baptiste Quenot <jb...@apache.org> wrote:
> > * jcompagner@apache.org:
> > > Author: jcompagner
> > > Date: Tue May  1 02:37:59 2007
> > > New Revision: 533985
> > >
> > > URL: http://svn.apache.org/viewvc?view=rev&rev=533985
> > > Log:
> > > we really can't just terminate <button tag for the Button component!
> (it did break all our solutions!)
> > > i now only output the value string if it is a <input > what about the
> name attribute can that be always included?
> > >
> > > Modified:
> > >     incubator/wicket/trunk/jdk-1.4
> /wicket/src/main/java/org/apache/wicket/markup/html/form/Button.java
> > >
> > >       protected void onComponentTag(final ComponentTag tag)
> > >       {
> > > -             checkComponentTag(tag, "input");
> > > -
> > >               // Default handling for component tag
> > >               super.onComponentTag(tag);
> >
> > Hi Johan,
> >
> > I changed the code to enforce the use of <input> because Button
> > does not work with <button>, confirmed by Igor on IRC.
> >
> > If you really want a <button> you should use a Link instead.  Or
> > if you really want Button, use <input> instead.  Currently it's
> > not obvious for users that Button does not handle <button>, so
> > please update your code so that we can bring back the <input> tag
> > check.
> >
> > Cheers,
> > --
> >      Jean-Baptiste Quenot
> > aka  John Banana   Qwerty
> > http://caraldi.com/jbq/
> >
>

Re: Button does not handle

Posted by Eelco Hillenius <ee...@gmail.com>.
Actually, tbh, I think it's kind of ugly we Buttons and SubmitLinks as
separate entities. Imo, a really good solution would be to just have
Button, that works on anything Button and SubmitLink work on now.

Eelco

On 5/2/07, Jean-Baptiste Quenot <jb...@apache.org> wrote:
> * jcompagner@apache.org:
> > Author: jcompagner
> > Date: Tue May  1 02:37:59 2007
> > New Revision: 533985
> >
> > URL: http://svn.apache.org/viewvc?view=rev&rev=533985
> > Log:
> > we really can't just terminate <button tag for the Button component! (it did break all our solutions!)
> > i now only output the value string if it is a <input > what about the name attribute can that be always included?
> >
> > Modified:
> >     incubator/wicket/trunk/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/form/Button.java
> >
> >       protected void onComponentTag(final ComponentTag tag)
> >       {
> > -             checkComponentTag(tag, "input");
> > -
> >               // Default handling for component tag
> >               super.onComponentTag(tag);
>
> Hi Johan,
>
> I changed the code to enforce the use of <input> because Button
> does not work with <button>, confirmed by Igor on IRC.
>
> If you really want a <button> you should use a Link instead.  Or
> if you really want Button, use <input> instead.  Currently it's
> not obvious for users that Button does not handle <button>, so
> please update your code so that we can bring back the <input> tag
> check.
>
> Cheers,
> --
>      Jean-Baptiste Quenot
> aka  John Banana   Qwerty
> http://caraldi.com/jbq/
>