I'm trying to add a span, inside an anchor, inside a dd tag. for some reason this:
protected Control MakeDD() {
var dd = new HtmlGenericControl("dd");
var link = new HtmlGenericControl("a");
var span = new HtmlGenericControl("span");
link.Controls.Add(span);
dd.Controls.Add(link);
return dd;
}
only generates
<dd><a></a></dd>
instead of
<dd><a><span></span></a></dd>
how do I add controls to a control, then add that control to another control?