Adding save button functionality