added share and save functionality