Skip to content

Instantly share code, notes, and snippets.

@nbriz
Last active August 29, 2015 14:03
Show Gist options
  • Save nbriz/973c46f7bb60c919da03 to your computer and use it in GitHub Desktop.
Save nbriz/973c46f7bb60c919da03 to your computer and use it in GitHub Desktop.
removePost.js
$('span').each(function( i ) {
if( $(this).html() == 'Report'){ $(this).click(); }
if( $(this).html() == 'Report/Remove Tag'){ $(this).click(); }
if( $(this).html() == 'Remove Tag...'){ $(this).click(); }
if( $(this).html() == 'Delete This Photo'){ $(this).click(); }
if( $(this).html() == 'Delete'){ $(this).click(); }
if( $(this).html() == 'Delete...'){ $(this).click(); }
if( $(this).html() == 'Unlike'){ $(this).click(); }
});
@pretenditsthesea
Copy link

This code isn't opening up the report/remove boxes for untagging photos. It is working for deleting other activity though.

@pretenditsthesea
Copy link

The console reads "undefined" after the previous piece of code, indicating that the submenus are there. When I enter this code to open the report/remove boxes, the console displays:
m.fn.init[669]
Sorry I can't be more proactive and fix the problem myself. I really appreciate what you have shared here. Any help is also appreciated.

@seandogg
Copy link

seeing the same issue as you, pretend... report / remove isn't firing. tested to see if it was hidden by cutting and pasting the next step:

$( "input[name|='untag']" ).click();

and it returns:

[]

@Take27
Copy link

Take27 commented Jul 19, 2014

Doesn't work for me neither.please help

@nbriz
Copy link
Author

nbriz commented Jul 21, 2014

UPDATES >>>> http://nickbriz.com/facebook/unfriend.html <<< new scripts which might help ( comment here if u still have issues )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment