My recommendation would be to not use <cfselect>, particularly if you're not
using the required="true" attribute... iirc ( it's been a while ),
<cfselect> adds any manually added rows ( <cfselect ...><option
value=""></option></cfselect> to the bottom of the list, rather than to the
top, which is usually where I want it/them ... so asside from the javascript
portions of <cfselect> used for the required and message attributes ( which
you may be able to recreate by examining the output of the page ), you can
get the same results from

<select name="myselect"><option value=""></option>
<cfoutput query="myquery">
        <option value="#myquery.myvalue#">
        #htmleditformat(myquery.myvalue2)#</option>
</select>


hth

Isaac Dealey
Certified Advanced ColdFusion 5 Developer

www.turnkey.to
954-776-0046

> This will add a blank row at the beginning of the query. You can also use
> QuerySetCell to give the row specific values.

> <cfset temp = queryaddrow(GetDivision,1)>

> - j

> -----Original Message-----
> From: Clark, Aimee [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, August 27, 2002 12:00 PM
> To: CF-Talk
> Subject: Have a question about a cfselect....Was(RE: Need help with
> update on two different tables)


> Turns out that there was nothing wrong with this cfselect, but something
> else was wrong with the data that was being saved to the multiple tables I
> was inserting into. All is well, however I have a question. How can I
> emulate the blank line before a cfselect in a drop down box? Here's a
> sample
> cfselect I have:

> <tr>
>     <td>Division:</td>
>     <td><cfselect name="Division" query="GetDivision" value="Division"
> display="Division"></cfselect></td>
> </tr>

> Currently this defaults to the 1st value that the query returns. I tried
> to
> insert a blank line in the DB, but that is not working.

> Thanks,
>       Aimee' Clark

> -----Original Message-----
> From: S. Isaac Dealey [mailto:[EMAIL PROTECTED]]
> Sent: Friday, August 23, 2002 7:37 PM
> To: CF-Talk
> Subject: RE: Need help with update on two different tables


>> Here's the code for the cfselect.

>> <tr>
>>     <td>Gender:</td>
>>     <td><cfselect name="Gender" message="Gender"
>>     query="GetPersonnelInfo"
>> value="Gender" selected="Gender">
>> <option value="M">M
>>       <option value="F">F</cfselect></td>
>> </tr>

> My first instinct is to close the option tags... so <option
> value="M">M</option> ... If that doesn't work, I'd start to think it's a
> bug
> because I don't see any other problems with the <cfselect> tag syntax...
> I'm
> not sure why there's a query attribute tho, since your only options are
> both
> provided manually and not by the query ( as is normal for cfselect ), so
> you
> might want to remove that also... and if you want to make sure the people
> entering the data don't make some women men, you might also want to add
> <option value=""></option> above the M option...


> hth

> Isaac
> Certified Advanced ColdFusion 5 Developer

> www.turnkey.to
> 954-776-0046



> 
______________________________________________________________________
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to