• Hello!

    I am having difficulties with the Tanaku theme. I would like to limit the amount of text on the posts displayed on the home page. I have tried the various ways I have read about such as adding a plug in, asking to add ” excerpt” instead of “content” in the php file and using the ‘more’ tag but nothing works so far. I did manage to make the post shorter by writing “excerpt” in the php file but then I don’t get the image either. Does anyone know how to resolve this please? I would be very grateful for some help if anyone knows. Many thanks in advance.

    The code in the php file is as per below. I have replaced ‘get the content’ with ‘get the excerpt’ but then I get some text in Japanese and the image disappears. I would still like the image to appear on the home page:

    <?php if (have_posts()) :
    if ( $is_top_single ) $GLOBALS [‘more’] = false; //important
    while (have_posts()) : the_post(); ?>

    <?php
    $content = get_the_content(‘Details »’);
    $content = apply_filters(‘the_content’, $content);
    list($col_class, $grid_img) = adjust_grid_image(
    $content,
    $col_w,
    $gap_w,
    $max_col,
    $flg_img_forcelink,
    $flg_obj_fit

Viewing 4 replies - 1 through 4 (of 4 total)
  • hi!

    for all with the same problem, add this to the end of your function.php before the ?>

    ————
    function remove_more_link($link) { $offset = strpos($content, ‘#more-‘);
    if ($offset) { $end = strpos($content, ‘”‘,$offset); }
    if ($end) { $link = substr_replace($content, ”, $offset, $end-$offset); } return $content; }
    add_filter(‘the_content_more_link’, ‘remove_more_link’);
    ————

    this will remove the more link on posts

    hmmm Thanks Pongs. Tried that, but no luck.

    I wonder if this theme is not allowing the “summary” option in the Settings/Reading to work at all. I have:

    For each article in a feed, show: Summary

    But it looks like it is always displaying the full post independently

    Alwyn Botha

    (@123milliseconds)

    Please mark thread as resolved so that

    – others with similar problem can see it as resolved and will read this thread for help if they have similar problem

    – people providing help see it as resolved and will not waste time reading this post.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Tanzaku theme difficulties with excerpts’ is closed to new replies.