>> How to "divide" that news in 2 columns, like this:


Again, if I understanding you right.... (not tested this code but it's
thereabouts)

<cfset noNews = news.recordCount />
<cfset halfNews = int(news.recordCount/2) />


<div id="news">
<cfoutput query="news">
    <cfif news.currentRow eq 1>
        <div id="news-left"
    </cfif>


    #news.item#<br />


    <!--- Output halfway news div's --->
    <cfif news.currentRow eq halfNews>
        </div>


        <div id="news-right">
    </cfif>


    <!--- Close off div if last record --->
    <cfif news.currentRow eq news.recordCount>
        </div>
    </cfif>
</cfoutput>
</div>


--
dc
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]

Reply via email to