Miscellaneous fixes

* Fixes issue where false-y values were treated as present when reading cached info about PMs. The redis cache backend returns null if a key isn't found rather than false, so this over-strictness was an issue. A false-y value shouldn't be returned by any of the backends if the key is present in this case.

* Make pm_snippet use mb_substr.

* Fixed openBoard and boardTitle functions to not trample each other's cache, and refactored their common functionality so they both call getBoardInfo.

* Fixed issue with page after a theme is installed.

* Fix broken entity removal in post truncation. The regex was incorrect and would not remove a single "&" character at the end.

* Make mod.php ignore extra URL parameters. jQuery appends some parameters like "&_=1371573728564" to a URL in AJAX requests set with cache:false, which used to break requests to pages under mod.php.

I think none of these changes are too controversial, so I've bundled them up into one pull request unlike the others.