I have two dropdwon box. First box has names of the states. Choosing a state will populate the second dropdown box that contains cities of that selected state. For all states city names are stored in mysql database table. now I am little confussed how to model the table and code the dropdown boxes. I can use PHP, mysql, Javasricpt, Ajax. I am just learning basic php and i have to create a website project. So please i need some help. Thank you
Nabaneeta
0
Newbie Poster
Recommended Answers
Jump to PostI recomand you to use JQuery.
I can't give you the entire code but here is some of the logic and just a small example:
$("#main_menu").click(function(){//after a city tab is clicked var city=$(this).text()//get that city name $.post({"myfile.php",{city:city},,function(data){//post to your php file where you can process the …
All 3 Replies
Reply to this topic
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.