[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 326
  • Last Modified:

Select box

Hi,

How can I in coldfusion if I select from the select box then populate the data

so, I don't want the select to get populated when I open the page

what should I say here

<cfif isdefined('form.?) can I do form.GetState  GetSate is a dropdown box.

<select name="GetCity" style="width: 180px;height:200px;" size="8" multiple="multiple"/>
<cfoutput>
<cfloop from="1" to="#listlen(myCitiesList)#" index="i" step="3">
<option value="#listgetat(myCitiesList,i+1)#">#listgetat(myCitiesList,i+2)#</option>
</cfloop>
</cfoutput>
</select>

http://www.churchesbulletin.com/

what I want to do is when the user open this site the page should not populate the city data unless the user select the state.  
0
lulu50
Asked:
lulu50
1 Solution
 
ravi_bachwalaCommented:
You can do it in 2-ways:
1. on form submission i.e when you select the state generate the city drop down.
2. on Using of Custom Tag with all the city and generated but when state is selected fire the event to the custom tag which pulls the data for the City.

Thanks
Ravi
0
 
gdemariaCommented:

Ravi covered two options, a third could be using bind on the CFSELECT tags.

so all three options..

1) select the state, submit the form, show the cities (easiest approach for coding, worst for user)
2) use custom tag TWOSELECTSRELATED to fetch and populate two dependant select statements  (good use experience, harder to code)
3) use cfc and CFSELECT with Binding  (good user experience, harder to code, need to setup a cfc, not bad if you've done it before)



0
 
digicidalCommented:
The caveat to gdemaria's addition would be the version of ColdFusion you are using... are you using CF8 or CF9 at least?  If so I'd definitely recommend the binding option.  Either that or if not you could do the same thing with an earlier CF version (i.e. MX,7) by utilizing jQuery or extJS ajax frameworks - although if all you're doing is this that might be overkill.

Ben Forta has a nice example at his blog for CF8 (same works for CF9).

There's also an example for earlier versions with pure javascript and a custom tag (although I haven't tried it because I still prefer gdemaria's third suggestion).  Just wanted to give you some referrences.
0
Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

 
ZvonkoSystems architectCommented:
Yes, you can use CFIF like this:
<form name="FRMAcc" action="" method="post" enctype="multipart/form-data">
<select name="DispStateBox" style="width: 180px;height:200px;" size="8"  onChange="this.form.submit()" >
  <option value="22">Michigan (MI)</option>
  <option value="35">Ohio (OH)</option>
</select>

<cfif isdefined("form.DispStateBox")>

<select name="GetCity" style="width: 180px;height:200px;" size="8" multiple="multiple"/>
<cfoutput>
<cfloop from="1" to="#listlen(myCitiesList)#" index="i" step="3">
  <cfif listgetat(myCitiesList,i) EQ form.DispStateBox >
<option value="#listgetat(myCitiesList,i+1)#">#listgetat(myCitiesList,i+2)#</option>
  </cfif>
</cfloop>
</cfoutput>
</select> 

</cfif>

Open in new window

0
 
ZvonkoSystems architectCommented:
Please note two changes on your FORM:
1.) You do not have a SUBMIT button on your form and therefore I changed your State select onChange to do the submit();
2.) You cannot select multiple State from the Cities list and therefore I removed that attribute from the <select>


0
 
ZvonkoSystems architectCommented:
Of course it is much faster if you do it in the Browser and not onSubmit:
<script type="text/javascript">
function setOptionCity(chosen) {
  //Method to populate City based on the selected State
  //document.FRMAcc.GetChurch.options.length = 0;
  //document.FRMAcc.allChrch.checked = false;
  var getmyCityList = '35,4580,Aberdeen,22,3832,Acme,22,3833,Ada,35,4581,Ada,35,4582,Adamsville,22,3834,Addison,35,4583,Addyston,35,4584,Adena,22,1447,Adrian,22,3835,Akron,35,4585,Akron,22,1448,Alanson,22,3836,Alba,35,4586,Albany,22,1449,Albion,22,3837,Alden,35,4587,Alexandria,22,3838,Alger,35,4588,Alger,22,3839,Algonac,22,1450,Allegan,22,3840,Allen,22,3841,Allen Park,22,3842,Allendale,22,3843,Allenton,35,4589,Alliance,22,1452,Alma,22,3844,Almont,22,1453,Alpena,22,3845,Alto,35,4590,Amanda,22,3846,Amasa,35,4591,Amelia,35,4592,Amesville,35,4593,Amherst,35,4594,Amsterdam,35,4595,Andover,22,1455,Ann Arbor,35,4596,Anna,35,4597,Ansonia,35,4598,Antwerp,35,4599,Apple Creek,22,3847,Applegate,35,4600,Arcadia,22,3848,Arcadia,35,4601,Arcanum,35,4602,Archbold,22,3849,Argyle,35,4603,Arlington,22,3850,Armada,35,4604,Ashland,22,3851,Ashley,35,4605,Ashley,35,4606,Ashtabula,35,4607,Ashville,35,4608,Athens,22,1456,Athens,22,3852,Atlanta,22,3853,Attica,35,4609,Attica,35,4610,Atwater,22,3854,Au Gres,22,3855,Au Train,22,3856,Auburn,22,3857,Auburn Hills,22,3858,Augusta,35,4611,Aurora,35,4612,Austinburg,35,4613,Austintown,35,4614,Avon,35,4615,Avon Lake,22,3859,Azalia,22,3860,Bad Axe,22,3861,Bailey,35,4616,Bainbridge,35,4617,Bakersville,22,3862,Baldwin,35,4618,Baltic,35,4619,Baltimore,22,3863,Bancroft,22,3864,Bangor,22,3865,Bannister,22,3866,Baraga,35,4620,Barberton,22,1459,Bark River,35,4621,Barlow,35,4622,Barnesville,22,1460,Baroda,22,3867,Barryton,22,3868,Barton City,35,4623,Bascom,35,4624,Batavia,22,3869,Bath,22,1462,Battle Creek,22,1463,Bay City,22,3870,Bay Port,22,3871,Bay Shore,35,4625,Beach City,35,4626,Beachwood,35,4627,Beallsville,22,3872,Bear Lake,35,4628,Beaver,22,3873,Beaver Island,35,4629,Beavercreek,35,4630,Beavercreek Twp,35,4631,Beaverdam,22,3874,Beaverton,35,4632,Bedford,22,3875,Belding,35,4633,Bellaire,22,3876,Bellaire,35,4634,Bellbrook,35,4635,Belle Center,35,4636,Belle Valley,35,4637,Bellefontaine,22,3877,Belleville,22,3878,Bellevue,35,4638,Bellevue,35,4639,Bellville,22,3879,Belmont,35,4640,Belmont,35,4641,Beloit,35,4642,Belpre,22,3880,Bentley,22,1467,Benton Harbor,35,4643,Benton Ridge,22,3881,Benzonia,35,4644,Berea,35,4645,Bergholz,22,3882,Bergland,35,4646,Berkey,22,3883,Berkley,35,4647,Berlin,22,3884,Berlin,35,4648,Berlin Center,35,4649,Berlin Heights,22,3885,Berrien Center,22,1469,Berrien Springs,22,3886,Bessemer,35,4650,Bethel,35,4651,Bethesda,35,4652,Bettsville,22,3887,Beulah,35,4653,Beverly,22,1470,Beverly Hills,35,4654,Bexley,35,4655,Bidwell,22,3888,Big Bay,35,4656,Big Prairie,22,1471,Big Rapids,22,3889,Birch Run,35,4657,Birmingham,22,1472,Birmingham,22,3890,Bitely,35,4658,Blacklick,35,4659,Bladensburg,22,3891,Blanchard,35,4660,Blanchester,22,3892,Blissfield,35,4661,Bloomdale,22,1473,Bloomfield Hills,35,4662,Bloomingdale,22,3893,Bloomingdale,35,4663,Bloomville,35,4664,Blue Ash,35,4665,Blue Creek,35,4666,Bluffton,35,4667,Boardman,35,4668,Bolivar,22,3894,Boon,35,4669,Botkins,35,4670,Bowerston,35,4671,Bowersville,35,4672,Bowling Green,22,3895,Boyne City,35,4673,Bradford,35,4674,Bradner,22,1475,Branch,22,3896,Brant,22,3897,Breckenridge,35,4675,Brecksville,35,4676,Bremen,22,3898,Brethren,35,4677,Brewster,35,4678,Brice,22,3899,Bridgeport,35,4679,Bridgeport,22,3900,Bridgman,22,1477,Brighton,35,4680,Brilliant,22,3901,Brimley,35,4681,Brinkhaven,35,4682,Bristolville,22,3902,Britton,22,3903,Brockway,22,1478,Bronson,35,4683,Brookfield,22,3904,Brooklyn,35,4684,Brookville,22,3905,Brown City,22,3906,Brownstown,22,3907,Brownstown Twp,22,3908,Bruce Crossing,22,3909,Bruce Twp,35,4685,Brunswick,22,1479,Brutus,35,4686,Bryan,22,1480,Buchanan,35,4687,Buchtel,35,4688,Buckeye Lake,35,4689,Buckland,22,3910,Buckley,35,4690,Bucyrus,35,4691,Buford,35,4692,Burbank,35,4693,Burghill,35,4694,Burgoon,22,1481,Burlington,22,3911,Burnips,22,3912,Burr Oak,22,3913,Burt,22,3914,Burt Lake,22,3915,Burtchville,22,1482,Burton,35,4695,Burton,35,4696,Butler,35,4697,Byesville,22,3916,Byron,22,3917,Byron Center,35,4698,Cable,22,1483,Cadillac,35,4699,Cadiz,35,4700,Cairo,35,4701,Caldwell,35,4702,Caledonia,22,3918,Caledonia,22,3919,Calumet,35,4703,Cambridge,22,3920,Camden,35,4704,Camden,35,4705,Camp Dennison,35,4706,Campbell,35,4707,Canal Fulton,35,4708,Canal Winchester,35,4709,Canfield,35,4710,Canton,22,3921,Canton,22,3922,Capac,35,4711,Cardington,35,4712,Carey,22,3923,Carleton,35,4713,Carlisle,22,3924,Carney,22,3925,Caro,22,3926,Carp Lake,35,4714,Carroll,35,4715,Carrollton,22,3927,Carrollton,22,3928,Carson City,22,3929,Carsonville,22,3930,Casco,22,3931,Caseville,22,3932,Casnovia,22,3933,Caspian,22,3934,Cass City,22,3935,Cassopolis,35,4716,Casstown,35,4717,Castalia,35,4718,Catawba,22,3936,Cedar,22,3937,Cedar Lake,22,1485,Cedar Springs,22,3938,Cedarville,35,4719,Cedarville,35,4720,Celina,22,3939,Cement City,22,3940,Center Line,35,4721,Centerburg,35,4722,Centerville,22,3941,Central Lake,22,3942,Centreville,22,1487,Ceresco,35,4723,Chagrin Falls,22,3943,Champion,35,4724,Chandlersville,22,3944,Channing,35,4725,Chardon,22,3945,Charlevoix,22,3946,Charlotte,22,3947,Chase,22,3948,Chassell,35,4726,Chatfield,22,3949,Chatham,35,4727,Chauncey,22,1488,Cheboygan,22,1490,Chelsea,35,4728,Cherry Fork,22,3950,Chesaning,35,4729,Chesapeake,35,4730,Cheshire,35,4731,Chester,22,3951,Chesterfield,35,4732,Chesterhill,35,4733,Chesterland,35,4734,Chesterville,35,4735,Chickasaw,35,4736,Chillicothe,22,3952,China,35,4737,Chippewa Lake,22,3953,Chippewa Lake,35,4738,Christiansburg,35,4739,Cincinnati,35,4740,Circleville,22,3954,Clare,35,4741,Clarington,22,3955,Clarklake,35,4742,Clarksburg,22,3956,Clarkston,35,4743,Clarksville,22,3957,Clarksville,22,3958,Clawson,22,3959,Clayton,35,4744,Clayton,35,4745,Cleveland,35,4746,Cleveland Hts,35,4747,Cleves,22,3960,Clifford,22,3961,Climax,35,4748,Clinton,22,3962,Clinton,22,3963,Clinton Twp,22,1491,Clio,35,4749,Cloverdale,35,4750,Clyde,22,3964,Clyde,35,4751,Coal Grove,35,4752,Coalton,22,3965,Cohoctah,35,4753,Coldwater,22,1492,Coldwater,22,3966,Coleman,35,4754,Colerain,35,4755,College Corner,35,4756,Collins,22,1493,Coloma,22,3967,Colon,35,4757,Columbia Station,35,4758,Columbiana,22,3968,Columbiaville,22,3969,Columbus,35,4759,Columbus,35,4760,Columbus Grove,22,3970,Comins,22,3971,Commerce Twp,22,3972,Comstock,22,3973,Comstock Park,22,3974,Concord,35,4761,Conesville,22,3975,Conklin,35,4762,Conneaut,35,4763,Conover,22,3976,Constantine,35,4764,Continental,35,4765,Convoy,22,3977,Cooks,35,4766,Coolville,22,3978,Coopersville,22,3979,Copemish,35,4767,Copley,22,3980,Coral,22,1495,Cornell,35,4768,Corning,35,4769,Cortland,22,3981,Corunna,35,4770,Coshocton,22,3982,Cottrellville,22,3983,Covert,22,3984,Covington,35,4771,Covington,35,4772,Crestline,35,4773,Creston,35,4774,Cridersville,35,4775,Crooksville,22,3985,Croswell,35,4776,Croton,35,4777,Crown City,22,3986,Crystal,22,3987,Crystal Falls,35,4778,Cumberland,35,4779,Curtice,22,3988,Curtis,35,4780,Custar,22,3989,Custer,35,4781,Cutler,35,4782,Cuyahoga Falls,35,4783,Cynthiana,22,3990,Daggett,35,4784,Dalton,35,4785,Damascus,22,3991,Dansville,35,4786,Danville,22,3992,Davisburg,22,1496,Davison,35,4787,Dayton,35,4788,De Graff,22,3993,De Tour Village,22,1498,Dearborn,22,3994,Dearborn Heights,22,3995,Decatur,22,3996,Decker,22,3997,Deckerville,35,4789,Deerfield,22,1499,Deerfield,35,4790,Deersville,35,4791,Defiance,22,3998,Deford,35,4792,Delaware,35,4793,Dellroy,35,4794,Delphos,35,4795,Delta,22,3999,Delton,35,4796,Dennison,35,4797,Derby,35,4798,Deshler,22,1502,Detroit,22,4000,Dewitt,22,1503,Dexter,35,4799,Diamond,35,4800,Dillonvale,22,4001,Dimondale,35,4801,Dola,22,4002,Dollar Bay,35,4802,Donnelsville,22,4003,Dorr,35,4803,Dorset,22,4004,Douglas,35,4804,Dover,22,4005,Dowagiac,22,4006,Dowling,35,4805,Doylestown,35,4806,Dresden,22,4007,Drummond Island,22,4008,Dryden,35,4807,Dublin,35,4808,Duncan Falls,22,4009,Dundee,35,4809,Dundee,35,4810,Dunkirk,35,4811,Dupont,22,4010,Durand,22,4011,Dutton,22,4012,Eagle,35,4812,East Canton,22,4013,East China,35,4813,East Claridon,35,4814,East Cleveland,35,4815,East Fultonham,22,4014,East Jordan,22,4015,East Lansing,22,4016,East Leroy,35,4816,East Liberty,35,4817,East Liverpool,35,4818,East Palestine,35,4819,East Rochester,35,4820,East Sparta,22,4017,East Tawas,22,4018,Eastpointe,22,4019,Eastport,35,4821,Eaton,22,4020,Eaton Rapids,22,4021,Eau Claire,22,4022,Eben Junction,22,4023,Eckerman,22,4024,Ecorse,22,4025,Edenville,35,4822,Edgerton,35,4823,Edison,22,4026,Edmore,35,4824,Edon,22,4027,Edwardsburg,22,4028,Elberta,35,4825,Eldorado,35,4826,Elida,22,4029,Elk Rapids,22,4030,Elkton,35,4827,Elliston,22,4031,Ellsworth,22,4032,Elmira,35,4828,Elmore,22,4033,Elsie,22,4034,Elwell,35,4829,Elyria,22,4037,Emmett,22,4038,Empire,22,4036,Engadine,35,4830,Englewood,35,4831,Enon,22,4035,Erie,22,1509,Escanaba,22,1510,Essexville,35,4832,Etna,35,4833,Euclid,22,4039,Eureka,35,4834,Evansport,22,4040,Evart,22,4041,Ewen,35,4835,Fairborn,35,4836,Fairfield,22,4042,Fairgrove,35,4837,Fairlawn,35,4838,Fairpoint,35,4839,Fairport Harbor,22,4043,Fairview,22,4044,Falmouth,35,4840,Farmdale,35,4841,Farmersville,22,4045,Farmington,22,4046,Farmington Hills,22,4047,Farwell,35,4842,Fayette,35,4843,Fayetteville,22,4048,Felch,35,4844,Felicity,22,4049,Fennville,22,1512,Fenton,22,1513,Ferndale,22,1514,Fife Lake,22,4050,Filion,35,4845,Findlay,35,4846,Flat Rock,22,4051,Flat Rock,35,4847,Fletcher,22,1516,Flint,35,4848,Flushing,22,1517,Flushing,35,4849,Forest,22,4052,Fort Gratiot,35,4850,Fort Jennings,35,4851,Fort Loramie,35,4852,Fort Recovery,22,4053,Foster City,35,4853,Fostoria,22,4054,Fostoria,22,4055,Fountain,22,4056,Fowler,35,4854,Fowler,22,1520,Fowlerville,22,4057,Frankenmuth,35,4855,Frankfort,22,4058,Frankfort,35,4856,Franklin,22,4059,Franklin,35,4857,Franklin Furnace,22,1521,Fraser,35,4858,Frazeysburg,22,4060,Frederic,35,4859,Fredericksburg,35,4860,Fredericktown,22,4061,Free Soil,22,4062,Freeland,35,4861,Freeport,22,4063,Freeport,22,4064,Fremont,35,4862,Fremont,35,4863,Fresno,35,4864,Friendship,22,4065,Fruitport,35,4865,Fulton,22,4066,Fulton,35,4866,Fultonham,22,4067,Gaastra,22,4068,Gagetown,35,4867,Gahanna,22,4069,Gaines,35,4868,Galena,22,4070,Galesburg,22,1522,Galien,35,4869,Galion,35,4870,Gallipolis,35,4871,Galloway,35,4872,Gambier,22,1523,Garden,22,4071,Garden City,35,4873,Garfield Heights,35,4874,Garrettsville,35,4875,Gates Mills,22,4072,Gaylord,22,1525,Genesee,35,4876,Geneva,35,4877,Genoa,35,4878,Georgetown,35,4879,Germantown,22,4074,Germfask,35,4880,Gibsonburg,35,4881,Girard,22,1526,Gladstone,22,4075,Gladwin,35,4882,Glandorf,22,4076,Glen Arbor,35,4883,Glendale,35,4884,Glenford,35,4885,Glenmont,22,4077,Glenn,22,4078,Glennie,35,4886,Glouster,35,4887,Gnadenhutten,22,4079,Gobles,22,4080,Goetzville,35,4888,Gomer,22,4081,Goodells,22,4082,Goodrich,35,4889,Gordon,35,4890,Goshen,22,4083,Gould City,22,4084,Gowen,35,4891,Grafton,22,4085,Grand Beach,22,1527,Grand Blanc,22,4086,Grand Haven,22,4087,Grand Junction,22,4088,Grand Ledge,22,4089,Grand Marais,22,1528,Grand Rapids,35,4892,Grand Rapids,22,4090,Grandville,22,4091,Grant,22,4092,Grant Twp,35,4893,Granville,22,4093,Grass Lake,35,4894,Gratiot,35,4895,Gratis,22,4094,Grawn,22,4095,Grayling,35,4896,Graysville,35,4897,Graytown,35,4898,Green,35,4899,Green Camp,35,4900,Green Springs,22,4096,Greenbush,35,4901,Greenfield,22,4097,Greenland,35,4902,Greentown,22,4098,Greenville,35,4903,Greenville,35,4904,Greenwich,22,4099,Greenwood,22,4100,Gregory,22,1532,Grosse Ile,22,1533,Grosse Point,22,4103,Grosse Pte Farms,22,4104,Grosse Pte Park,22,4105,Grosse Pte Woods,35,4905,Grove City,35,4906,Groveport,35,4907,Grover Hill,22,4106,Gwinn,22,4107,Hadley,22,4108,Hale,22,1534,Hamburg,35,4908,Hamden,35,4909,Hamersville,22,4110,Hamilton,35,4910,Hamilton,35,4911,Hamler,22,4111,Hamtramck,22,4112,Hancock,35,4912,Hannibal,22,4113,Hanover,35,4913,Hanoverton,22,4114,Harbert,22,4115,Harbor Beach,22,4116,Harbor Springs,22,4117,Harper Woods,35,4914,Harpster,22,4118,Harrietta,22,4119,Harrison,35,4915,Harrison,22,4120,Harrison Twp,22,4121,Harrisville,35,4916,Harrisville,35,4917,Harrod,22,4122,Harsens Island,22,4123,Hart,35,4918,Hartford,22,4124,Hartford,22,1537,Hartland,35,4919,Hartville,22,4125,Harvey,35,4920,Harveysburg,35,4921,Haskins,22,4126,Haslett,22,1538,Hastings,35,4922,Haviland,35,4923,Hayesville,22,4127,Hazel Park,35,4924,Heath,35,4925,Hebron,22,4128,Hemlock,22,4129,Henderson,22,4130,Herron,22,4131,Hersey,22,4132,Hesperia,22,4133,Hessel,22,4134,Hickory Corners,35,4926,Hicksville,22,4135,Higgins Lake,35,4927,Highland,22,4136,Highland,22,4137,Highland Park,35,4928,Hilliard,22,4138,Hillman,35,4929,Hillsboro,22,1539,Hillsdale,35,4930,Hinckley,35,4931,Hiram,35,4932,Hockingport,35,4933,Holgate,35,4934,Holland,22,1540,Holland,35,4935,Hollansburg,35,4936,Holloway,22,1541,Holly,35,4937,Holmesville,22,4139,Holt,22,4140,Holton,35,4938,Homer,22,1542,Homer,35,4939,Homerville,35,4940,Homeworth,22,4145,Honor,22,4144,Hope,35,4941,Hopedale,35,4942,Hopewell,22,4143,Hopkins,22,4142,Horton,22,1543,Houghton,22,4141,Houghton Lake,35,4943,Houston,35,4944,Howard,22,1544,Howard City,22,1545,Howell,35,4945,Hoytville,35,4946,Hubbard,22,4146,Hubbard Lake,22,4147,Hubbardston,22,4148,Hubbell,35,4947,Huber Heights,22,4149,Hudson,35,4948,Hudson,22,4150,Hudsonville,22,4151,Hulbert,22,4152,Huntington Woods,35,4949,Huntsburg,35,4950,Huntsville,35,4951,Huron,35,4952,Iberia,22,4153,Ida,22,4154,Idlewild,22,4155,Imlay City,22,1547,Indian River,35,4953,Indian Springs,22,4156,Inkster,22,4157,Interlochen,22,1548,Ionia,22,4158,Ira,22,4159,Iron Mountain,22,4160,Iron River,35,4954,Irondale,22,4161,Irons,35,4955,Ironton,22,1549,Ironwood,35,4956,Irwin,22,4162,Ishpeming,22,1551,Ithaca,35,4957,Jackson,22,1552,Jackson,35,4958,Jackson Center,35,4959,Jacksontown,35,4960,Jacksonville,35,4961,Jacobsburg,22,4163,Jamestown,35,4962,Jamestown,22,4164,Jasper,35,4963,Jefferson,35,4964,Jeffersonville,35,4965,Jenera,22,4165,Jenison,22,4166,Jerome,35,4966,Jeromesville,35,4967,Jerusalem,35,4968,Jewett,22,4167,Johannesburg,35,4969,Johnstown,22,4169,Jones,22,4168,Jonesville,35,4970,Junction City,22,1553,Kalamazoo,22,4170,Kaleva,35,4971,Kalida,22,1554,Kalkaska,35,4972,Kansas,22,4171,Kawkawlin,35,4973,Kelleys Island,22,4172,Kendall,35,4974,Kensington,35,4975,Kent,22,4173,Kent City,35,4976,Kenton,22,4174,Kentwood,35,4977,Kettering,35,4978,Kettlersville,22,4175,Kewadin,35,4979,Kidron,35,4980,Kilbourne,35,4981,Killbuck,22,4176,Kimball,35,4982,Kimbolton,22,4177,Kincheloe,22,4178,Kinde,35,4983,Kings Mills,22,4179,Kingsford,22,4180,Kingsley,22,4181,Kingston,35,4984,Kingston,35,4985,Kingsville,22,4182,Kinross,35,4986,Kinsman,35,4987,Kipton,35,4988,Kirkersville,35,4989,Kirtland,35,4990,Kitts Hill,35,4991,Kunkle,35,4992,La Rue,22,4183,La Salle,22,4184,Lachine,22,4185,Lacota,35,4993,Lafayette,35,4994,Lafferty,35,4995,Lagrange,22,4186,Laingsburg,22,4187,Lake,22,4188,Lake Ann,22,4189,Lake City,22,4190,Lake George,22,4191,Lake Leelanau,22,4192,Lake Linden,35,4996,Lake Milton,22,4193,Lake Odessa,22,4194,Lake Orion,22,4195,Lakeport,22,4196,Lakeside,35,4997,Lakeside Marblhd,22,4197,Lakeview,35,4998,Lakeview,35,4999,Lakeville,35,5000,Lakewood,22,4198,Lambertville,35,5001,Lancaster,35,5002,Langsville,22,4199,Lanse,22,1560,Lansing,35,5003,Lansing,22,4200,Lapeer,35,5004,Latham,22,1561,Lathrup Village,35,5005,Laura,35,5006,Laurelville,22,4201,Laurium,22,4202,Lawrence,22,4203,Lawton,35,5007,Leavittsburg,35,5008,Lebanon,35,5009,Leesburg,35,5010,Leesville,35,5011,Leetonia,35,5012,Leipsic,22,4204,Leland,35,5013,Lemoyne,22,4205,Lennon,22,4206,Lenox,22,4207,Leonard,22,4208,Leroy,22,4209,Leslie,22,1562,Levering,35,5014,Lewis Center,35,5015,Lewisburg,22,4210,Lewiston,35,5016,Lewistown,35,5017,Lewisville,35,5018,Lexington,22,4211,Lexington,35,5019,Liberty Center,35,5020,Liberty Twp,35,5021,Lima,22,4213,Limestone,22,4212,Lincoln,22,1563,Lincoln Park,22,1564,Linden,35,5022,Lindsey,22,4214,Linwood,35,5023,Lisbon,22,4215,Litchfield,35,5024,Litchfield,35,5025,Lithopolis,35,5026,Little Hocking,22,4216,Little Lake,22,4217,Livonia,35,5027,Lockbourne,35,5028,Lodi,35,5029,Logan,35,5030,London,35,5031,Londonderry,35,5032,Long Bottom,35,5033,Lorain,35,5034,Lore City,35,5035,Loudonville,35,5036,Louisville,35,5037,Loveland,35,5038,Lowell,22,4218,Lowell,35,5039,Lowellville,35,5040,Lower Salem,35,5041,Lucas,35,5042,Lucasville,35,5043,Luckey,22,1566,Ludington,35,5044,Ludlow Falls,22,4219,Luna Pier,22,4220,Lupton,22,4221,Luther,22,4222,Luzerne,35,5045,Lynchburg,35,5046,Lyons,35,5047,Macedonia,22,1568,Mackinac Island,22,4224,Mackinaw City,35,5048,Macksburg,22,4225,Macomb,35,5049,Madison,22,4226,Madison Heights,35,5050,Magnetic Springs,35,5051,Magnolia,35,5052,Maineville,35,5053,Malinta,35,5054,Malta,35,5055,Malvern,22,4227,Mancelona,35,5056,Manchester,22,1569,Manchester,22,4229,Manistee,22,4230,Manistique,22,4231,Manitou Beach,35,5057,Mansfield,22,4232,Manton,35,5058,Mantua,22,4233,Maple City,35,5059,Maple Heights,22,4234,Maple Rapids,35,5060,Maplewood,22,4235,Marcellus,35,5061,Marengo,22,4236,Marenisco,35,5062,Maria Stein,35,5063,Marietta,22,4237,Marine City,35,5064,Marion,22,4238,Marion,35,5065,Mark Center,22,4239,Marlette,22,4240,Marne,22,1573,Marquette,22,4242,Marshall,35,5066,Marshallville,35,5067,Martin,22,4243,Martin,35,5068,Martins Ferry,35,5069,Martinsburg,35,5070,Marysville,22,4244,Marysville,35,5071,Mason,22,4245,Mason,22,4246,Mass City,35,5072,Massillon,35,5073,Masury,22,4247,Mattawan,35,5074,Maumee,22,4248,Maybee,22,4249,Mayville,35,5075,Mc Arthur,22,4250,Mc Bain,35,5076,Mc Clure,35,5077,Mc Comb,35,5078,Mc Cutchenville,35,5079,Mc Dermott,35,5080,Mc Donald,35,5081,Mc Guffey,22,4251,Mc Millan,35,5082,Mcconnelsville,22,4252,Mears,35,5083,Mechanicsburg,35,5084,Mechanicstown,22,4253,Mecosta,35,5085,Medina,35,5086,Medway,35,5087,Melrose,22,4254,Melvin,22,4255,Melvindale,22,4256,Memphis,35,5088,Mendon,22,4257,Mendon,22,1577,Menominee,35,5089,Mentor,35,5090,Mentor On Lake,22,4259,Merrill,22,4264,Merritt,22,4260,Mesick,35,5091,Mesopotamia,35,5092,Metamora,22,4261,Metamora,35,5093,Miamisburg,35,5094,Miamitown,22,4262,Michigamme,22,1578,Michigan Center,35,5095,Middle Point,35,5096,Middlebranch,35,5097,Middleburg,35,5098,Middlefield,35,5099,Middleport,22,4265,Middleton,35,5100,Middletown,22,4266,Middleville,35,5101,Midland,22,4267,Midland,35,5102,Midvale,22,4268,Mikado,22,4269,Milan,35,5103,Milan,35,5104,Milford,22,4270,Milford,35,5105,Milford Center,35,5106,Millbury,35,5107,Miller City,22,4271,Millersburg,35,5108,Millersburg,35,5109,Millersport,35,5110,Millfield,22,4272,Millington,22,4273,Minden City,35,5111,Mineral City,35,5112,Mineral Ridge,35,5113,Minerva,35,5114,Minford,35,5115,Mingo Junction,35,5116,Minster,22,4274,Mio,35,5117,Mogadore,22,4275,Mohawk,22,4276,Moline,35,5118,Monclova,35,5119,Monroe,22,4277,Monroe,35,5120,Monroeville,22,4278,Montague,35,5121,Montezuma,22,4279,Montgomery,35,5122,Montgomery,35,5123,Montpelier,22,4280,Montrose,35,5124,Montville,35,5125,Moraine,22,4281,Moran,22,4282,Morenci,22,4283,Morley,35,5126,Morral,22,4284,Morrice,35,5127,Morrow,35,5128,Moscow,35,5129,Mowrystown,35,5130,Moxahala,35,5131,Mt Blanchard,22,4285,Mt Clemens,35,5132,Mt Eaton,35,5133,Mt Gilead,35,5134,Mt Healthy,35,5135,Mt Hope,35,5136,Mt Liberty,22,4286,Mt Morris,35,5137,Mt Orab,35,5138,Mt Perry,35,5139,Mt Pleasant,22,4287,Mt Pleasant,35,5140,Mt Sterling,35,5141,Mt Vernon,35,5142,Mt Victory,22,4288,Muir,22,4289,Mulliken,22,4290,Munger,22,4291,Munising,22,4292,Munith,35,5143,Munroe Falls,22,1583,Muskegon,22,4294,Muskegon Heights,22,4295,Mussey,22,4296,Nadeau,35,5144,Nankin,35,5145,Napoleon,22,4297,Napoleon,35,5146,Nashport,22,1585,Nashville,35,5147,Nashville,22,4299,Naubinway,35,5148,Navarre,35,5149,Neapolis,35,5150,Neffs,22,4300,Negaunee,35,5151,Nelsonville,35,5152,Nevada,35,5153,New Albany,35,5154,New Athens,22,4301,New Baltimore,35,5155,New Bavaria,35,5156,New Bloomington,35,5157,New Boston,22,4302,New Boston,35,5158,New Bremen,22,1586,New Buffalo,35,5159,New Carlisle,35,5160,New Concord,22,4304,New Era,35,5161,New Hampshire,22,4305,New Haven,35,5162,New Haven,35,5163,New Holland,22,4306,New Hudson,35,5164,New Knoxville,35,5165,New Lebanon,35,5166,New Lexington,35,5167,New London,22,4307,New Lothrop,35,5168,New Madison,35,5169,New Marshfield,35,5170,New Matamoras,35,5171,New Middletown,35,5172,New Paris,35,5173,New Philadelphia,35,5174,New Richmond,35,5175,New Riegel,35,5176,New Springfield,35,5177,New Straitsville,22,1587,New Troy,35,5178,New Vienna,35,5179,New Washington,35,5180,New Waterford,35,5181,Newark,22,4309,Newaygo,22,4310,Newberry,35,5182,Newburgh Heights,35,5183,Newbury,35,5184,Newcomerstown,35,5185,Newport,22,4311,Newport,35,5186,Newton Falls,35,5187,Ney,35,5188,Niles,22,4312,Niles,22,4313,North Adams,35,5189,North Baltimore,35,5190,North Bend,35,5191,North Benton,35,5192,North Bloomfield,22,4314,North Branch,35,5193,North Canton,35,5194,North Fairfield,35,5195,North Georgetown,35,5196,North Hampton,35,5197,North Jackson,35,5198,North Kingsville,35,5199,North Lawrence,35,5200,North Lewisburg,35,5201,North Lima,22,4315,North Muskegon,35,5202,North Olmsted,35,5203,North Ridgeville,35,5204,North Robinson,35,5205,North Royalton,35,5206,North Star,35,5207,Northfield,22,4316,Northport,22,1589,Northville,35,5208,Northwood,35,5209,Norton,22,4318,Norton Shores,35,5210,Norwalk,22,4319,Norway,35,5211,Norwich,22,4320,Nottawa,35,5212,Nova,35,5213,Novelty,22,4321,Novi,22,4322,Nunica,35,5214,Oak Harbor,35,5215,Oak Hill,22,4323,Oak Park,22,4324,Oakland,22,4325,Oakley,35,5216,Oakwood,35,5217,Oberlin,35,5218,Obetz,35,5219,Ohio City,22,4326,Okemos,35,5220,Old Fort,22,4327,Old Mission,35,5221,Old Washington,22,4328,Olivet,35,5222,Olmsted Falls,22,4339,Onaway,22,4340,Onekama,22,4341,Onondaga,22,4342,Onsted,35,5223,Ontario,22,4343,Ontonagon,22,1593,Orchard Lake,35,5224,Oregon,35,5225,Oregonia,35,5226,Orient,22,4344,Orion,22,4345,Orleans,35,5227,Orrville,22,4346,Ortonville,35,5228,Orwell,22,4347,Oscoda,35,5229,Osgood,22,4348,Osseo,22,4349,Ossineke,35,5230,Ostrander,22,4350,Otisville,22,4351,Otsego,35,5231,Ottawa,35,5232,Ottawa Hills,22,4352,Ottawa Lake,22,4353,Otter Lake,35,5233,Ottoville,35,5234,Otway,35,5235,Overpeck,22,4354,Ovid,22,4355,Owendale,22,1595,Owosso,22,4356,Oxford,35,5236,Oxford,22,4357,Painesdale,35,5237,Painesville,35,5238,Palestine,22,4358,Palms,22,4359,Palmyra,22,4360,Palo,35,5239,Pandora,22,4361,Paradise,22,4362,Parchment,35,5240,Paris,22,4363,Paris,35,5241,Parkman,35,5242,Parma,22,4364,Parma,35,5243,Pataskala,35,5244,Patriot,35,5245,Paulding,22,4365,Paw Paw,35,5246,Payne,22,4366,Peck,35,5247,Pedro,35,5248,Peebles,22,4367,Pelkie,22,1597,Pellston,35,5249,Pemberton,35,5250,Pemberville,35,5251,Peninsula,22,4368,Pentwater,22,1598,Perkins,22,4369,Perrinton,35,5252,Perry,22,4370,Perry,35,5253,Perrysburg,35,5254,Perrysville,35,5255,Petersburg,22,4371,Petersburg,22,1599,Petoskey,35,5256,Pettisville,35,5257,Phillipsburg,35,5258,Philo,35,5259,Pickerington,22,4372,Pickford,35,5260,Pierpont,22,4373,Pierson,22,4374,Pigeon,35,5261,Piketon,22,1601,Pinckney,22,4375,Pinconning,35,5262,Pioneer,35,5263,Piqua,35,5264,Pitsburg,22,4376,Pittsford,35,5265,Plain City,22,4377,Plainwell,35,5266,Pleasant City,35,5267,Pleasant Hill,22,4378,Pleasant Lake,35,5268,Pleasant Plain,22,4379,Pleasant Ridge,35,5269,Pleasantville,35,5270,Plymouth,22,4380,Plymouth,35,5271,Poland,35,5272,Polk,35,5273,Pomeroy,22,4381,Pompeii,22,1604,Pontiac,22,4382,Port Austin,35,5274,Port Clinton,22,4383,Port Hope,22,4384,Port Huron,22,4385,Port Sanilac,35,5275,Port Washington,35,5276,Port William,35,5277,Portage,22,4386,Portage,22,4387,Portland,35,5278,Portsmouth,22,4388,Posen,35,5279,Potsdam,22,4389,Potterville,35,5280,Powell,22,4390,Powers,35,5281,Powhatan Point,22,4391,Prescott,22,4392,Presque Isle,35,5282,Proctorville,35,5283,Prospect,22,4393,Prudenville,22,4394,Pullman,35,5284,Put In Bay,35,5285,Quaker City,35,5286,Quincy,22,1607,Quincy,22,4395,Quinnesec,35,5287,Racine,35,5288,Radnor,22,4396,Ramsay,22,4397,Rapid City,22,1609,Rapid River,22,4399,Ravenna,35,5289,Ravenna,35,5290,Rawson,22,4400,Ray,35,5291,Rayland,35,5292,Raymond,22,4401,Reading,22,4402,Redford,22,1610,Reed City,35,5293,Reedsville,22,4404,Reese,22,4405,Remus,35,5294,Reno,22,4406,Republic,35,5295,Republic,35,5296,Reynoldsburg,22,4407,Rhodes,35,5297,Richfield,22,4408,Richland,22,4409,Richmond,35,5298,Richmond,35,5299,Richmond Dale,35,5300,Richwood,35,5301,Ridgeville Cors,35,5302,Ridgeway,22,4410,Riga,22,4411,Riley,35,5303,Rio Grande,35,5304,Ripley,35,5305,Risingsun,35,5306,Rittman,22,4412,River Rouge,22,4413,Riverdale,22,4414,Riverview,22,4415,Rives Junction,35,5307,Robertsville,22,4416,Rochester,22,4417,Rochester Hills,35,5308,Rock Creek,35,5309,Rockbridge,22,1613,Rockford,35,5310,Rockford,22,1612,Rockland,22,4419,Rockwood,22,4420,Rodney,35,5311,Rogers,22,4421,Rogers City,22,4422,Rollin,35,5312,Rome,22,4423,Romeo,22,4424,Romulus,35,5313,Rootstown,22,4425,Roscommon,22,4426,Rose City,22,4427,Rosebush,22,1614,Roseville,35,5314,Roseville,35,5315,Rosewood,35,5316,Rossburg,35,5317,Rossford,22,4429,Rothbury,22,1615,Royal Oak,22,4431,Ruby,35,5318,Rudolph,22,4432,Rudyard,35,5319,Rushsylvania,35,5320,Rushville,35,5321,Russells Point,35,5322,Russellville,35,5323,Russia,22,4433,Ruth,35,5324,Rutland,35,5325,S Bloomingville,35,5326,Sabina,22,1616,Saginaw,35,5327,Salem,35,5328,Salesville,22,1618,Saline,35,5329,Salineville,22,4436,Samaria,22,4437,Sand Creek,22,4438,Sand Lake,22,4439,Sandusky,35,5330,Sandusky,35,5331,Sandyville,22,4440,Sanford,35,5332,Sarahsville,22,4441,Saranac,35,5333,Sardinia,35,5334,Sardis,22,4442,Saugatuck,22,1620,Sault Ste Marie,35,5335,Savannah,22,4444,Sawyer,22,4445,Schoolcraft,35,5336,Scio,35,5337,Scott,22,4446,Scotts,22,4447,Scottville,35,5338,Seaman,22,4448,Sears,22,4449,Sebewaing,35,5339,Sebring,35,5340,Sedalia,35,5341,Senecaville,35,5342,Seven Hills,35,5343,Seville,35,5344,Shadyside,22,4450,Shaftsburg,35,5345,Shaker Heights,35,5346,Shandon,35,5347,Sharon Center,35,5348,Shauck,35,5349,Shawnee,35,5350,Sheffield Lake,35,5351,Sheffield Vlg,22,4451,Shelby,35,5352,Shelby,22,4452,Shelby Twp,22,4453,Shelbyville,22,4454,Shepherd,22,4455,Sheridan,35,5353,Sherrodsville,22,4456,Sherwood,35,5354,Sherwood,35,5355,Shiloh,22,4457,Shingleton,35,5356,Shreve,22,4458,Sidnaw,35,5357,Sidney,22,4459,Sidney,35,5358,Silver Lake,22,4460,Silverwood,35,5359,Sinking Spring,22,4461,Six Lakes,22,4462,Skandia,22,4463,Skanee,35,5360,Smithfield,22,4464,Smiths Creek,35,5361,Smithville,22,4465,Snover,22,4466,Sodus,35,5362,Somerset,22,4467,Somerset Center,35,5363,Somerton,35,5364,Somerville,35,5365,South Amherst,35,5366,South Bloomfield,22,4468,South Boardman,35,5367,South Charleston,22,4469,South Haven,35,5368,South Lebanon,22,4470,South Lyon,35,5369,South Point,22,4471,South Range,22,4472,South Rockwood,35,5370,South Salem,35,5371,South Solon,35,5372,South Vienna,35,5373,South Webster,22,4473,Southfield,22,4474,Southgate,35,5374,Southington,22,4475,Spalding,22,4476,Sparta,35,5375,Sparta,35,5376,Spencer,35,5377,Spencerville,22,4477,Spring Arbor,22,4478,Spring Lake,35,5378,Spring Valley,35,5379,Springboro,35,5380,Springfield,22,4479,Springfield,22,4480,Springport,22,4481,Spruce,22,4482,St Charles,22,4483,St Clair,22,4484,St Clair Shores,35,5381,St Clairsville,22,4485,St Helen,35,5382,St Henry,22,1624,St Ignace,22,4486,St Johns,22,1625,St Joseph,22,1626,St Louis,35,5383,St Louisville,35,5384,St Marys,35,5385,St Paris,35,5386,Stafford,22,4487,Standish,22,4488,Stanton,22,4489,Stanwood,22,4490,Stephenson,35,5387,Sterling,22,4491,Sterling,35,5388,Steubenville,22,4493,Stevensville,35,5389,Stewart,22,4494,Stockbridge,35,5390,Stockport,35,5391,Stone Creek,35,5392,Stony Ridge,35,5393,Stout,35,5394,Stoutsville,35,5395,Stow,35,5396,Strasburg,35,5397,Stratton,35,5398,Streetsboro,35,5399,Strongsville,35,5400,Struthers,35,5401,Stryker,22,4495,Sturgis,35,5402,Sugar Grove,35,5403,Sugarcreek,35,5404,Sullivan,35,5405,Sulphur Springs,35,5406,Summerfield,35,5407,Summit Station,35,5408,Summitville,22,4496,Sumner,35,5409,Sunbury,22,4497,Sunfield,22,4498,Suttons Bay,35,5410,Swanton,22,1630,Swartz Creek,35,5411,Sycamore,35,5412,Sylvania,35,5413,Syracuse,35,5414,Tallmadge,35,5415,Tarlton,22,4500,Tawas City,22,4501,Taylor,22,4502,Tecumseh,22,1631,Tekonsha,22,4503,Temperance,35,5416,Terrace Park,35,5417,The Plains,35,5418,Thompson,22,4504,Thompsonville,35,5419,Thornville,22,1632,Three Oaks,22,1633,Three Rivers,35,5420,Thurman,35,5421,Thurston,35,5422,Tiffin,35,5423,Tiltonsville,35,5424,Tipp City,35,5425,Tippecanoe,22,4507,Tipton,35,5426,Tiro,22,4508,Toivola,35,5427,Toledo,35,5428,Tontogany,22,4509,Topinabee,35,5429,Toronto,22,1634,Tower,22,1635,Traverse City,35,5430,Tremont City,22,4512,Trenary,35,5431,Trenton,35,5432,Trimble,35,5433,Trotwood,22,4514,Trout Creek,22,3831,Troy,35,5434,Troy,35,5435,Tuppers Plains,22,4515,Turner,35,5436,Tuscarawas,22,4516,Tuscola,22,4517,Tustin,22,4518,Twin Lake,22,4519,Twining,35,5437,Twinsburg,22,4520,Ubly,35,5438,Uhrichsville,35,5439,Union,22,4521,Union,35,5440,Union City,22,1637,Union City,22,4525,Union Pier,35,5441,Uniontown,22,4523,Unionville,35,5442,University Hts,35,5443,Upper Arlington,35,5444,Upper Sandusky,35,5445,Urbana,22,4524,Utica,35,5446,Utica,35,5447,Valley City,35,5448,Van Buren,22,4526,Van Buren Twp,35,5449,Van Wert,35,5450,Vandalia,22,4527,Vandalia,22,4528,Vanderbilt,35,5451,Vanlue,22,4529,Vassar,35,5452,Venedocia,35,5453,Vermilion,22,4530,Vermontville,22,4531,Vernon,35,5454,Verona,35,5455,Versailles,22,4532,Vestaburg,35,5456,Vickery,22,4533,Vicksburg,35,5457,Vienna,35,5458,Vincent,35,5459,Vinton,22,4534,Vulcan,35,5460,Wadsworth,22,4535,Wakefield,35,5461,Wakeman,35,5462,Walbridge,35,5463,Waldo,22,4536,Waldron,22,4537,Wales,22,4538,Walkerville,22,4539,Wallace,22,4540,Walled Lake,22,4544,Walloon Lake,35,5464,Walnut Creek,35,5465,Wapakoneta,35,5466,Warnock,35,5467,Warren,22,4541,Warren,35,5468,Warrensville Hts,35,5469,Warsaw,22,4542,Washington,35,5470,Washington Ct Hs,22,1642,Washington Twp,22,4543,Waterford,35,5471,Waterford,22,4545,Watersmeet,35,5472,Waterville,22,1643,Watervliet,22,4546,Watton,35,5473,Wauseon,35,5474,Waverly,22,4547,Wayland,35,5475,Wayland,22,4548,Wayne,35,5476,Wayne,35,5477,Waynesburg,35,5478,Waynesfield,35,5479,Waynesville,22,4549,Webberville,22,4550,Weidman,35,5480,Wellington,22,4551,Wells,22,4552,Wellston,35,5481,Wellston,35,5482,Wellsville,35,5483,West Alexandria,22,4553,West Bloomfield,22,4554,West Branch,35,5484,West Carrollton,35,5485,West Chester,35,5486,West Elkton,35,5487,West Farmington,35,5488,West Jefferson,35,5489,West Lafayette,35,5490,West Liberty,35,5491,West Manchester,35,5492,West Mansfield,35,5493,West Milton,22,4555,West Olive,35,5494,West Portsmouth,35,5495,West Salem,35,5496,West Union,35,5497,West Unity,35,5498,Westerville,35,5499,Westlake,22,4556,Westland,22,4557,Weston,35,5500,Weston,22,4558,Westphalia,35,5501,Westwood,22,4559,Wetmore,35,5502,Wharton,22,4560,Wheeler,35,5503,Wheelersburg,35,5504,Whipple,22,4561,White Cloud,35,5505,White Cottage,22,4562,White Lake,22,4563,White Pigeon,22,4564,White Pine,35,5506,Whitehall,22,4565,Whitehall,35,5507,Whitehouse,22,1649,Whitmore Lake,22,1650,Whittaker,22,4566,Whittemore,35,5508,Wickliffe,35,5509,Willard,35,5510,Williamsburg,22,4567,Williamsburg,35,5511,Williamsport,22,4568,Williamston,35,5512,Williamstown,22,1652,Willis,35,5513,Williston,35,5514,Willoughby,35,5515,Willoughby Hills,35,5516,Willowick,35,5517,Willshire,35,5518,Wilmington,35,5519,Wilmot,35,5520,Winchester,35,5521,Windham,35,5522,Windsor,35,5523,Winesburg,35,5524,Wingett Run,35,5525,Winona,35,5526,Wintersville,22,1653,Wolverine,35,5527,Woodsfield,35,5528,Woodville,35,5529,Wooster,35,5530,Worthington,22,1655,Wyandotte,35,5531,Wyoming,22,4576,Wyoming,35,5532,Xenia,22,4577,Yale,35,5533,Yellow Springs,35,5534,Yorkshire,35,5535,Yorkville,35,5536,Youngstown,22,1657,Ypsilanti,35,5537,Zaleski,35,5538,Zanesfield,35,5539,Zanesville,22,4579,Zeeland,35,5540,Zoar,35,5541,Zoarville';
  var selboxCity = document.FRMAcc.GetCity;
  var CTDataListCity = getmyCityList.split(",");
  //selboxCity.style.visibility = "visible";
  //document.FRMAcc.TxtCity.style.visibility = "visible";
  //selboxCity.options.length = 0;
  var opt=document.FRMAcc.GetCity.options;
  opt.length=0;
  if(chosen){
    for(var i=0; i<CTDataListCity.length; i+=3) {
   	  if (chosen == CTDataListCity[i]) {
  		opt[opt.length] = new Option(CTDataListCity[i+2],CTDataListCity[i+1]);
   	  }
    }
  } else {
    opt[0] = new Option('Select please The State..',' ');
  }
}

setOptionCity();
</script>

Open in new window

0
 
lulu50Author Commented:
Zvonko

by having this at the end

setOptionCity();

it means it is going to execute the function without the onclick event but I want it to only execute the function if the user selected a state.

I want the city to be hidden when the user come to the site and when they select a state it will become available for them to select.

Thank you
0
 
lulu50Author Commented:
I don't want it to populate data to the city unless the user selected a state.

I have a lots of data it will take for ever to upload.
0
 
lulu50Author Commented:
I looked at the view source and I see the data got populated
how can I have it not to populate the data and be hidden unless the user select from the state?
0
 
lulu50Author Commented:
Great!!!!
I did this
<cfif isdefined("form.DispStateBox")>
now I don't have the data populated unless the user select from the state.

now the only issue is that I needed the city to be hidden unless the user select on the state.
0
 
ZvonkoSystems architectCommented:
Simply do this:
setOptionCity();

Open in new window

0
 
lulu50Author Commented:
Zvonko

I don't understand?
0
 
lulu50Author Commented:
do you mean just to call the function
0
 
lulu50Author Commented:
Zvonko

Great!!

it works!!!!

Thank you and Thank you for your help
0
 
lulu50Author Commented:
Thank you
0
 
ZvonkoSystems architectCommented:
You are velcome, but you did it by the "visibility" trick <|:-)
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now