Home  >  Article  >  Web Front-end  >  How to generate a questionnaire_html/css_WEB-ITnose

How to generate a questionnaire_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 12:15:311920browse

All questions are stored in a database table, and all options are stored in a database table. Now check out these data and put them in a static page. Can anyone tell me what the idea is? I should use a double loop to generate a question. , loop to generate several corresponding options, generate a question, and then loop to generate several corresponding options. Repeat this. Who knows how to do it? Or share your ideas


Reply to the discussion (solution)

You can use a json object, or a two-dimensional array~·

Is there any other way? Ah

Or find them all and put them in the List, traverse in the frontend

Type of question (data structure)
How to save (how to access)
Form of the generated questionnaire ( How to display determines how you write code)
How to specify the number and type of questions when generating the questionnaire (strategy)

How to give points with so few people answering

The option table is subordinate to the question table

How can I give points with so few people answering?

Can you tell me how you achieved it

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn