0
  • 0
  • 0

    Making changes to the number of changes

    I have a counter like this:

    <ul>
        <li id="cenMill">0</li>
        <li id="decMill">0</li>
        <li id="uniMill">0</li>
        <li id="cen">3</li>
        <li id="dec">2</li>
        <li id="uni">1</li>
    </ul>
    
    •  0 0 0 3 2 1

    I intend to change each number in accordance with the variable that I give it, that is, if I add +1, then just change id = "uni" from 1 to 2, but if I give 12, then change both that are affected and etc. However, I do not know how to start doing this so far, this is what I have:

    $('#uni').animate({
        marginTop: "-25px",
    },200);
    

    But this only puts 1 at the top, it does not make the “2” pop-up box from under the next number, but 1 is visible, and I can’t hide it even when displaying “no” or others like it. Any help (or ideas) regarding how to do this?

    +5
    source share

    All Articles