ok, I'm tryin to implement the same mxAjax coolness with radio buttons instead 
of my select menu. My problem is, getelementbyid() is using the first radio 
button value only. 

I have about 10 radio buttons, all with different values. When I select one, it 
needs to feed getelementbyid() with its value, so it can then be sent into my 
ajax cfc.

I'm guessin JS deals with radio buttons differently. The ajax call works 
perfectly - just uses one radio value only. lol.

Did some googlin, no luck. 

Here's my ajax call:

 <script language="javascript">
            var url = "http://localhost:8500/mysite/mxajax/core/cf/example.cfc";;
           
            function init() {
                           var DSID = document.getElementById("qType").value;
                           
                new mxAjax.Data({
                    executeOnLoad:true,
                    paramArgs: new mxAjax.Param(url,{param:"DSID=" + DSID, 
cffunction:"getDistractors"}),
                    postFunction: handleData
                });
               
                function handleData(response) {
                    var myHTMLOutput = JSON.parse(response);
                    document.getElementById("showDistractors").innerHTML = 
myHTMLOutput;
                }
            }
           
           
        </script> 

Here's my form stuff:

<p><input name="qType" id="qType" type="radio" value="1" onclick="init();"  /> 
Likert Scale</p>

                
                <p><input name="qType" id="qType" type="radio" value="4" 
onclick="init();"  /> Yes/No</p>
                
                <p><input name="qType" id="qType" type="radio" value="25" 
onclick="init();"  /> Yes/No with Not sure</p>
                
                <p><input name="qType" id="qType" type="radio" value="26" 
onclick="init();"  /> Satisfaction Ratings</p>
                
                <p><input name="qType" id="qType" type="radio" value="27" 
onclick="init();"  /> Quality Ratings</p>
                
                <p><input name="qType" id="qType" type="radio" value="28" 
onclick="init();"  /> Amount Ratings</p>

                
                <p><input name="qType" id="qType" type="radio" value="29" 
onclick="init();"  /> GPA Ratings</p>
                
                <p><input name="qType" id="qType" type="radio" value="30" 
onclick="init();"  /> Grade Ratings</p>

Any ideas anyone? James?

Thanks much,
Will

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
ColdFusion MX7 by AdobeĀ®
Dyncamically transform webcontent into Adobe PDF with new ColdFusion MX7. 
Free Trial. http://www.adobe.com/products/coldfusion?sdid=RVJV

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:284282
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to