• Resolved Christian

    (@sugarchrist)


    Hello,

    About 4 weeks ago the back to top button disappeared, I did not change anything, I no not have a custom footer.php and I have the latest GP free version 2.1.2
    The only custom php in my child theme is a functions.php
    —————————————————-
    <?php
    // Exit if accessed directly
    if ( !defined( ‘ABSPATH’ ) ) exit;
    // BEGIN ENQUEUE PARENT ACTION
    // AUTO GENERATED – Do not modify or remove comment markers above or below:
    // END ENQUEUE PARENT ACTION
    —————————————————-
    Should I delete my child theme?
    I also tried to disable all the plugin one by one with no result.

    Thank you for your help

    The page I need help with: [log in to see the link]

Viewing 15 replies - 1 through 15 (of 18 total)
  • Leo

    (@leohsiang)

    Hi there,

    The current page you linked is using Elementor Canvas which strips all of GP’s elements.

    Does it work on a static page that’s not using Elementor?

    Let me know ??

    Theme Author Tom

    (@edge22)

    Ah yea, the button was recently hooked into a GP specific hook instead of wp_footer, as that was causing bugs with other plugins.

    As Leo said, the Canvas template strips everything GP related out of the page, including our hooks.

    Thread Starter Christian

    (@sugarchrist)

    Hi Leo and Tom,
    I have change the Elementor canvas to full width and now I can see the “back to top button” but in doing so, I now see the GP menu and copyright footer. What is the solution since I’m using Elementor canvas?

    Thank you very much
    Christian

    Leo

    (@leohsiang)

    Hmm I would say that if you are using Canvas then you should be using back to top button from Elementor as well. Or do they not have that option?

    I just checked your page again and don’t see back to top or GP’s menu/footer showing.

    Thread Starter Christian

    (@sugarchrist)

    Hi Leo,
    You don’t see it because I went back to canvas waiting for a solution.
    There are no “back to top button” in Elementor.

    Is there a way not to use GP header and footer? (just like canvas)

    Thank you
    Christian

    Theme Author Tom

    (@edge22)

    Canvas removes the GP header and footer.

    Are you wanting to remove the GP copyright and menu on all pages, or only specific pages?

    Thread Starter Christian

    (@sugarchrist)

    Hi Tom,

    On all pages (for others sites), but for this website, only this page since there is only one page.

    Thank you

    Theme Author Tom

    (@edge22)

    If that’s the case, you can add this CSS:

    .site-header,
    .site-footer {
        display: none;
    }
    Thread Starter Christian

    (@sugarchrist)

    Hello Tom,

    Thank you for all your help, last question about this…
    Where do I add the CSS code?
    Can I add it with the code snippet plugin?
    Sorry about that, I’m still a beginner with WordPress.

    Thank’s
    Christian

    Theme Author Tom

    (@edge22)

    No problem! This article should help: https://docs.generatepress.com/article/adding-css/

    Hi Tom,

    I have the same problem with a missing ‘back to top’ button, and I am not using Elementor Canvas. I tried to deactivate all plugins, but still no button ?

    This is my site

    Thanks

    Lars

    Theme Author Tom

    (@edge22)

    Hi Lars,

    Are you using any custom template files?

    Yes, I have created a custom template for podcasts, but that was more than a year ago, and I am pretty sure, that this issue occured just recently.

    Theme Author Tom

    (@edge22)

    If you’re using a custom footer.php file, make sure it contains this hook: https://github.com/tomusborne/generatepress/commit/df1c836dbf441c64bbd63da835123dd811f13f6f

    Hi Tom, thanks for helping.

    I am using this for a custom footer:

    /**
    *Fjern temaets normale copyright
    */
    
    add_action('after_setup_theme','generate_copyright_remove_default_message');
    function generate_copyright_remove_default_message()
    {
    		
    	remove_action( 'generate_credits', 'generate_add_footer_info' );
    	remove_action( 'generate_copyright_line','generate_add_login_attribution' );
    }
    
    /**
     * Add the custom copyright
     * @since 0.1
     */
    add_action('generate_credits','generate_copyright_add_custom_message');
    function generate_copyright_add_custom_message()
    {
    ?>
    		Digitalt lejrb?l <i class="fab fa-free-code-camp" style="color:orange"></i> skabt med <i class="fa fa-heart" style="color:red"></i> til historiel?rere - Del og hersk!<br/>
      		<a href="https://historielaerer.dk/privatlivspolitik">Privatlivspolitik/GDPR</a><br/>
      		<a href="https://eepurl.com/4H3hz"><i class="fas fa-envelope-square fa-2x"></i></a>
      		<a href="https://www.facebook.com/historielaererforeningen"><i class="fab fa-facebook-square fa-2x"></i></a>
    		<a href="https://historielaerer.dk/feed/podcast"><i class="fa fa-podcast fa-2x"></i></a>
    		<a href="https://twitter.com/forumhistoricus"> <i class="fab fa-twitter-square fa-2x"></i></a> 
    		<a href="https://www.linkedin.com/company/historiel%C3%A6rerforeningen-for-gymnasiet-og-hf"> <i class="fab fa-linkedin-square fa-2x"></i></a>
    		<a href="https://www.youtube.com/channel/UCS4VfPJF-jyU_D66ulPBTKQ"> <i class="fab fa-youtube-square fa-2x"></i></a>
    <?php
    }

    .. but I can’t locate <?php wp_footer(); ?> in this?

Viewing 15 replies - 1 through 15 (of 18 total)
  • The topic ‘back to top button’ is closed to new replies.