• Resolved DarkCoder

    (@darkcod3r)


    Hi. i am using generateblocks button. When i add link in button and enable “open link in new tab” option it also adds noreferrer tag as well. i dont want that noref tag (cause i am using amazon affiliate links, and it is against their policy). So is their any way to stop adding norefferer tag when enable “open in new tab” option.?!
    Thank You

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Tom

    (@edge22)

    Hi there,

    You can add a PHP function like this:

    add_filter( 'render_block', function( $block_content, $block ) {
        if ( 'generateblocks/button' === $block['blockName'] ) {
            $block_content = str_replace( 'noreferrer', '', $block_content );
        }
    
        return $block_content;
    }, 10, 2 );

    Let me know ??

    Thread Starter DarkCoder

    (@darkcod3r)

    @edge22 Thanks. Worked.. ??

    Plugin Author Tom

    (@edge22)

    Glad I could help ??

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Is it possible to disable/remove noreferrer tag?!’ is closed to new replies.