Ahh…. Bourne Again SHell.
Not a piece of crap.
edit your ~/.initrc file (or create one) and put these items in it:
"\e[5~": history-search-backward
"\e[6~": history-search-forward
This will bind pg up (5) and pgdown (6) to these bash commands.
For more information, see man readline, man bash (search for inputrc), and your local linux geek.
If you want to bind a key but don’t know the right number (5, or 6 for instance), then in vi, go into insert mode (i), and type C-v, then the key you want to bind and it will output the appropriate number: ^[[19~ is f7 I think.