View Full Version : Selected Value
cameron
09-08-2006, 07:49 AM
I'm making an edit feature in my CMS in which I load values from the database into a <select> dropdown list. I want to know how to specifiy the option which is selected when the page loads instead of having it simply select the first item in the list. Thanks.
You can specifiy the option which is selected when the page loads by adding the "selected" attribute in the option you want:
<OPTION selected value="1">Option1</OPTION>
Powered by vBulletin® Version 4.2.2 Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.