Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

Hello Perl Monks,

I am looking for some code in Perl or Java that will have 2 drop down menu. The first drop down menu will have a list of states and once the user selected a particular state, the second deop down menu will have list of cities for the corresponding selected state. I saw this code in action at www.beazer.com when I clicked on search for house but I think they did it using javascript. Anyway to do this in Perl? An example would be appreciated.
Thanks.
  • Comment on Displaying a list of cities when the user select the state

Replies are listed 'Best First'.
Re: Displaying a list of cities when the user select the state
by aku (Monk) on Nov 05, 2007 at 08:09 UTC
    Only way to do it with perl would be to submit the form after selecting the state and process the parameters and return a new page with the cities popup, but I don't think that you want to do that. Stick with the javascript solution. Use one of the many javascript libraries. For example: JQuery.