rewrite controller so that page parameters can be easily retrieved
Merge branch 'master' into 2.5