Opened 9 years ago

Closed 9 years ago

#12069 closed defect (fixed)

ContentPane: content lost when programatically attaching a widget to a div element

Reported by: bobgallagher Owned by: bill
Priority: high Milestone: 1.6
Component: Dijit Version: 1.5
Keywords: Cc:
Blocked By: Blocking:

Description

The following sample snippet worked fine with dojo 1.5 however in the current stream the content of the div disappears.

<body class="tundra">
<div id="mainContent">
  content body
</div>
<script type="text/javascript">
  dojo.require("dijit.layout.ContentPane");
  dojo.addOnLoad(function() {
    new dijit.layout.ContentPane({
      title : "pane one"
    }, "mainContent").startup();
  });
</script>
</body>

Change History (2)

comment:1 Changed 9 years ago by bill

Component: GeneralDijit
Milestone: tbd1.6
Owner: changed from anonymous to bill
Status: newassigned
Summary: content lost when programatically attaching a widget to a div elementContentPane: content lost when programatically attaching a widget to a div element

It works if you pass in dojo.byId("mainContent"). I'll fix it for the string case in your example, thanks.

comment:2 Changed 9 years ago by bill

Resolution: fixed
Status: assignedclosed

(In [23333]) Missing dojo.byId(), srcNodeRef may be a string, fixes #12069 !strict.

Note: See TracTickets for help on using tickets.