page only displays output, db updates on button click