there really aren't commands. The HTML stuff would just be something like:
-- Get user-input about questions (#, order, questions)
-- Get user-input about answering methods (checkboxes, radio-buttons, text-field, etc)
-- Get user-input about answers to questions (question #, answer, other answer options)
-- Take all that, create the php page to show the form AND check answers
-- Store that in a string
-- Write string to *.html file using [man]fwrite/man