ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

<div id="fragment-2"> how to loop?

July 04, 2011 12:57pm

Subscribe [2]
  • #1 / Jul 04, 2011 12:57pm

    brebre

    75 posts

    Hi there all,

    I have some javascript that requires a list id to increase..

    ie:

    <div id=“fragment-2”> where 2 will auto increase with the channel loop.

    Currently I am manually making the different divs and then offsetting each entry which works BUT is not a great way to do this as ‘sticky’ entries floats won’t float to the top.

    any thoughts?
    Lance

  • #2 / Jul 04, 2011 2:11pm

    Rob Allen

    3105 posts

    If you need sequential numbering try this:

    <div id="fragment-{count}">
.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases