adding pages update functionality

now able to edit pages