Hi,
i have the following unordered list:
<ul id="#lastcompanieslist">
<li style="display: none;" page="0">whatever 1</li>
<li style="display: none;" page="0">whatever 2</li>
<li style="display: none;" page="0">whatever 2</li>
<li style="display: none;" page="0">whatever 3</li>
<li style="display: none;" page="0">whatever 4</li>
<li style="display: none;" page="1">whatever 5</li>
<li style="display: none;" page="1">whatever 6</li>
<li style="display: none;" page="1">whatever 7</li>
<li style="display: none;" page="1">whatever 8</li>
</ul>
<p class="NextPrevious">
<img src="/Images/PreviousItem.jpg" id="previousbutton" />
<img src="/Images/NextItem.jpg" id="nextbutton" />
</p>
I have a counter "actualpage is the variable name" with the current page for other hand.
With Jquery im trying to fadeout and fadein li elements when the user clicks this two buttons and depending of the counter of actual page.
The lines that im using for fadeout and fadein are the following:
$('#lastcompanieslist li[page!=' + actualpage.toString() + ']').fadeOut(500);
$('#lastcompanieslist li[page=' + actualpage.toString() + ']').fadeIn(500);
The effect is working, but im having a flickering effect, the items starts to fadeout, but for a moment the list is bigger in height space. When the fadein is complete, the list returns to the original height size.
What could be the problem, or how could i solve it?
Thanks in advance. Kind Regards. Josema.