Show full posts in "Archives"

pending (18 posts) (3 voices)

  1. rylandrussell
    Member

    Hello, I'd like to show the full posts for the archive of a certain category on this page http://www.cbcowasso.com/e-news/ and not have a "read more".

    I tried this adjusting things in the archive.php without luck. Any ideas?

    Posted 10 months ago #
  2. Elliott
    Support

    Hello rylandrussell,

    You are still using 1.3 correct? You should be able to use the more tag here, http://digwp.com/2010/01/wordpress-more-tag-tricks/.

    If that does not work for you then open up /wp-content/themes/archive.php and around lines 91 - 96 you should see this,

    if ($custom_use_more_quicktag) {
    	$more = 0;
    	the_content("Read More",false);
    }else{
    	the_excerpt(); ?><a class="fancy_link read_more_link" href="<?php the_permalink(); ?>">Read More</a>
    <?php } ?>

    You can change that to this,

    the_content(); ?>

    To display full post content.

    Posted 10 months ago #
  3. rylandrussell
    Member

    I replaced the 6 lines of code with the simple code you provided, doesn't seem to be working. Maybe I'm missing something...

    Posted 10 months ago #
  4. Elliott
    Support

    Try clearing your browser cache and refresh any caching related plugins you might have installed. I checked your single post and there was just a link inside as the content so perhaps you need to add some more content inside.

    Also make sure that the page is actually using the one category template.

    By the way, what is that "Location & Times" script in the top right hand corner? It's pretty cool.

    Posted 10 months ago #
  5. rylandrussell
    Member

    Well I added some text and it will show the text, but no matter how I format my link they won't show up unless you go to the actual post...

    The plugin I used for that is called "Sliding Panel"

    Posted 10 months ago #
  6. Elliott
    Support

    Try this,

    echo do_shortcode(get_the_content()); ?>

    Posted 10 months ago #
  7. rylandrussell
    Member

    Still not working.... here is a screen shot of my code adjustments. Hope I'm not missing something simple.

    <?php
    get_header();
    require(WEBTREATS_INCLUDES . "/var.php");

    if ($custom_use_more_quicktag) { global $more; }

    $exclude_blog_cats = preg_replace("!(\d)+!","-${0}$0", $blog_excludecats);
    query_posts($query_string . '&cat='.$exclude_blog_cats);
    ?>

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

    <div id="body_block" <?php webtreats_body_class(); ?>>

    <?php if($home_slider_page) { webtreats_header_slider_switcher($homepage_slider); } ?>

    <?php if($header_teaser != 'disable') : ?>
    <div id="intro_blurb">
    <div class="inner">
    <h1>Archives</h1>
    <div id="blurb">
    <?php if (!$header_disable) { ?>
    <?php $post = $posts[0]; // Hack. Set $post so that the_date() works. ?>
    <?php /* If this is a category archive */ if (is_category()) { ?>
    Category Archive for: ‘<?php single_cat_title(); ?>’
    <?php /* If this is a tag archive */ } elseif( is_tag() ) { ?>
    All Posts Tagged Tag: ‘<?php single_tag_title(); ?>’
    <?php /* If this is a daily archive */ } elseif (is_day()) { ?>
    Daily Archive for: ‘<?php the_time('F jS, Y'); ?>’
    <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
    Monthly Archive for: ‘<?php the_time('F, Y'); ?>’
    <?php /* If this is a yearly archive */ } elseif (is_year()) { ?>
    Yearly Archive for: ‘<?php the_time('Y'); ?>’
    <?php /* If this is an author archive */ } elseif (is_author()) {
    $curauth = get_userdata(intval($author)); ?>
    Author Archive for: ‘<?php echo $curauth->nickname; ?>’
    <?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { ?>
    Blog Archives
    <?php } ?>
    <?php } ?>
    </div>
    </div>
    </div><!-- intro_blurb -->
    <div class="clearboth"></div>
    <?php endif; ?>

    <div id="body_block_background">
    <div class="inner">

    <?php if (!$breadcrumb_disable){ if (class_exists('simple_breadcrumb')) { $bc = new simple_breadcrumb; }} ?>

    <div id="main">
    <div class="content">

    <?php if($header_teaser == 'disable') : ?>
    <h1>
    <?php $post = $posts[0]; // Hack. Set $post so that the_date() works. ?>
    <?php /* If this is a category archive */ if (is_category()) { ?>
    Category Archive for: ‘<?php single_cat_title(); ?>’
    <?php /* If this is a tag archive */ } elseif( is_tag() ) { ?>
    All Posts Tagged Tag: ‘<?php single_tag_title(); ?>’
    <?php /* If this is a daily archive */ } elseif (is_day()) { ?>
    Daily Archive for: ‘<?php the_time('F jS, Y'); ?>’
    <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
    Monthly Archive for: ‘<?php the_time('F, Y'); ?>’
    <?php /* If this is a yearly archive */ } elseif (is_year()) { ?>
    Yearly Archive for: ‘<?php the_time('Y'); ?>’
    <?php /* If this is an author archive */ } elseif (is_author()) {
    $curauth = get_userdata(intval($author)); ?>
    Author Archive for: ‘<?php echo $curauth->nickname; ?>’
    <?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { ?>
    Blog Archives
    <?php } ?>
    </h1>
    <?php endif; ?>

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

    <div <?php post_class() ?> id="post-<?php the_ID(); ?>">
    <div class="blog_module">

    <?php webtreats_post_image(); ?>

    <h2 class="blog_header">
    " rel="bookmark" title="Permanent Link: <?php the_title(); ?>"><?php the_title(); ?>
    <span class="comment_bubble"><?php comments_popup_link('0', '1', '%'); ?></span>
    </h2>

    <div class="entry">
    <?php
    echo do_shortcode(get_the_content()); ?>
    </div>

    <div class="blog_meta">
    <?php $get_year = get_the_time('Y'); $get_month = get_the_time('m'); ?>
    Posted on: "><?php the_time('m-j-Y') ?>
    Posted in: <?php the_category(', ') ?>
    </div>

    </div><!-- blog_module -->
    </div><!-- post -->

    <?php endwhile; endif; ?>

    <?php if(function_exists('wp_pagenavi')) { wp_pagenavi(); } ?>

    <?php get_sidebar(); ?>
    <?php get_footer(); ?>

    Posted 10 months ago #
  8. Ruderic
    Support

    Hello,

    I just visited your website, and it seems that you reverted the code to the original one. Could you please modify it again? So we can take a look at the problem.

    Posted 10 months ago #
  9. rylandrussell
    Member

    Tried the latest fix from above, still no luck.

    Posted 10 months ago #
  10. Elliott
    Support

    It's working okay on my end rylandrussell. Have you done any customizations or are you using any special templates? Perhaps your using a caching plugin?

    Posted 10 months ago #
  11. rylandrussell
    Member

    I'm using the "one category" template that I found in the forums. No caching here. When you say it's working okay when on your end do you mean my actual webpage that I provided shows the link without having to click "read more" correctly and that I may be seeing a cached version?

    Posted 10 months ago #
  12. Elliott
    Support

    Sorry, I got confused. If your using the "One Category" template then you'll find the areas to change on lines 71 - 77.

    Posted 10 months ago #
  13. rylandrussell
    Member

    So I replaced all code on lines 71-77
    -----------------------------
    <?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { ?>
    Blog Archives
    <?php } ?>
    </h1>
    <?php endif; ?>

    <?php while(have_posts()) : the_post(); ?>
    --------------------------------
    With the code as follows:

    echo do_shortcode(get_the_content()); ?>

    Didn't work. I feel like Im only supposed to be replacing part of that code, I'm sorry I'm such a php newb.

    Posted 10 months ago #
  14. Ruderic
    Support

    Hi,

    After line #77, you should find a line of code like this one:

    the_excerpt();

    Replace that single piece of code with this one:

    echo do_shortcode(get_the_content());

    Posted 10 months ago #
  15. rylandrussell
    Member

    So i gave up on showing full posts in archives. But my blog page called "news" doesn't show links either. I tried using the final template found here http://mysitemyway.com/support/topic/how-to-disable-read-more-link-on-blog-page but it broke up my page as seen here http://www.cbcowasso.com/news/

    It did however show the links. Any ideas why it broke everything up?

    Posted 9 months ago #
  16. Elliott
    Support

    That was a file for inFocus rylandrussell,

    Your just trying to get full posts instead of excerpts to display correct?

    Go ahead and revert all of the changes that have been done and let us know if that is a regular blog page or if you are using a template such as the "One Category".

    Posted 9 months ago #
  17. rylandrussell
    Member

    oh haha, sorry, that explains it! OK I reverted everything back to its original state. Original archive.php and orignial template blog file. I gave up on trying to use one category template. So the "news" page above is designated as the blog.

    So my questions are this:
    1. How can I show posts on the blog page that include links. Would love it if I could use the read more tag.
    2. Ditto above for "archive" pages using the category template.

    Posted 9 months ago #
  18. Elliott
    Support

    Are you wanting the link to appear in the excerpt? If so then you can craft a custom excerpt in each post. (see attached image)

    If you do not see the excerpt field then click on "Screen Options" in the top right hand corner and check it to display.

    Attachments

    1. 1.jpg (22 KB, 0 downloads) 9 months old
    Posted 9 months ago #

Reply

You must log in to post.

Construct WordPress Theme
Construct wordpress theme
Myriad WordPress Theme
Myriad wordpress theme
Method WordPress Theme
Method wordpress theme
Fusion WordPress Theme
Fusion wordpress theme
Elegance WordPress Theme
Elegance wordpress theme
Echelon WordPress Theme
Echelon wordpress theme
Dejavu WordPress Theme
Dejavu wordpress theme
Modular WordPress Theme
Modular wordpress theme