This is prohibited by specs, a select element is not allowed to contain
a input element.

You might better use either a 2d array -> var tmp [[0,1],[0,1]] or a
struct -> var tmp {name:'value',name:'value'}

Micha Schopman
Project Manager

Modern Media, Databankweg 12 M, 3821 AL  Amersfoort
Tel 033-4535377, Fax 033-4535388
KvK Amersfoort 39081679, Rabo 39.48.05.380

------------------------------------------------------------------------
------------------------------------------------------------------------
-----
Modern Media, Making You Interact Smarter. Onze oplossingen verbeteren
de interactie met uw doelgroep. 
Wilt u meer omzet, lagere kosten of een beter service niveau? Voor meer
informatie zie www.modernmedia.nl 
------------------------------------------------------------------------
------------------------------------------------------------------------
-----
-----Original Message-----
From: Jeff Waris [mailto:[EMAIL PROTECTED] 
Sent: dinsdag 14 juni 2005 14:02
To: CF-Talk
Subject: Quick OT Javascript question. PART 2

Another question:

In my previous question.. I needed to grab the currently selected option
from a select list.

I can now get the selected value using this code...

var SelOpt = document.myform.colors.options.selectedIndex;
var colortype = document.myform.colors[SelOpt].value;

I now need to get the value of a hidden input that is dynamically named
from
the select list value...

Visusally it looks like this...

<select name="colors">
        <cfloop query="color_names>
        <option value="#name#">#name#</option>
        <input type="hidden" name="#name#" value="#rating#">
        </cfloop>

I am looking to get the RATING value. 
I can get the selected NAME using the code above, but my attempts to
extract
the hidden variable have been unsuccessful. 

I've tried:

var amt = 'document.myform.' + colortype + '.value';
and
var amt = document.myform.colortype.value';

I'm stumped.. Any suggestions???

Thanks,
Jeff




~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:209398
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to