Hi dear
I want to create a dynamic page where i want select country name in first drop down menu and then get its related city list in second drop down list
how this will work in php

Recommended Answers

All 4 Replies

If you only want to do this using PHP, you would have to generate a post back so that you can get the value of the first drop down so that you can populate the second drop down.

If you incorporate client side technologies including javascript, jQuery and AJAX, you can make a call back to the server by sending info about th value of the first drop down so you can populate the second without the need to refresh the page.

This is just one option... There are others, plu-ins out there, etc...

Please explain with coding so that i can better known

I don't have ready made code to give you. I was simply providing guidance.

It would be better if you provide your relevant code so that members here can help you with errors or problems.

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.