Sidebar placement
-
Hi everyone,
I am a graphic designer. I am trying to set up my blog and failing to make the sidebar sit next to the post image.
Like this: http://amey-gokarn.com/trial/amey-gokarn-screenshot.jpg
This is my actual site: http://www.amey-gokarn.com/test/
I am quite sure that there is some problem with DIVs, I am sitting on code for 2 weekends but i m too dumb for it. So here is the code:<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head profile="http://gmpg.org/xfn/11"> <title> <?php bloginfo('name'); ?> <?php wp_title(); ?> </title> <meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" /> <meta name="generator" content="WordPress <?php bloginfo('version'); ?>" /> <!-- leave this for stats please --> <link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" media="screen" /> <link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="<?php bloginfo('rss2_url'); ?>" /> <link rel="alternate" type="text/xml" title="RSS .92" href="<?php bloginfo('rss_url'); ?>" /> <link rel="alternate" type="application/atom+xml" title="Atom 0.3" href="<?php bloginfo('atom_url'); ?>" /> <link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" /> <?php wp_get_archives('type=monthly&format=link'); ?> <?php //comments_popup_script(); // off by default ?> <?php wp_head(); ?> </head> <body> <!--wrapper start--> <div id="wrapper"> <?php get_header(); ?> <!--container start--> <div id="container"> <?php if(have_posts()) : ?> <?php while(have_posts()) : the_post(); ?> <!--post start--> <div class="post"> <h1><a href="<?php the_permalink(); ?>"> <?php the_title(); ?> </a></h1> <?php _e('Filed under:'); ?> <?php the_category(', ') ?> <?php _e('by'); ?> <?php the_author(); ?> <!--entry start--> <div class="entry"> <?php the_content(); ?> <p class="postmetadata"> <?php comments_popup_link('No Comments »', '1 Comment »', '% Comments »'); ?> <?php edit_post_link('Edit', ' | ', ''); ?> </p> </div> <!--entry end--> <!--comments start--> <div class=”comments-template”> <?php comments_template(); ?> </div> <!--comments end--> <?php endwhile; ?> <!--next page start--> <div class="navigation"> <?php posts_nav_link(); ?> </div> <!--next page end--> <?php else : ?> <!--not found start--> <div class="not" id="not-<?php the_ID(); ?>"> <h2> <?php _e('Not Found'); ?> </h2> </div> <!--not found end--> </div> <!--post end--> <?php endif; ?> </div> <!--container end--> <!--sidebar start--> <div class="sidebar"> <?php get_sidebar(); ?> </div> <!--sidebar end--> <!--footer start--> <div id="footer"> Copyright © 2009 <a href="<?php bloginfo('url'); ?>"> <?php bloginfo('name'); ?> </a> </div> <!--footer end--> </div> <!--wrapper end--> </body> </html>The weird part is its showing kind of right on the not found page.
http://www.amey-gokarn.com/test/asd
But its not quite right, I want it to be aligned with the image of the post, which always will be 380 X 380 pixels.Any kind of help is appreciated.
I am also open to comments on design 🙂Thanx
-
Try making sure in the CSS that you put something like this:
.post { float:left; } .sidebar { float:left; }That might help.
I did, sorry for not posting my CSS.
Both post and sidebar are floated left.even the ‘read more’ thing doesn’t work, it makes the half post disappear on the front page but when u click Read More or click on post title and see the post page, the remaining text is missing.
Maybe I am not destined to have my own designed theme 🙁
Do a search on your CSS and see if there’s anything that says:
clear:leftor
clear:bothIf there is take them out.
The topic ‘Sidebar placement’ is closed to new replies.