add in pages functionality