View Single Post
Old 01-11-07, 01:51 PM   #64 (permalink)
Pocketbrain
Aximsite Hall of Fame
 
Pocketbrain's Avatar
Addicted Member
 
Join Date: Mar 2005
Location: West Palm Beach, FL
Posts: 6,025
Device: iPhone
Carrier: AT&T
Thanked 0 Times in 0 Posts
Greasemonkey script for listing more threads

New Greasemonkey script for Firefox written by yours truly will put up to 200 threads on your search page!
Ever want to view more than the default 25 threads when you click the View New Posts or Today's Posts buttons? This script will allow you to view up to 200 per page. That's not a limit set in the script, but by the engine. Sure, you can put 300 instead of 200, but the max. is 200.
Paste this into your a new Greasemonkey user script or download the script itself below:
Code:
// ==UserScript==
// @name           Forum Long List
// Author: "PocketBrain" Karl J. Knippel
// @namespace      http://www.mobilitysite.com/
// @description    Make Search lists on forums larger than the default.
// @include        http://www.mobilitysite.com/forums/search.php?*
// @include        http://www.aximsite.com/boards/search.php?*
// just add more to the include list as they become usable.
// ==/UserScript==

// This is cyclic.  As soon as the new URL is posted, it acts 
//  again to append the '&pp=200' term again, repeatedly.
// window.location.href = window.location.href + ('&pp=200')

// if !(window.location.href.match(/pp=\?/)) {
//      window.location.href = window.location.href + ('&pp=200')
// }

// This one works, but will become cyclic if there are more than 
//  200 listings in the search.
// if (document.body.textContent.match('Page 1 of')) {
//      window.location.href = window.location.href + ('&pp=200')
// }


// This one works!  Yayyyy!!!
// Pseudocode: 
//       If the URL doesn't have "pp=" in it, add "&pp=200" to the end and reload the page.
var pagestg = 'pp=';
if  (!(window.location.href.match(pagestg)))  {
     window.location.href = window.location.href + ('&pp=200')
}
You can see the evolution and some evidence of my chaotic mind; I left limited-working or non-working versions of the script in place. As it is, it's quite small! Note that I included MobilitySite too. You can add any website that the "&pp=" trick works with.

Don't forget to remove the .txt extension from the download once you have it on your desktop. Drag it over to your Firefox Browser. Get Greasemonkey if you don't have it already.
Attached Files:
File Type: txt forumlonglist.user.js.txt (1.1 KB, 10 views)

Last edited by PocketBrain; 01-15-07 at 08:47 PM.
Pocketbrain is offline   Reply With Quote