Note that there are some explanatory texts on larger screens.

plurals
  1. POAsp.net checkbox list randomly rendering span
    text
    copied!<p>I am using an asp.net asp:CheckBoxList with RepeatLayout="UnorderedList"</p> <p>It has always rendered the output as (with some values missing for brevity)</p> <pre><code>&lt;ul class="checkbox unstyled"&gt; &lt;li&gt;&lt;input type="checkbox" value="17"&gt;&lt;label&gt;Label Name&lt;/label&gt;&lt;/li&gt; &lt;/ul&gt; </code></pre> <p>but all of a sudden I am getting a span rendered into the list</p> <pre><code>&lt;ul class="checkbox unstyled"&gt; &lt;li&gt;&lt;span alt="17"&gt;&lt;input type="checkbox" value="17"&gt;&lt;label&gt;Label Name&lt;/label&gt;&lt;/span&gt;&lt;/li&gt; &lt;/ul&gt; </code></pre> <p>being produced by the following code</p> <pre><code>&lt;div class="control-group" &gt; &lt;label class="control-label" id="Label2"&gt;Available Mailing Lists&lt;/label&gt; &lt;div class="controls"&gt; &lt;asp:CheckBoxList id="chklSubs" runat="server" RepeatLayout="UnorderedList" CssClass="checkbox unstyled"&gt;&lt;/asp:CheckBoxList&gt; &lt;/div&gt; &lt;/div&gt; </code></pre> <p>It's messing with my CSS and making the list break. Why would I be getting this span and how do I get rid of it?</p> <p>Side note I am styling with twitter bootstrap.</p> <p>full output</p> <pre><code>&lt;ul id="ContentPlaceHolderDefault_override_innerPageOverRide_BoilerplateMainContentPlaceHolder_ctl00_SignUpCtl_4_chklSubs" class="checkbox unstyled"&gt; &lt;li&gt;&lt;span alt="7"&gt;&lt;input id="ContentPlaceHolderDefault_override_innerPageOverRide_BoilerplateMainContentPlaceHolder_ctl00_SignUpCtl_4_chklSubs_0" type="checkbox" name="ctl00$ctl00$ctl00$ContentPlaceHolderDefault$override$innerPageOverRide$BoilerplateMainContentPlaceHolder$ctl00$SignUpCtl_4$chklSubs$0" value="7"&gt;&lt;label for="ContentPlaceHolderDefault_override_innerPageOverRide_BoilerplateMainContentPlaceHolder_ctl00_SignUpCtl_4_chklSubs_0"&gt;Energy Express Newsletter&lt;/label&gt;&lt;/span&gt;&lt;/li&gt; &lt;/ul&gt; </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload