问题描述
数据库结构:
-MassWarVetsADM(数据库名称)
-商务(商务表)
-BName |主键
-Category
- 类别(类别表)
-Category |外键引用父母业务:类别
仅使用php和javascript,有人可以协助我填写2个选择框,并符合以下规定?
首先,用户将从我主页上的选择框中选择一个商业类别(类别:类别),该类别将从(类别:类别)加载类别加载主页时的表/列。
然后在选择类别后填充第二个选择框,共享该类别的所有商家名称(Bname) 。非常感谢您的帮助!
Database structure:
-MassWarVetsADM (database name)
-Business (business table)
-BName | Primary Key
-Category
-Category (category table)
-Category | Foreign key referencing parent Business:Category
Using php & javascript only, can someone assist me in populating 2 select boxes with the following stipulations?
First a user will select a business category (Category:Category) from a select box on my homepage, that will have the categories loaded from the (Category:Category) table/column upon loading the homepage.
Then a second select box will populate after a category selection is made, all of the Business names(Bname) that share that category. Your help is greatly appreciated!
推荐答案
这篇关于如何根据第一个菜单中的选择从我的数据库中填充2个下拉菜单的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!