Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Contributor Hardeep Asrani


    Hey there,

    Where exactly do you want to remove the link from? Let us know.


    I was actually looking for a way to include “nofollow” for the links and I thought that snippet was my best clue to start…with the help of these:
    ..I was able to achieve inclusion of nofollow links on both textlink and thumbnail link:

    function alttwo_feedzy_remove_link_matches( $matches ) {
    	return '<a href="' . $matches[1] .'" rel="nofollow" target="_blank">' . $matches[2]. '</a>';
    function alttwo_feedzy_remove_link( $content, $feedURL ) {
        $pattern= '/<a\s+href\s*=\s*"([^"]+)"[^>]*>([\d\D]+)<\/a>/iU';
        $content= preg_replace_callback( $pattern, 'alttwo_feedzy_remove_link_matches', $content );
        return $content;
    add_filter( 'feedzy_global_output', 'alttwo_feedzy_remove_link', 9, 2 );

    Does it look ok?
    I have not yet updated to Feedzy 3.2.8


Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘“How to remove links” -snippet’ is closed to new replies.