Archived topic
How to make the Read more link appear inline after a post excerpt
5 replies · Started by danhotchkiss on July 16, 2022
Is there a way to accomplish this? Here's what I've tried:
.wp-block-read-more{
display:inline-block !important;
color:red !important;
padding:0 !important;
margin:0 !important;
}
Everything works except display:inline-block, which seems to have no effect.
Thanks!
Dan
Hi there,
if you want it to be displayed inline with the excerpt, then you will need to:
1. Remove the read more block.
2. Select the Headline Block that is displaying the Excerpt and in its Dynamic Settings select: Use default more link
3. As it looks like you're using custom excerpts you will also need to add the snippet provided here for that to display;
https://docs.generatepress.com/article/activating-read-custom-excerpt/#read-more-text
Note that this will only display on the front end - not the editor.
Thanks for your quick response. That worked.
(I learned in the process, I believe, that only one of the Read-More snippets should be activated at a time. If that is true it would be a useful addition to the documentation for these snippets.)
One more question: I don't see a separate class for the "Read more" text. Is there a way to style it separately, or to make it a link without making the whole excerpt a link?
Dan
1. You can remove the link from the excerpt by removing the value from the Link sourceoption.
2. Once the link is removed from the excerpt, you can use this selector to style the read more link: div#CurrentNews p a
Thanks, Ying and David. I cannot tell what a pleasure it is to get such helpful help. I learn something new each time I write or eavesdrop on your help to others.
I had not realized before how useful the HTML Anchor at the bottom of each Container block could be. Not only does it create a unique set of CSS selectors, but it also puts a label for the container in the editor's List View. Very helpful when navigating around the editor!
Dan
Glad you are happy with our support :)
It's our pleasure to be helpful!