Home › Forums › Support › Support on meta display and change load-more in blog-page and achived-page.
- This topic has 9 replies, 2 voices, and was last updated 4 years, 5 months ago by Tom.
-
AuthorPosts
-
October 14, 2019 at 2:22 am #1033983An Nguyen
Hi Tom,
I need your help on 2 issues:
1/ Last post, you gave me PHP code can change position of footer-meta (categories) above title. It’s worked. However, the summary of post is above the title too.
add_action( 'wp', function() { if ( ! is_singular() ) { remove_action( 'generate_after_entry_content', 'generate_footer_meta' ); add_action( 'generate_before_content', 'generate_footer_meta', 15 ); } } );
Now I want to display summary below the title (in current HTML-markup it’s the same level of “entry-header”). Now, I wanna reorder its position inside the HTML-markup below:
<header class="entry-header"></header> <h2 class="entry-title" itemprop="headline"></h2> <div class="entry-summary" itemprop="text"> -------->(I want it'll be put here) <div class="entry-meta"></div>
+And I can add some customised contents next to summary like(button, readmore, icon read or customised text…). Could you support me with PHP code?
2/I can set “load more” posts like paginations in achived-page and blog-page? ( Articles: 1 2 3 4…1200 ) .
October 14, 2019 at 10:34 am #1034466TomLead DeveloperLead DeveloperHi there,
1. I’m not too sure what you mean here. Are you trying to move the post meta inside the
entry-summary
element?2. This isn’t possible at the moment, unfortunately.
October 14, 2019 at 3:42 pm #1034634An NguyenHi Tom,
I try to summary my idea again. I hope you can help.
1/I want “entry-summary” is between “entry title” and “entry-meta”. It means that summary displays below post title and above entry-meta. Now, the post summary is above title. You can take a look on my updated link.
+And I can add some customised contents next to summary like (button, readmore, icon read or customised text…).
Thanks Tom.
October 14, 2019 at 8:15 pm #1034758TomLead DeveloperLead DeveloperWhat if you do this?:
.entry-summary { order: 3; }
Are you wanting to replace the current read more link? If you want to turn it into a button, you can do that in Customize > Layout > Blog.
October 14, 2019 at 9:49 pm #1034795An NguyenHi Tom,
I used flex for inside-article so I’m clear about that and already did that. However, the summary is at the bottom instead of entry-meta. Both entry-header & entry-summary are the same level. Entry-title & entry-meta are child inside entry-header. Now, the order of entry header is 2, so that bothe entry-title & entry-meta are above entry-summary.
Current html markup:
<header class="entry-header"></header> <h2 class="entry-title" itemprop="headline"></h2> <div class="entry-meta"></div> <div class="entry-summary" itemprop="text">
That why I reckon it should be here. Entry-summary will be a child inside entry-header. Maybe, you will have another better solution for this case.
<header class="entry-header"></header> <h2 class="entry-title" itemprop="headline"></h2> <div class="entry-summary" itemprop="text"> -------->(I want it'll be put here) <div class="entry-meta"></div>
October 15, 2019 at 9:49 am #1035454TomLead DeveloperLead DeveloperSo you want the author, date, time to read below the entry summary?
October 15, 2019 at 10:43 am #1035507An NguyenHi Tom,
It’s definitely, Tom.
Thanks.
October 15, 2019 at 7:56 pm #1035819TomLead DeveloperLead DeveloperTry this:
remove_action( 'generate_after_entry_title', 'generate_post_meta' ); add_action( 'generate_after_entry_content', 'generate_post_meta' );
That will move the HTML. You may need to adjust the “order” CSS values as well.
October 17, 2019 at 12:50 am #1036931An NguyenHi Tom,
The code worked perfectly.
Thanks Tom
October 17, 2019 at 9:56 am #1037410TomLead DeveloperLead DeveloperYou’re welcome 🙂
-
AuthorPosts
- You must be logged in to reply to this topic.