Opened 13 years ago

Closed 13 years ago

Last modified 11 years ago

#7654 closed defect (invalid)

Creating dijit.form.Button programmatically removes trailing elements

Reported by: coldfire22x Owned by:
Priority: high Milestone: tbd
Component: Dijit - Form Version: 1.2beta
Keywords: dijit.form.Button Cc:
Blocked By: Blocking:


Version 1.2.0b2

When creating a dijit.form.Button programmatically with the following markup, it removes all trailing elements from the DOM:

        var button = new dijit.form.Button({ label: "Click me!" }, "buttonNode");


    <button id="buttonNode" />
    <div>Where'd I go?</div>

It does work with the following markup.

    <button id="buttonNode"></button>
    <div>Oh here I am</div>

Change History (4)

comment:1 Changed 13 years ago by bill

Resolution: invalid
Status: newclosed

Unfortunately this is a user error. HTML is not XML; specifically <button/> is invalid HTML. It's interpreted the same as <button>.

So this is invalid / wontfix.

comment:2 Changed 13 years ago by coldfire22x

While not valid HTML, it is valid XHTML.

Perhaps the example located at should be updated to indicate that it is not compatible using XHTML rules?

comment:3 Changed 13 years ago by bill

I've just updated the button example to be standard HTML to avoid any confusion.

comment:4 Changed 11 years ago by bill

Component: DijitDijit - Form
Note: See TracTickets for help on using tickets.