I'm using OPTGROUP to group my options value, but i'm getting an wierd issue.
This is what my code looks like:
____________________________________
Just Imagine.
Code:
This is how it comes out:
<select name="ID">
<option value="">Select</option>
<optgroup label="Actuarial Science">
<option value="67">ACTU</option>
</optgroup>
<optgroup label="Anthropology">
<option value="7">ANTH</option>
</optgroup>
<optgroup label="Art History and Archaeology">
<option value="50">AHIS</option>
</optgroup>
<optgroup label="Art History and Archaeology">
<option value="10">HUMA</option>
</optgroup>
</select>
Code:
This is how I want it to come out:
<select name="ID">
<option value="">Select</option>
<optgroup label="Actuarial Science">
<option value="67">ACTU</option>
</optgroup>
<optgroup label="Anthropology">
<option value="7">ANTH</option>
</optgroup>
<optgroup label="Art History and Archaeology">
<option value="50">AHIS</option>
<option value="10">HUMA</option>
</optgroup>
</select>
This is what my code looks like:
Code:
<cfquery name="getIdentifier" datasource="#DB#">
SELECT SI.ID, SI.Name as SIName, D.Department_Info_ID, D.Name as DName
FROM Subject_Identifier SI INNER JOIN
Department_Info D ON D.Department_Info_ID = SI.Department_Info_ID
ORDER BY DName, SIName
</cfquery>
<select name="Subject_Identifier_ID">
<option value="">Select a Subject Identifier</option>
<cfloop query="getIdentifier">
<optgroup label="#DName#">
<option value="#ID#">#SIName#</option>
</optgroup>
</cfloop>
</select>
____________________________________
Just Imagine.