User Input not writing to Database

I have a database with Email and Name, on a page i have two user inputs with the dataset linked to them and a submit button. When I go into preview mode I input the Email and Name, and check the database BOOM its there. publish the website do the same thing input the data check the database nothing, but it know the input boxes are getting filled with text, because the submit button redirectes me to a different page on completion