function fillCountry(){ addOption(document.drop_list.country, '', 'All');addOption(document.drop_list.country, 'Algeria', 'Algeria');addOption(document.drop_list.country, 'Bahrain', 'Bahrain');addOption(document.drop_list.country, 'Egypt', 'Egypt');addOption(document.drop_list.country, 'Iraq', 'Iraq');addOption(document.drop_list.country, 'Jordan', 'Jordan');addOption(document.drop_list.country, 'Kuwait', 'Kuwait');addOption(document.drop_list.country, 'Lebanon', 'Lebanon');addOption(document.drop_list.country, 'Libya', 'Libya');addOption(document.drop_list.country, 'Morocco', 'Morocco');addOption(document.drop_list.country, 'Oman', 'Oman');addOption(document.drop_list.country, 'Qatar', 'Qatar');addOption(document.drop_list.country, 'Saudi Arabia', 'Saudi Arabia');addOption(document.drop_list.country, 'South Sudan', 'South Sudan');addOption(document.drop_list.country, 'Sudan', 'Sudan');addOption(document.drop_list.country, 'Syria', 'Syria');addOption(document.drop_list.country, 'Tunis', 'Tunis');addOption(document.drop_list.country, 'U.A.E.', 'U.A.E.');addOption(document.drop_list.country, 'Yemen', 'Yemen');} function SelectSubCounty(){ removeAllOptions(document.drop_list.subcounty); if(document.drop_list.country.value == 'Saudi Arabia'){addOption(document.drop_list.subcounty,'', 'All');addOption(document.drop_list.subcounty,'Abha', 'Abha');addOption(document.drop_list.subcounty,'Al-Khobar', 'Al-Khobar');addOption(document.drop_list.subcounty,'Dammam', 'Dammam');addOption(document.drop_list.subcounty,'Dhahran', 'Dhahran');addOption(document.drop_list.subcounty,'Jazan', 'Jazan');addOption(document.drop_list.subcounty,'Jeddah', 'Jeddah');addOption(document.drop_list.subcounty,'Jubail', 'Jubail');addOption(document.drop_list.subcounty,'North Ghawar', 'North Ghawar');addOption(document.drop_list.subcounty,'Ras Tanura', 'Ras Tanura');addOption(document.drop_list.subcounty,'Riyadh', 'Riyadh');addOption(document.drop_list.subcounty,'Tabuk', 'Tabuk');addOption(document.drop_list.subcounty,'Wadi Al Dawaser', 'Wadi Al Dawaser');addOption(document.drop_list.subcounty,'Yanbu', 'Yanbu');}if(document.drop_list.country.value == 'South Sudan'){addOption(document.drop_list.subcounty,'', 'All');addOption(document.drop_list.subcounty,'Juba', 'Juba');}if(document.drop_list.country.value == 'Qatar'){addOption(document.drop_list.subcounty,'', 'All');addOption(document.drop_list.subcounty,'Doha', 'Doha');}if(document.drop_list.country.value == 'Kuwait'){addOption(document.drop_list.subcounty,'', 'All');addOption(document.drop_list.subcounty,'Kuwait City', 'Kuwait City');}if(document.drop_list.country.value == 'U.A.E.'){addOption(document.drop_list.subcounty,'', 'All');addOption(document.drop_list.subcounty,'Abu Dhabi', 'Abu Dhabi');addOption(document.drop_list.subcounty,'Dubai', 'Dubai');addOption(document.drop_list.subcounty,'Sharjah', 'Sharjah');}if(document.drop_list.country.value == 'Egypt'){addOption(document.drop_list.subcounty,'', 'All');addOption(document.drop_list.subcounty,'Alexandria', 'Alexandria');addOption(document.drop_list.subcounty,'Cairo', 'Cairo');addOption(document.drop_list.subcounty,'Hurghada', 'Hurghada');addOption(document.drop_list.subcounty,'Sharm El Sheikh', 'Sharm El Sheikh');}if(document.drop_list.country.value == 'Algeria'){addOption(document.drop_list.subcounty,'', 'All');addOption(document.drop_list.subcounty,'Algeria', 'Algeria');}} ////////////////// function removeAllOptions(selectbox) { var i; for(i=selectbox.options.length-1;i>=0;i--) { //selectbox.options.remove(i); selectbox.remove(i); } } function addOption(selectbox, value, text ) { var optn = document.createElement("OPTION"); optn.text = text; optn.value = value; selectbox.options.add(optn); }