Some formatting and adding necessary routing to avoid wrong access to pages