1

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>

1 Answer 1

1

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.

2
  • I tried calling $('.spinner-mv').spinner(); after append. also added .fuelux on the main Div.....no luck Apr 24, 2015 at 4:18
  • $('#MySpinner').spinner({ value: 0, min: 0, max: 10, step: 0.1 }); -------- Solved thanks Apr 24, 2015 at 5:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.