Skip to content

Instantly share code, notes, and snippets.

} elseif ($count%3 == 0){
/*If third column*/
/* if this is the bottom post, close the div and start a new div: */
echo '</div>
} elseif ($count%6 == 0){
echo '<div>
} elseif ($count%2 == 0){
/* if this is the bottom post, close the div and start a new div: */
echo '<div>';
<?php
//
// Custom Child Theme Functions
//
// I've included a "commented out" sample function below that'll add a home link to your menu
// More ideas can be found on "A Guide To Customizing The Thematic Theme Framework"
// http://themeshaper.com/thematic-for-wordpress/guide-customizing-thematic-theme-framework/
<?php
function childtheme_index_loop(){
?>
<div id='column1'>
<?php
global $paged, $more;
$more = 0;
// Second, create a new temporary Variable for your query.
// $creative_query is the Variable used in this example query.
<?php
/* In the case you're rendering the very last post, do nothing: */
if ($count == 4){
// Do nothing, thematic will add a '</div>' to close the last post
/* Is this the last post in the column?
That means if the loop number divides by 2 (or whatever post per column number we choose) */
} elseif ($count%2 == 0){
/* if this is the bottom post, close the div and start a new div: */
echo '</div>
<?php
function childtheme_index_loop(){
?>
<div id='column1'>
<?php
global $paged, $more;
$more = 0;
// Second, create a new temporary Variable for your query.
// $creative_query is the Variable used in this example query.
<?php
//
// Custom Child Theme Functions
//
// I've included a "commented out" sample function below that'll add a home link to your menu
// More ideas can be found on "A Guide To Customizing The Thematic Theme Framework"
// http://themeshaper.com/thematic-for-wordpress/guide-customizing-thematic-theme-framework/
<?php
//
// Custom Child Theme Functions
//
// I've included a "commented out" sample function below that'll add a home link to your menu
// More ideas can be found on "A Guide To Customizing The Thematic Theme Framework"
// http://themeshaper.com/thematic-for-wordpress/guide-customizing-thematic-theme-framework/
<?php
/*
Template Name: portfolio page
*/
get_header();
?>
<div id="container">
<div id="content">