Updated paging logic with modular math suggested by danny.
Code cleanup and added comments to all functions. Cleaned up code sniffer errors, and rewrote the title/details display functionality.
Merge pull request #10 from MorganDawe/master

Comments, code sniffer cleanup and bug fixes