Reputation: 2177
I am using fuelux spinner, it applies spinner when page loads but fails to apply spinners when I append HTML code containing spinner div's . CSS is also getting disturbed
<!-- Loaded spinner having button + and - to input box STARTS -->
<div class="shape-sp">
<div class="spinner-my">
<div class="input-group">
<input type="text" maxlength="1" class="spinner-input form-control">
<div class="spinner-buttons input-group-btn btn-group-vertical">
<button class="btn spinner-up btn-xs default" type="button">
<i class="fa fa-angle-up"></i>
</button>
<button class="btn spinner-down btn-xs default" type="button">
<i class="fa fa-angle-down"></i>
</button>
</div>
</div>
</div>
</div>
HTMLCODE = /* It contains HTML code that will get appended to MYDIV */;
$("#mydiv").append(HTMLCODE);
<div id="mydiv"> </div>
Upvotes: 1
Views: 503
Reputation: 780
You will need to call $('spinner-my').spinner();
on the element after you append. And you will need to use the .spinner class for CSS with .fuelux class at the top of the page/ as a parent.
Upvotes: 1