[Support request] Hide Archive page excerpts

Home Forums Support [Support request] Hide Archive page excerpts

Home Forums Support Hide Archive page excerpts

Viewing 12 posts - 16 through 27 (of 27 total)
  • Author
    Posts
  • #2232401
    David
    Staff
    Customer Support

    You’re welcome

    #2232603
    Earl

    Hey Dave,
    Added the code, cleared the cache and the excerpt still haunts me.

    #2232616
    Ying
    Staff
    Customer Support

    I just tested the code, it works fine on my site.

    Can you make sure the you are using ' not in your code?

    And besides the more tag, are you using custom excerpt?
    https://wordpress.com/support/excerpts/#create-an-excerpt

    Let me know!

    #2232635
    Earl

    this is the code from my function php file:

    <?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’ );

    Just to be clear, I am trying to remove the excerpt from the blog post from being displayed on archive pages. I did just check the page in another browser from the one I’m working in and the excerpt still displays.

    #2232640
    Ying
    Staff
    Customer Support

    I did just check the page in another browser from the one I’m working in and the excerpt still displays.

    I know, I can see that too. But you didn’t answer my question. Are you using custom excerpt?

    The code you pated is not wrapped with the code tag, so I can’t check if the format is correct, so can you wrap the code with the code tag?
    https://www.screencast.com/t/FMicVg3blF

    #2232647
    Earl

    sorry missed part of your question.

    I haven’t added anything custom to the theme.

    I did go to the theme customizer -> Layout -> blog -> and set the excerpt work count to ‘0’

    #2232675
    Ying
    Staff
    Customer Support

    My question was are you using the custom expert, can you check if this field is blank in your post editor? Thanks!
    Please refer to the first image in the blow article:
    https://docs.generatepress.com/article/excerpt-issues/

    #2232702
    Earl

    Sorry for being a knucklehead, now I know what you mean:)

    No, nothing is entered at the blog post level for custom excerpts. I do use rank math and I’ve put in a custom description, but it’s pulling from the blog post not the rank math description.

    #2232796
    Fernando
    Customer Support

    Hi Earl,

    Also tested the code and it works as expected from my end, can you try checking for any syntax errors in your functions.php file?

    The code should be exactly:

    add_filter( 'generate_more_tag', '__return_empty_string' );

    If that doesn’t work, as a 2nd course for debugging, try removing the code from your functions.php file, and then install a plugin called Code Snippets, and then add the PHP code there.

    Lastly, can you also try disabling other plugins temporarily as another course of debugging? Try #1 here: https://docs.generatepress.com/article/debugging-tips/

    Kindly let us know how it goes. Hope to hear from you soon!

    #2233305
    Earl

    Got everything to work this morning!

    Big thank you to Dave, Ying and you Fernando for dealing with my shenannigans 🙂

    Final question:
    I want to do a blogroll on the front page with elements, can you provide a link to do that?

    Thanks again!

    #2233344
    David
    Staff
    Customer Support

    Glad to hear that – Would you mind raising a new topic? So we can mark this as resolved 🙂

    #2233655
    Earl

    Will do, thanks David

Viewing 12 posts - 16 through 27 (of 27 total)
  • You must be logged in to reply to this topic.