Support » Fixing WordPress » Is Kubrick the best theme to do this with?

  • hippievstony.com

    I am dividing the content area into two divs (left and right) which will display posts based on their category. I tried altering the main index of the kubrick theme and adding some to the style.css file. As far as I can tell nothing has changed, I can’t tell if it is creating the divs but not displaying them correctly or what. Do I need to change more than index.php and style.css? Does it matter where I put the left and right divs in the style file? Thanks a lot

    Here is the css I added:

    #left,#right {
    width:50%;
    float:left;
    }

    Here is my index:

    <?php
    /**
    * @package WordPress
    * @subpackage Default_Theme
    */

    get_header(); ?>

    <div id=”content” class=”narrowcolumn” role=”main”>

    <?php if (have_posts()) : ?>

    <?php while (have_posts()) : the_post(); ?>

    <div <?php post_class() ?> id=”post-<?php the_ID(); ?>”>
    <h2>” rel=”bookmark” title=”Permanent Link to <?php the_title_attribute(); ?>”><?php the_title(); ?></h2>
    <small><?php the_time(‘F jS, Y’) ?> <!– by <?php the_author() ?> –></small>

    <div class=”entry”>
    <?php the_content(‘Read the rest of this entry »’); ?>
    </div>

    <p class=”postmetadata”><?php the_tags(‘Tags: ‘, ‘, ‘, ‘
    ‘); ?> Posted in <?php the_category(‘, ‘) ?> | <?php edit_post_link(‘Edit’, ”, ‘ | ‘); ?> <?php comments_popup_link(‘No Comments »’, ‘1 Comment »’, ‘% Comments »’); ?></p>
    </div>

    ///////////////////////////////////////////////////////////////
    ////////////////////////////////insertion start//////////////
    ///////////////////////////////////////////////////////////

    <div id=”left”>
    <?php $my_query = new WP_Query(‘category_name=tony&showposts=3’);
    while ($my_query->have_posts()) : $my_query->the_post();
    $do_not_duplicate = $post->ID;?>
    <?php endwhile; ?>
    </div>

    <div id=”right”>
    <?php $my_query = new WP_Query(‘category_name=hippie&showposts=3’);
    while ($my_query->have_posts()) : $my_query->the_post();
    $do_not_duplicate = $post->ID;?>
    <?php endwhile; ?>
    </div>

    //////////////////////////////////////////////////////////////
    ////////////////////////////////insertion end//////////////
    ///////////////////////////////////////////////////////

    <?php endwhile; ?>

    <div class=”navigation”>
    <div class=”alignleft”><?php next_posts_link(‘« Older Entries’) ?></div>
    <div class=”alignright”><?php previous_posts_link(‘Newer Entries »’) ?></div>
    </div>

    <?php else : ?>

    <h2 class=”center”>Not Found</h2>
    <p class=”center”>Sorry, but you are looking for something that isn’t here.</p>
    <?php get_search_form(); ?>
    <?php endif; ?>

    </div>

    <?php get_sidebar(); ?>

    <?php get_footer(); ?>

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Is Kubrick the best theme to do this with?’ is closed to new replies.