You have no VALUE attribute on the default option.

> -----Original Message-----
> From: Marc Garrett [SMTP:[EMAIL PROTECTED]]
> Sent: Tuesday, April 24, 2001 9:48 AM
> To:   CF-Talk
> Subject:      Re: Character code for a TAB
> 
> Michael Lugassy wrote:
> 
> > I JUST LOVE IT WHEN 1203483409875 PEOPLE answer the same answer
> > to a pretty easy question.
> 
> I'm still hoping to get an answer to a question I posted yesterday that I
> have to think other people have handled before. Here's a repost:
> 
> I have an update page on which I need to show "user friendly" terms in a
> select box, even though the information in the table is actually a code
> number (e.g., the info is saved as "010-000" but the user should see
> "services.") The value from the select is then passed to a CFUPDATE on the
> following page. I can get the update to work properly if the user changes
> the value in the select box, but if she leaves the value unchanged the field
> gets updated to the "friendly" word instead of leaving the code value
> unchanged.
> 
> Thanks for any assistance. I have included code below my sig.
> 
> Regards,
> 
> Marc Garrett
> 
> Here's the code that populates the select list:
> 
> <select class="editBox" name="fldCategory1">
>     <option><cfoutput query="category_1">#fldCategory#</cfoutput></option>
>     <cfloop query="categories">
>     <option
> value="<cfoutput>#fldCategoryID#</cfoutput>"><cfoutput>#fldCategory#</cfoutp
> ut></option>
>     </cfloop>
> </select>
> 
> Here's query category_1:
> 
> <cfquery datasource="datasource" name="category_1">
> SELECT
>  tblContacts.fldContactID,
>  tblContacts.fldCategory1,
>  tblCategories.fldCategory,
>  tblCategories.fldCategoryID
> FROM
>  tblContacts, tblCategories
> WHERE
>  tblContacts.fldContactID LIKE '#id#'
>  AND tblCategories.fldCategoryID = tblContacts.fldCategory1
> </cfquery>
> 
> The update on the next page is simply:
> <cfupdate datasource="datasource" tablename="tblContacts">
> 
> 
> 
> 
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to