Updated pages controller in the backend