Pages with template chooser work again. Fixes #1942.
Merge pull request #1943 from rossriley/php53-fixes

php53 json error fix
change a couple more occurrences