WordPress: delete enclosures of media files in feeds


/ Published in: PHP
Save to your folder(s)



Copy this code and paste it in your HTML
  1. // delete enclosures of media files in feeds
  2. add_filter( 'get_enclosed', 'delete_enclosure' );
  3. add_filter( 'rss_enclosure', 'delete_enclosure' );
  4. add_filter( 'atom_enclosure', 'delete_enclosure' );
  5. function delete_enclosure() {
  6. return '';
  7. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.