If I have a list being generated in a loop, something like:
<?php if ( have_posts() ) while ( have_posts() ) : the_post(); ?>
<div id="slide">
<ul>
<li class="slide-<?php //how can I generate an integer here ?>">
<a href="#">stuff</a></li>
</ul>
</div>
How could I append a sequential number to each of those classes, and/or those hrefs?
so in that example slide-1,slide-2, etc..
I’m considering that you will put some slides in the same page. So I would put all HTML code in the PHP code. Something like that:
I didn’t check the code, but it’s just an idea.
Good luck.