This is the code from my main.template.php:
<div class="', ($var % 2 == 0 ? 'index_left':'index_right') ,'">
<div class="content_box">
<h2>', $category['title'] ,'</h2>';
foreach ($main['files'][$category['id']] as $file) {
echo '
<div class="file file_index">
<div class="icon">
<a href="', $file['url'] ,'"><img src="', $file['image'] ,'" width="', $settings['image_width'] ,'" height="', $settings['image_height'] ,'" alt="', $file['title'] ,'" /></a>
</div>
<div class="desc">
<p class="link"><a href="', $file['url'] ,'">', $file['title'] ,'</a></p>';
if ($settings['stars_index'] == 1) {
echo '
<p><img src="', $settings['siteurl'] ,'/images/stars', $file['stars'] ,'.gif" width="67" height="15" title="', $file['rating'] ,'" alt="', $file['rating'] ,'" /></p>';
} // if
echo '
<p>', $file['description'] ,'</p>
<p class="played">(', $lang['played_times'] ,': ', $file['played'] ,')</p>
</div>
</div>';
} // foreach
echo '
<div class="txt_right">
<a href="', $category['url'] ,'">', $lang['more_in_category'] ,' ', $category['title'] ,' ></a>
</div>
</div>
</div>';
if ($var % 2 == 1) {
echo '
<div class="clear"></div>';
} // if
} // foreach
echo '
</div>';
} // end function
This is the code from the CSS file:
/* index page 2 columns */
.index_left {
float: left;
width: 407px;
}
.index_right {
float: right;
width: 407px;
}
Now the page has 2 columns, and I want it with 3 columns. How can I do that? Any help is welcome.