Changeset 164
- Timestamp:
- 11/13/07 03:00:37 (14 months ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
facebook-app-spam/trunk/facebookappspamremover.user.js
r159 r164 1 1 // Facebook App Spam Remover 2 // Version 1.0 -SVN2 // Version 1.01-SVN 3 3 4 4 // This Greasemonkey script removes the application spam which has … … 49 49 50 50 divs = document.getElementsByTagName('div'); 51 pattern = new RegExp("(^|\\s) app_story(\\s|$)");51 pattern = new RegExp("(^|\\s)(ad_capsule|app_story)(\\s|$)"); 52 52 for (i = 0; divs && i < divs.length; i ++) { 53 if (pattern.test(divs[i].className)) { 53 classes = pattern.exec(divs[i].className) 54 if (classes) { 54 55 divs[i].style.display = "none"; 55 divs[i].previousSibling.lastChild.style.display = "none"; 56 divs[i].nextSibling.style.padding = 0; 57 divs[i].nextSibling.className="clearfix"; 56 linepattern = new RegExp("(^|\\s)(one_liner|one_liner_cluster)(\\s|$)"); 57 if (linepattern.test(divs[i].nextSibling.className)) { 58 if (classes[2] == 'app_story') { 59 divs[i].previousSibling.lastChild.style.display = "none"; 60 } 61 divs[i].nextSibling.style.padding = 0; 62 divs[i].nextSibling.className="clearfix"; 63 } 58 64 } 59 65 }
