You'll need to create a backend script, where users can create the form. You can choose to generate an html file there, but it's probably better to save everything into a database and create a seperate (frontend) php thing that generates the form. The submit button should post everything to another php file, that saves the input (into a database, as JSON, preferably). Last thing is to create a file that shows the input nicely (you can make that very simple or complicated, with graphs, for example).
Important thing about the form creating (first step) I think is to first write down for yourself every feature that you want / things that should be able to do. Then, design the database table, and then, start coding. Otherwise (I think) you'll be re-writing things at some point.
If there are things in this you don't know how to do, just ask.