Blog with Renew Stack

Hello @smart_x,

I am really sorry for the confusion. Looks like I pasted the current ticket URL in the reply.

Here’s the solution that you can take a look:

Thanks.

Hello X Team,

http://demo.theme.co/integrity-1/blog/


I added the code to my functions.php file but this didn’t change anything.

When it does work, is it also possible to determine after how many rules of text the Read more will show?
I would like to show the Read More direct after the title.

Please advise.
Than you

Hello @smart_x,

Please do this as well:

  • Copy content.php from /wp-content/themes/pro/framework/views/renew/ to child theme under /wp-content/themes/pro-child/framework/views/renew/. You will have to create necessary child folders. And then replace the code with following:
<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
  <div class="entry-wrap">
  <?php if ( has_post_thumbnail() ) : ?>
      <div class="entry-featured mbm">
        <?php x_featured_image(); ?>
      </div>
    <?php endif; ?>
    <?php x_get_view( 'renew', '_content', 'post-header' ); ?>
    
    <?php x_get_view( 'global', '_content' ); ?>
  </div>
</article>

This will swap the image, title and the read more format.

Hope this helps. Please let us know how it goes.

Hi X Team,

You write:

Blockquote
You will have to create necessary child folders. And then replace the code with following:

Can you explain which, where and how I have to create the necessary child folders?
I assume I can make the folders within my FTP (FileZilla)?

Hi @smart_x,

Yes, you can make folder using FTP.
By default, the child theme folders have the following: /pro-child/framework/views. Please navigate on your wordpress installation then go to your pro child theme folder. Inside pro-child theme folder there is frameworks folder and inside this framework you can see views folder. Now, to do the suggestion on previews reply, you have to create renew folder inside existing views folder. This is where you have to paste the file from /wp-content/themes/pro-child/framework/views/renew/ and do the update.

Hope this helps.

Hi X Team,

Ok I did this step, I copied the content.php file and replaced the code.

In my case there was already a Renew folder.
/wp-content/themes/x-child/framework/views/renew (x-child folder is my pro-child folder)

Nothing changed until now on my blog page?

Hi @smart_x ,

I checked and can see the changes. The featured image is now on top of the title instead of below.

You can compare it with our renew demo


Thanks

Hi X Team,

I don’t see it. I added new background images but they don’t show at all.
Also no Read More button?

I read this whole post again and there is also a message from @Prasant where he’s refering to @RueNel about adding code to the child theme’s functions.php file.

I didn’t do that part.

Hi @smart_x,

You mean add featured image? As you have requested

It seems to work

This is the default, the featured image is below the title

With regards to read more, you need to do that if you want read more link.

i.e. Add this code in your child theme’s functions.php file

// Excerpt More String
// =============================================================================

if ( ! function_exists( 'x_excerpt_string' ) ) :
  function x_excerpt_string( $more ) {

    $stack = x_get_stack();

    if ( $stack == 'integrity' ) {
      return ' ... <div><a href="' . get_permalink() . '" class="more-link">' . __( 'Read More', '__x__' ) . '</a></div>';
    } else if ( $stack == 'renew' ) {
      return ' ... <a href="' . get_permalink() . '" class="more-link">' . __( 'Read More', '__x__' ) . '</a>';
    } else if ( $stack == 'icon' ) {
      return ' ... <a href="' . get_permalink() . '" class="more-link">' . __( 'Read More', '__x__' ) . '</a>';
    } else if ( $stack == 'ethos' ) {
      return ' ... <a href="' . get_permalink() . '" class="more-link">' . __( 'Read More', '__x__' ) . '</a>';
    }

  }
  add_filter( 'excerpt_more', 'x_excerpt_string' );
endif;
```


Thanks

Hi X team,

Hi X team,

I just see that I already added the code to my pro child theme. Sorry I forgot about it.
I don’t get a read more button/link?

The featured image is only showing at the blog post that already and had an image. I added other featured images and these are not showing.

Hello @smart_x,

You can only set one featured image in a post. Any image you added in the post content will not be displayed in the post excerpt because excerpts will be generated from the first 55 words on the post contents. Any html code, shortcode or images will not be displayed in the excerpts. If you want to display images, then you need to display full post and not the excerpts. Please go to X > Theme Options > Blog > Content and enable the “Full Post Content on Index” option.

The whole thread is unlisted so only you and our staff will see the screenshots.

Hope this helps.

Hello X Team,

I assume I can set a featured image for each post. As I explained before there featured images for my other posts don’t show.

In the Integity Demo I also see post with less then 55 words with Read More. Is it possible to shorten this?
And how do I make the posts look wider instead of long and small?

Hi @smart_x,

In that case, would you mind providing your admin login credentials in the secure note? Then I’ll check the issue about the featured image.

Then please check this for limiting the excerpt length https://smallenvelop.com/limit-post-excerpt-length-in-wordpress/. Most common is using filter like on #5, and it’s easy as adding it on child theme’s functions.php

Thanks!

Hi X Team,

Thank you for checking.

Can you also have a look at the sidebar for the blog page.

Hello @smart_x,

You featured image do not show in the blog index because you did not assign any featured image.

And if you want to change the number of words in your excerpts, please go to Pro > Theme Options > Blog > Content and change the Excerpt Length value.

Hope this helps.

Hello X Team,

I’m so so sorry, my apologies! I thought that I added the featured image but is was the Background image.

Can you please remove the screenshots. Thank you.

Thank you for the tip for changing the number of words in excerpts in Pro > Theme Options > Blog > Content.
Is it possible to make the posts wider and centered over the whole page?

Hello @smart_x,

The screenshots were now added in the secure note.

The blog items were not centered because there is an empty space for the sidebar. At the moment, the sidebar is blank or empty because you did not added any widget for your custom sidebar. Please do so by going to Appearance > Widgets.

Best Regards.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.