I fixed something, just forget what it was

This commit is contained in:
jengo 2001-07-01 22:49:51 +00:00
parent c577eb203b
commit 4152c9f4b9

View File

@ -544,7 +544,8 @@
function list_states($name, $selected = '')
{
$states = array(
'' => 'non US',
'' => lang('Select one'),
'--' => 'non US',
'AL' => 'Alabama',
'AK' => 'Alaska',
'AZ' => 'Arizona',
@ -599,7 +600,12 @@
while (list($sn,$ln) = each($states))
{
$s .= '<option value="' . $sn . '">' . $ln . '</option>';
$s .= '<option value="' . $sn . '"';
if ($selected == $sn)
{
$s .= ' selected';
}
$s .= '>' . $ln . '</option>';
}
return '<select name="' . $name . '">' . $s . '</select>';
}