You are currently viewing the Struts section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
You need to set the value attribute of the select tag.
The following code will fix your problem:
<html:select property="loglevel" value="1" size="1">
Notice how I set the value attribute of the select tag to 1, this will cause the value 1 in the option is rendered as selected.