SitePoint Sponsor |
|
User Tag List
Results 1 to 15 of 15
Thread: Hep me with my wordpress blog
-
Nov 25, 2007, 11:26 #1
- Join Date
- Oct 2007
- Posts
- 75
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Hep me with my wordpress blog
The archived and categories I think not working correctly. When I click on the month of November, it shows only posts in full message. Also when I click on categories.
I want summary of post, but I don't understand why this happens.
Please help.
Thanks
-
Nov 25, 2007, 11:33 #2
- Join Date
- May 2005
- Location
- Singapore
- Posts
- 1,261
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Can you give a link to your blog? It would depend on what type of theme you are using.
In order for the summary to show, have you typed something in the 'excerpt' box? or put a <!--more--> tag in your post?Winners Respond. Losers React.
Singapore Web Designer
-
Nov 25, 2007, 18:02 #3
- Join Date
- Oct 2007
- Posts
- 75
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
It's in my sig. http://www.myseoblog.net
thanks
-
Nov 25, 2007, 18:03 #4
- Join Date
- Nov 2007
- Posts
- 1
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Nice
-
Nov 25, 2007, 18:28 #5
Hello
You'll need to open archive.php located in your active themes folder and change the line that has the_content to the_excerpt.Code PHP:<?php the_content(); ?> <?php the_excerpt(); ?>
-
Nov 25, 2007, 21:44 #6
- Join Date
- Jun 2001
- Location
- Toronto, Canada
- Posts
- 9,123
- Mentioned
- 2 Post(s)
- Tagged
- 0 Thread(s)
Just as a note, if there is no excerpt, WP will automagically excerpt for you.
-
Nov 26, 2007, 00:26 #7
- Join Date
- Oct 2007
- Posts
- 75
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Thanks a lot.. I will do this later..
-
Nov 29, 2007, 04:39 #8
- Join Date
- Oct 2007
- Posts
- 75
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Hello John, here is the code of my archive.php. Please tell me what do I need to change here or where to insert the given codes.
Code:<?php /* Template Name: Archives */ ?> <?php get_header(); ?> <div id="content"><div class="cont-border-white"><div class="cont-border-grey"> <div id="main"> <div class="content"> <div class="post"> <div class="entry"> <h2>Archives by Month:</h2> <ul> <?php wp_get_archives('type=monthly'); ?> </ul> <h2>Archives by Subject:</h2> <ul> <?php wp_list_categories(); ?> </ul> </div> </div> </div> </div> <?php get_sidebar(); ?> <div class="clear"></div> </div></div></div> <?php get_footer(); ?>
Thank's a lot..
-
Nov 29, 2007, 11:07 #9
Hello
That is archive(s).php you need to edit archive.php no s. Then simply replace the line that says:Code PHP:<?php the_content(); ?>
Code PHP:<?php the_excerpt(); ?>
-
Nov 29, 2007, 19:24 #10
- Join Date
- Oct 2007
- Posts
- 75
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Here is my code for archive.php
Code:<?php get_header(); ?> <div id="content"><div class="cont-border-white"><div class="cont-border-grey"> <div id="main"> <div class="content"> <?php if (have_posts()) : ?> <?php $post = $posts[0]; /* Hack. Set $post so that the_date() works.*/ ?> <?php /* If this is a category archive */ if (is_category()) { ?> <h2 class="pagetitle">Archive for the "<strong><?php single_cat_title(); ?></strong>" Category</h2> <?php /* If this is a daily archive */ } elseif (is_day()) { ?> <h2 class="pagetitle">Archive for <?php the_time('F jS, Y'); ?></h2> <?php /* If this is a monthly archive */ } elseif (is_month()) { ?> <h2 class="pagetitle">Archive for <?php the_time('F, Y'); ?></h2> <?php /* If this is a yearly archive */ } elseif (is_year()) { ?> <h2 class="pagetitle">Archive for <?php the_time('Y'); ?></h2> <?php /* If this is an author archive */ } elseif (is_author()) { ?> <h2 class="pagetitle">Author Archive</h2> <?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { ?> <h2 class="pagetitle">Blog Archives</h2> <?php } ?> <?php while (have_posts()) : the_post(); ?> <div class="post" id="post-<?php the_ID(); ?>"> <div class="date"><?php the_time('j') ?><br /><?php the_time('M') ?></div> <div class="title"><div class="bord-l"><div class="bord-r"><div class="tit-rb"><div class="tit-lb"><div class="tit-rt"><div class="tit-lt"> <h1><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></a></h1> <p class="author">Author: <?php the_author() ?> <?php edit_post_link('Edit', ' | ', ' | '); ?></p> </div></div></div></div></div></div></div> <div class="entry"> <?php the_content('Read the rest of this entry »'); ?> </div> <div class="postmetadata">Filed Under » <?php the_category(', ') ?> | <span><?php comments_popup_link('No Comments »', '1 Comment »', '% Comments »'); ?></span></div> </div> <?php endwhile; ?> <div class="Nav"><?php if(function_exists('wp_pagenavi')) { wp_pagenavi(); } ?></div> <?php else : ?> <h2><?php _e('Not Found'); ?></h2> <p><?php _e('Sorry, no posts matched your criteria.'); ?></p> <?php endif; ?> </div> </div> <?php get_sidebar(); ?> <div class="clear"></div> </div></div></div> <?php get_footer(); ?>
-
Nov 29, 2007, 19:33 #11
Hello
Here you go.Code PHP:<?php get_header(); ?> <div id="content"><div class="cont-border-white"><div class="cont-border-grey"> <div id="main"> <div class="content"> <?php if (have_posts()) : ?> <?php $post = $posts[0]; /* Hack. Set $post so that the_date() works.*/ ?> <?php /* If this is a category archive */ if (is_category()) { ?> <h2 class="pagetitle">Archive for the "<strong><?php single_cat_title(); ?></strong>" Category</h2> <?php /* If this is a daily archive */ } elseif (is_day()) { ?> <h2 class="pagetitle">Archive for <?php the_time('F jS, Y'); ?></h2> <?php /* If this is a monthly archive */ } elseif (is_month()) { ?> <h2 class="pagetitle">Archive for <?php the_time('F, Y'); ?></h2> <?php /* If this is a yearly archive */ } elseif (is_year()) { ?> <h2 class="pagetitle">Archive for <?php the_time('Y'); ?></h2> <?php /* If this is an author archive */ } elseif (is_author()) { ?> <h2 class="pagetitle">Author Archive</h2> <?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { ?> <h2 class="pagetitle">Blog Archives</h2> <?php } ?> <?php while (have_posts()) : the_post(); ?> <div class="post" id="post-<?php the_ID(); ?>"> <div class="date"><?php the_time('j') ?><br /><?php the_time('M') ?></div> <div class="title"><div class="bord-l"><div class="bord-r"><div class="tit-rb"><div class="tit-lb"><div class="tit-rt"><div class="tit-lt"> <h1><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></a></h1> <p class="author">Author: <?php the_author() ?> <?php edit_post_link('Edit', ' | ', ' | '); ?></p> </div></div></div></div></div></div></div> <div class="entry"> <?php the_excerpt(); ?> </div> <div class="postmetadata">Filed Under » <?php the_category(', ') ?> | <span><?php comments_popup_link('No Comments »', '1 Comment »', '% Comments »'); ?></span></div> </div> <?php endwhile; ?> <div class="Nav"><?php if(function_exists('wp_pagenavi')) { wp_pagenavi(); } ?></div> <?php else : ?> <h2><?php _e('Not Found'); ?></h2> <p><?php _e('Sorry, no posts matched your criteria.'); ?></p> <?php endif; ?> </div> </div> <?php get_sidebar(); ?> <div class="clear"></div> </div></div></div> <?php get_footer(); ?>
-
Nov 29, 2007, 20:03 #12
- Join Date
- Oct 2007
- Posts
- 75
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Oh, it still shows 2 posts like before..just posts are shortened..
http://www.myseoblog.net/2007/11/
Doesn't even have the links for "continue reading" the posts..... seems something is wrong with the script?
Thanks anyway
-
Nov 30, 2007, 01:34 #13
- Join Date
- Oct 2006
- Location
- New Zealand
- Posts
- 2,323
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
-
Nov 30, 2007, 01:40 #14
- Join Date
- Oct 2006
- Location
- New Zealand
- Posts
- 2,323
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
This ought to fix it. Although it will now appear as bla bla bla [...] continue reading rather than bla bla bla ... continue reading. I can't remember how to get rid of those []'s, but if you do some searching for how to format the_excerpt you should be able to find a fix for that. I have a sneaking suspicion that the_excerpt(' ... ') may do the trick, but I'm not 100% certain and haven't tested it.
Code:<?php get_header(); ?> <div id="content"><div class="cont-border-white"><div class="cont-border-grey"> <div id="main"> <div class="content"> <?php if (have_posts()) : ?> <?php $post = $posts[0]; /* Hack. Set $post so that the_date() works.*/ ?> <?php /* If this is a category archive */ if (is_category()) { ?> <h2 class="pagetitle">Archive for the "<strong><?php single_cat_title(); ?></strong>" Category</h2> <?php /* If this is a daily archive */ } elseif (is_day()) { ?> <h2 class="pagetitle">Archive for <?php the_time('F jS, Y'); ?></h2> <?php /* If this is a monthly archive */ } elseif (is_month()) { ?> <h2 class="pagetitle">Archive for <?php the_time('F, Y'); ?></h2> <?php /* If this is a yearly archive */ } elseif (is_year()) { ?> <h2 class="pagetitle">Archive for <?php the_time('Y'); ?></h2> <?php /* If this is an author archive */ } elseif (is_author()) { ?> <h2 class="pagetitle">Author Archive</h2> <?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { ?> <h2 class="pagetitle">Blog Archives</h2> <?php } ?> <?php while (have_posts()) : the_post(); ?> <div class="post" id="post-<?php the_ID(); ?>"> <div class="date"><?php the_time('j') ?><br /><?php the_time('M') ?></div> <div class="title"><div class="bord-l"><div class="bord-r"><div class="tit-rb"><div class="tit-lb"><div class="tit-rt"><div class="tit-lt"> <h1><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></a></h1> <p class="author">Author: <?php the_author() ?> <?php edit_post_link('Edit', ' | ', ' | '); ?></p> </div></div></div></div></div></div></div> <div class="entry"> <?php the_excerpt(); ?> <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>">continue reading</a> </div> <div class="postmetadata">Filed Under » <?php the_category(', ') ?> | <span><?php comments_popup_link('No Comments »', '1 Comment »', '% Comments »'); ?></span></div> </div> <?php endwhile; ?> <div class="Nav"><?php if(function_exists('wp_pagenavi')) { wp_pagenavi(); } ?></div> <?php else : ?> <h2><?php _e('Not Found'); ?></h2> <p><?php _e('Sorry, no posts matched your criteria.'); ?></p> <?php endif; ?> </div> </div> <?php get_sidebar(); ?> <div class="clear"></div> </div></div></div> <?php get_footer(); ?>
-
Nov 30, 2007, 06:23 #15
- Join Date
- Oct 2007
- Posts
- 75
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Thank you.. I will try this later when return..
Bookmarks