HI... I have two combo boxes in which the first one is used for choosing the Regions and the second one is for the corresponding countries. I would like to do this with Perl and html without importation any modules and eventhough it is better by Javascript.
I am getting the pull down menu values through cgi Param functions. Now when the user chooses the region and the country,the values are assigned to the $review_region and the $country_code res. While I am trying to hard code the display by the following way.. the following country overrides the previous one. my requirement is when the user choose the region,only the corresponding countries should be displayed. Please pardon me the clarification is not sufficient and let me know to add more... ~; my $selected; if(($review_region eq 'North America') && ($country_code eq 'Canada')) { $selected="selected";}else{$selected="";} print qq ~ <option value="Canada" $selected >Canada</option> ~; if(($review_region eq 'North America') && ($country_code eq 'United States')) { $selected="selected";}else{$selected="";} print qq ~ <option value="United States" $selected >United States</option> ~; if(($review_region eq 'Europe') && ($country_code eq 'Denmark')) { $selected="selected";}else{$selected="";} print qq ~ <option value="Denmark" $selected >Denmark</option> ~; if(($review_region eq 'Europe') && ($country_code eq 'Denmark')) { $selected="selected";}else{$selected="";} print qq ~ <option value="Denmark" $selected >Denmark</option> ~; Thanks and Regards, E.Elavazhagan.