intothewhite
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: wp not outputing whole of templateIt seems that calling the template file
about.php
and the pageAbout
causes a problem. Renamed the file (rather than the template) and everything's fine.Forum: Fixing WordPress
In reply to: wp not outputing whole of templateI've figured out the problem (although it's not solved).
For some reason, the page uses
page.php
as its template, notabout.php
. In wp-admin the page has been told to use About as its template (Manage - Page - Advanced - Page Template - About
).I’m guessing this is a problem with the database?
Forum: Fixing WordPress
In reply to: wp not outputing whole of templateThanks for replying.
You’ve found an unrelated problem: I hadn’t got rid of the reference to the stylesheet I was using when it was a static, mockup page. I’ve done that, but the problem persists — unsurprising, as a missing stylesheet wouldn’t cause bits of the page to be displayed and others not.
It’s a bit of an odd problem.
— Leon
`
Forum: Fixing WordPress
In reply to: Making wp realise it’s a page, not a postBecause I want the page to query the database – I write posts that detail work that has been done with clients (and these posts are tagged ‘client’). The page pulls all posts tagged ‘client’ from the database, and displays a link, the title and the excerpt.
Thanks,
Leon
Forum: Fixing WordPress
In reply to: Trying a static pageThis is the
index.php
code:<?php query_posts('category_name=front') ?> <?php while (have_posts()) : the_post(); ?> <div id="banner"> <h2><?php the_excerpt(); ?> </div> <div id="content"> <h3><?php the_title(); ?></h3> <?php the_content(); ?> </div> <?php endwhile; ?>
Works just fine, but when I call sidebar.php:
<?php <?php if (is_home()) { echo "<h2>Find out how we help companies</h2>"; echo "<ul class=\"linklist\">"; wp_get_archives('type=postbypost'); echo ""; echo "<h2>Latest thinking from the blog</h2>"; echo "<h3>How to do only that which you can do</h3>"; echo "<p>Blog excerpt. <a>Visit our blog</a>.</p>"; } elseif (is_page('About')) { echo "<h2>Contact us</h2>"; echo "<p>123 West St.SomewhereSomewhereTel: +1 111 123 4567email: [email protected]</p>"; echo "<h2>What our clients say</h2>"; echo "<ul class=\"quotelist\">"; wp_list_bookmarks('title_li=&categorize=0&category_name=quote&limit=1&show_description=1'); echo ""; } else { echo "<h2>What our clients say</h2>"; echo "<ul class=\"quotelist\">"; wp_list_bookmarks('title_li=&categorize=0&category_name=quote&show_description=1'); echo ""; } ?>
No sidebar content is displayed, apart from the final
else
block (which means that the code doesn’t recognise the current page). I’m wondering whether my syntax is correct here (I’m new to PHP).Forum: Fixing WordPress
In reply to: Trying a static pageWhat happens if you don’t use the Front template for the Home page?
I tried another tack. I decided to use a normal front page that used
index.php
. Inindex.php
I usedquery_posts
to pull up any posts categorised as ‘front’ (I know it seems long winded, but it gives quite a bit of flexibility).Anyway, that’s fine, but now my sidebar conditional statements don’t work, i.e.
if (is_home())
doesn’t pick up the home page.Does
query_posts
somehow affect this?Thanks,
Leon
Forum: Themes and Templates
In reply to: Problems with blog_info(‘url’)Oops – spotted about 20 seconds after posting here.
Square eyes as been working on this all day.
Need a break!
Thanks for looking at it anyway!
Leon
Forum: Themes and Templates
In reply to: Header photo wants to center. I want it left. Help?You’re using a background image, so you need to look at your CSS file (forget about the tables). It’s called
style.css
and you can find it athttps://blog.littlebluedog.org/wp-content/themes/silver-light-01/style.css
. Change line 18 from:#header {background: #ffffff url('images/telly_bloghdr.jpg') no-repeat bottom center;}
to
#header {background: #ffffff url('images/telly_bloghdr.jpg') no-repeat bottom left;}
And change line 23 from:
#header p.desc{font-family:Verdana, Arial, Helvetica, sans-serif;font-size:11px;margin:0;padding:0;}
to
#header p.desc{font-family:Verdana, Arial, Helvetica, sans-serif;font-size:11px;margin:0;padding:0; margin-left: 220px;}
Forum: Themes and Templates
In reply to: Side bar keeps going to bottom of pageYes, it will affect the overall look. Another alternative would be to remove the calendar; everything else *should* wrap into the sidebar container.
Look for references to
#sidebar
,#content
and#page
in yourstyle.css
file and play around with the sizes, widths, colours etc. (saving before you make any changes!) The CSS is pretty simple and decently commented. Bear in mind that the#page width
will set the width of the whole page – I wouldn’t go above 960px as you’d be excluding the most common monitor resolution.Forum: Themes and Templates
In reply to: Side bar keeps going to bottom of pageIt looks like your sidebar content is too wide for the sidebar container, so it can’t float next to the content. Your content is set to 500px wide while the page is 754px, which means you have 254px for the sidebar.
One solution would be to increase the width of the page. The problem with this would be that you’d make users on an 800X600 monitor scroll horizontally in order to see all your content. If you’re OK with that it’s quite simple. Change line 236 of your
style.css
file from:width: 754px;
to
width: 940px;
This will give you a sidebar 440px wide, which should be sufficient.
Forum: Themes and Templates
In reply to: Posts always show the most recent commentI’ve looked into this some more and found that the problem is related to how I tag posts.
If I tag a post with ‘lead’ it is displayed on the blog’s front page. I put this before the loop in
index.php
:<?php if (have_posts()) : ?> <?php query_posts("tag=lead&showposts=1"); ?> <?php while (have_posts()) : the_post(); ?>
It appears that only comments made on the lead post will appear on any post’s single page. I can’t for the life of me figure out why this is the case.
I’m not sure if it’s related, but I also use
<? php query_posts(); ?>
within the loop in mysingle.php
file. Is it OK to use it within the loop?TIA,
Leon