[Dojo-interest] more contentPane questions
Fredrik Johansson
fredrik at mumme.se
Wed Apr 12 10:28:01 MDT 2006
onsdag 12 april 2006 07:18 skrev Jay Onda:
> Hey all!
>
> I was trying to create a contentpane through my handy dandy script and for
> some reason, its not rendering correctly.
>
>
> What im trying to accomplish:
> Create a div node and attach a content pane that makes an href reference to
> a separate jsp.
>
> What i got done:
> The node gets created, i believe the content pane widget is created (by
> setting alerts it returns, the widget, the widgetId).
> When i view the rendered source, attached to the div tag is an empty span
> tag.
> So whats getting me is why its a span tag, and of course why nothing is
> displaying.
>
> [from viewing rendered source] <div
> id="theNodeToAttachTo"><span></span></div>
>
>
> The Script:
> For simplicity sake, i cut some stuff out.
>
> function domAttachtest()
> {
> var myContentPaneArg = {widgetId:"workplease", style:"width: 100px;
> height: 100px; border: 1px solid red;"};
> var myContentPane = dojo.widget.createWidget('ContentPane',
> myContentPaneArg );
>
> var thatNodeThing = document.getElementById("theNodeToAttachTo");
>
> thatNodeThing.appendChild(myContentPane.domNode);
> }
>
>
> I thought that this would have done the trick. any ideas?
> As always, thanks!
> -Jay
Hi !
Some widgets needs a node to build from so to speak.
Try doing something like:
http://article.gmane.org/gmane.comp.web.dojo.user/6466
Regards
Fredrik johansson
More information about the Dojo-interest
mailing list