Archived topic
A few tweaks to the GP theme
6 replies · Started by Yoeri on January 28, 2020
Goodday people of GP! :)
Here I am again for some tweaks to the GeneratePress theme. I need the following for one of the websites I'm working on:
1.: If you click the 'read more' buttons, #more will be placed in the url after the post excerpt. How can I disable this for clean urls?
2.: I want to place the post title in the 'read more' buttons, something like 'Read [post title]'
3.: The next/previous posts which are placed under posts are now under each other. I'd like to have them next to eachother, like: < [previous post here] [next post here] >
4.: I want the post dates displayed without it being a link.
Thank you in advance for your help :)
Hi there,
1. https://docs.generatepress.com/article/generate_more_jump/
2. I'll confirm this one with Tom :)
3. https://docs.generatepress.com/article/inline-post-navigation/
4. https://docs.generatepress.com/article/generate_post_date_output/#remove-link-from-date
Hi there,
Give this a shot:
add_filter( 'option_generate_blog_settings', function( $settings ) {
$settings['read_more'] = $settings['read_more'] . ' ' . get_the_title();
return $settings;
} );
Let me know :)
Thanks Leo and Tom! Works like a charm.
For the button part it is almost like we want it. Now it shows the button text which is setup in the customizer and after that the post title. I'd like to have it literraly: '[post title] lezen'
What do I have to change in the php snippet? Thank you again! :)
Hi there,
try:
add_filter( 'option_generate_blog_settings', function( $settings ) {
$settings['read_more'] = get_the_title() . ' lezen';
return $settings;
} );
Amazing, just like we want it! Thank you all so much! 😊❤️
Glad we could help :)