[Resolved] add filter does not work

Home Forums Support [Resolved] add filter does not work

Home Forums Support add filter does not work

  • This topic has 3 replies, 3 voices, and was last updated 7 years ago by Leo.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #307830
    Farokh

    Hello,

    add_filter( ‘generate_back_to_top_start_scroll’, ‘tu_back_to_top_start_scroll’ );
    function tu_back_to_top_start_scroll() {
    return 1000;
    }

    I used this filter in my style sheet and its not working!

    What am I missing?

    #307889
    Jamal

    Hi Farokh

    Would you mind trying a lower number like 500 to see if it makes a difference? And please double check that you put that code in theme functions and not your style sheet.

    #307919
    Farokh

    theme function worked
    Thanks

    #307924
    Leo
    Staff
    Customer Support

    It’s probably best to add it using this method: https://docs.generatepress.com/article/adding-php/#code-snippets

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.