I’m creating a number of data entry forms that will frontend my website. All of the forms include city/county/state/country elements. I’d like to constrain values for state and country to those values published by the USPS. I haven’t tried to do that for countries (it’s a long list) but I have incorporated the state list in <option>
tag pairs that I used with <select>
tag pairs. This is cluttering my code. Adding country lists will add hundreds of lines of code for each instance across several forms.
Is there a way to create a list external to the inline code and link to it from HTML? I’m thinking something along the lines of using link . . .
to put CSS in a separate file or files.
I remember reading that there are 2 ways to present users with the means of choosing data. One used the <select>
tags but I cannot remember the other HTML keyword and cannot find it searching. The other method presents the entry panel and uses something like type-ahead as users type, presenting values from a programmed list. This is the technique I’d like to use for the names of countries, but cannot find the keyword I need.
Thanks for any help.