Eh. What browser are you using if that's your experience? The code I posted generates (at least in my IE 6.0) a dropdown, containing 01-31, with the selected item shown, but not at the top. if I unfold it (click the litte arrow-thingie), the list is shown from 01-31 and the selected item is where it's supposed to be, between selected-1 and selected+1.
The difference between my code and yours btw is quite obvious:
Before the for-loop you add an <option>-tag:
$day_select = "<select size=\"1\" name=\"day\"><option value=\"$_POST[day]\">$_POST[day]</option>";
// ^^^^^ here it is
containing the selected value, but it's not selected, the selection occurs further down in your code, which at the same time creates code-confusion, you have two <option>-tags with the same name.
The browser should render the dropdown-box (or actually the select-item, the dropdown is the "windows" way to display it. Using Tk or so it might just as well be something else..) as the page source specifies, in the same order as the elements are in the source, therefor Javascript is not very useful here from my point of view.
My code doesn't do this, for better or for worse, but they don't do the same thing. "Thanks" to the missing <option>-tag in my code order is preserved.
// Olle