How to remove nofollow from scroll up button

  • michellecouchfriedman

    I would just like to remove the nofollow instructions on the scroll up button on all of my pages.

  • Hi there,

    Try this PHP snippet:

    add_filter( 'generate_back_to_top_output','custom_back_to_top_output');
    		   
    function custom_back_to_top_output() {
    			printf(
    				'<a title="%1$s" aria-label="%1$s" href="#" class="generate-back-to-top" data-scroll-speed="%2$s" data-start-scroll="%3$s">
    					%5$s
    				</a>',
    				esc_attr__( 'Scroll back to top', 'generatepress' ),
    				absint( apply_filters( 'generate_back_to_top_scroll_speed', 400 ) ),
    				absint( apply_filters( 'generate_back_to_top_start_scroll', 300 ) ),
    				esc_attr( apply_filters( 'generate_back_to_top_icon', 'fa-angle-up' ) ),
    				generate_get_svg_icon( 'arrow-up' )
    			);
    }

    Adding PHP: https://docs.generatepress.com/article/adding-php/

  • michellecouchfriedman

    Thank you 🙂

  • michellecouchfriedman

    That worked. Thank you!!! 🙂

  • You are welcome   🙂

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