- This topic has 26 replies, 5 voices, and was last updated 1 year, 10 months ago by Earl.
-
AuthorPosts
-
May 23, 2022 at 2:42 pm #2230074Earl
I’ve read the documentation here -> https://docs.generatepress.com/article/blog-content-layout/
that tells me to set the excerpt to 0 if I don’t want it show.I’ve done that, but can’t get the excerpt on the archive page to disappear.
Thanks!
May 23, 2022 at 4:09 pm #2230113LeoStaffCustomer SupportHi there,
Any chance you can link us to the page in question?
You can use the private information field:
https://docs.generatepress.com/article/using-the-premium-support-forum/#private-informationLet me know ๐
May 24, 2022 at 2:26 am #2230527EarlHi Leo,
I’ve included a URL to one of my archive pages in the private window. The site shown is a staging site that was set up that I’ll move to the primary URL once the project is finished.May 24, 2022 at 3:55 am #2230633DavidStaffCustomer SupportHi there,
the Excerpt word count in the blog settings only applies to the auto excerpt.
And your posts are using the More tag.You can tell GP to ignore the more tag and use the auto excerpt by adding the PHP Snippet provided here to your site:
https://docs.generatepress.com/article/using-the-more-tag/#overwriting-the-more-tag
May 25, 2022 at 5:39 am #2232078EarlHi Dave,
I read the doc in the link, but I don’t know where to insert the php code that it references.Can you help me with that? Thanks!
May 25, 2022 at 5:58 am #2232093DavidStaffCustomer SupportSorry my bad – this doc explains how to add PHP:
https://docs.generatepress.com/article/adding-php/
TLDR: If you’re using a Child Theme, add the code to your Child Theme functions.php. If you are not using a Child Theme, install the Code Snippets plugin ( link in the doc ) and add the code to a New Snippet.
May 25, 2022 at 6:21 am #2232104Earlthanks for the quick response…
I am using the child theme, but I can’t seem to find where to edit the function php file…
I thought it was in Appearance -> Theme Editor BUT….Theme editor is not listed under ‘Appearance’
sorry to be ‘that guy’ today…
May 25, 2022 at 6:24 am #2232107DavidStaffCustomer SupportAre you logged in as an Admin user ?
May 25, 2022 at 6:29 am #2232113EarlYes sir.
for this project, I created a staging site from the original to work on and then installed GP.May 25, 2022 at 6:37 am #2232122EarlJust tried to create a new admin account to see if the edit function PHP would show up under appearance… no luck
May 25, 2022 at 6:45 am #2232136DavidStaffCustomer SupportTry clearing browser caches and cookies OR login using an incognito/private browser.
That will eliminate caching or cookies as an issue.If that don’t work then it could be security mod in your WP install. Any security plugins installed ?
May 25, 2022 at 7:21 am #2232180Earlstill no joy.
no security mods other than wp rocket and secure copy protection.
May 25, 2022 at 7:42 am #2232202EarlHi Dave,
Looks like I have to take the long way around and edit the functions php file with the host. Does the code below look correct?<?php
/**
* GeneratePress child theme functions and definitions.
*
* Add your custom PHP in this file.
* Only edit this file if you have direct access to it on your server (to fix errors if they happen).
*/
add_filter( ‘generate_more_tag’, ‘__return_empty_string’ );May 25, 2022 at 7:58 am #2232378DavidStaffCustomer SupportPersonally edit the files at the server level is best ๐
That code looks correct!
May 25, 2022 at 8:00 am #2232380EarlThanks for your help Dave!
-
AuthorPosts
- You must be logged in to reply to this topic.