How to use php to control the selected values in the select statement

Source: Internet
Author: User
How can I use php to control the selected values in the select statement? For example, I have a select form & lt; select & nbsp; name = "select_1" & gt; & lt; option & nbsp; value = "" & gt; & lt; /option & gt; & lt; option & nbsp; value = "value_1" & gt; how to use php to control the selected values in the select statement?
For example, I have a select form.



option_1
option_2
.....
option_n


The last n may be very large. my design is to save the user form submitted to mysql, and then the user can edit it. on the editing page, this single-choice form must be displayed as a mysql value in the selected status. I have read the value in mysql $ value_select_1. how can I use php to control this select_1 form and select the value of $ value_select_1?

Soon after learning php, I hope I will not be enlightened. Share: More

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.