Zikula: A Flexible Open Source Content Management System
home | forum | contact us

Dizkus

Bottom
split output into 2 columns?
  • Posted: 18.11.2005, 05:23
     
    pnfreak
    rank:
    Freshman Freshman
    registered:
     June 2005
    Status:
    offline
    last visit:
    18.11.05
    Posts:
    10
    This is more of a PHP question than PN, but it relates to what I'm working on for PN.

    I have a variable {VIDEO_COUNT} that basically means the total number of video's in the database. If I insert just that into my theme, it will give me the total number of video's.

    Now what I'm trying to do is split the output into two columns instead of just one. The same thing as having dual news columns concept.

    I think I'm on the right track but need some help.
    Here is the 'snippet' of code I'm trying to use to accomplish this

    Code

    <?php
      if (({VIDEO_COUNT} % 2) == 0)
      {
           echo '</tr><tr>';
      }
    ?>


    My thought was it would take the 'video count' divide it by 2 and output to 2 sep columns, but it's not working right.
    Does anyone have any ideas what I might use instead?

Extensions Moderation

Main Menu

Extensions Database

Documentation

Development

Login

Donate to Zikula