Home > Article > Web Front-end > Newbie asking about dynamic changes of html form elements_html/css_WEB-ITnose
[b]For example, the option content of one drop-down menu changes with the content of another drop-down menu. For example, the first drop-down selects the school, and the second drop-down selects the campus. Different schools have different campuses, so the second drop-down needs to change as the first changes.
Bind an action in the first drop-down box, onchange="change()", and get the corresponding in the bound change function Select the selected content of the drop-down box, and then operate the corresponding control that needs to be changed.
Drop-down menu linkage requires JS. Consider using ajax technology.
The pure JS implementation code may be a little more, but if you use a framework, there are ready-made things that can be applied
http://www.jb51.net/article/9790.htm