我的radio和text代码如下  我想把rdo的checked后的value传给text的value<form id="rdo"  >
        <img src="../../cn/gspic/dmz.jpg" width="12" height="12"  class="pad5r"/>按类型分:<br />
        <input type="radio" name="series"  value="宣传型"/>
        宣传型<br />
        <input type="radio" name="series"  value="营销型"/>
        营销型<br />
        <input type="radio" name="series"  value="商城型"/>
        商城型<br />
        <input type="radio" name="series"  value="外贸型"/>
        外贸型
    </form>
<input type="text" name="reciver" id="reciver" size="10" />

解决方案 »

  1.   

    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>无标题文档</title>
    </head>
    <body>
    <form id="rdo"  >
            <img src="../../cn/gspic/dmz.jpg" width="12" height="12"  class="pad5r"/>按类型分:<br />
            <input type="radio" name="series"  value="宣传型"/>
            宣传型<br />
            <input type="radio" name="series"  value="营销型"/>
            营销型<br />
            <input type="radio" name="series"  value="商城型"/>
            商城型<br />
            <input type="radio" name="series"  value="外贸型"/>
            外贸型
    </form>
    <input type="text" name="reciver" id="reciver" size="10" />
    </body>
    <script type="text/javascript" >
        var rads = document.getElementsByName("series");
        for (var i = 0, len = rads.length; i < len; i++) {
            rads[i].onclick = function () {
                document.getElementById("reciver").value = this.value;
            }
        }
    </script>
    </html>
      

  2.   


    那我现在把值传递到text之后,我的页面要显示相应的类型的产品,这个还要加什么事件之类的东西吗?
      

  3.   


    rads[i].onclick = function () {
        document.getElementById("reciver").value = this.value;
        //显示相应产品的代码
    }
      

  4.   

    我把我整个页面给你看看吧....大神救命啊!<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <%@ Register Src="/sysaspx/chkPermissions.ascx" TagName="chkPermissions" TagPrefix="Wcms" %>
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>无锡小牛网络科技有限公司</title>
    <link href="../../cn/gs.css" rel="stylesheet" type="text/css" />
    <!--mainl-->
    <script type="text/javascript" src="../../cn/mainl/js/pptBox.js"></script>
    <!--mainl-->
    </head>
    <body onload="javascript:showdh(1);">
    <div id="container"> 
        <!--#include file="_top.asp"-->
        <div class="clearfloat"></div>
        <div><img src="../../cn/gspic/show.jpg" width="1001" height="216" /></div>
        <div class="clearfloat"></div>
        <div class="k20"></div>
        <div class="clearfloat"></div>
        <div id="nmain">
            <div id="nmainl"> 
                <div id="nmainlx">
        <div class="size14 c7000a left bold"><img src="../../cn/gspic/wzal.jpg" width="12" height="12" class="pad5r"/>网站案例</div>
        <div class="k10"></div>
    <script type="text/javascript" >
    function chuanzhi(){
        var rads = document.getElementsByName("series");
        for (var i = 0, len = rads.length; i < len; i++) {
            rads[i].onclick = function () {
                document.getElementById("reciver").value = this.value;
            }
        }
    }
    </script>
        <form id="rdo"  onpropertychange="chuanzhi()">
            <img src="../../cn/gspic/dmz.jpg" width="12" height="12"  class="pad5r"/>按类型分:<br />
            <input type="radio" name="series"  value="宣传型"/>
            宣传型<br />
            <input type="radio" name="series"  value="营销型"/>
            营销型<br />
            <input type="radio" name="series"  value="商城型"/>
            商城型<br />
            <input type="radio" name="series"  value="外贸型"/>
            外贸型
        </form>
    <input type="text" name="reciver" id="reciver" size="10"  onpropertychange="location.href='show.aspx?key1='+document.getElementById('reciver').value"     style="visibility:hidden;" />
        <div class="k10"></div>
    <script type="text/javascript">
    function chuanzhi2(){
    var select=document.getElementById("select2").options;//下拉列表元素值for(var i=0;i<select.length;i++){
    if(select[i].selected==true){
    document.getElementById("reciver2").value=select[i].value;//收件人
    }
    }
    }
    </script>
        <form id="select2"  onpropertychange="chuanzhi2()">
            <img src="../../cn/gspic/dmz.jpg" width="12" height="12"  class="pad5r"/>按行业分:<br />
            <input type="radio" name="series"  value="电子"/>
            电子<br />
            <input type="radio" name="series"  value="通用机械"/>
            通用机械<br />
            <input type="radio" name="series"  value="包装"/>
            包装<br />
            <input type="radio" name="series"  value="照明"/>
            照明<br />
            <input type="radio" name="series"  value="家居百货"/>
            家居百货<br />
            <input type="radio" name="series"  value="五金工具"/>
            五金工具<br />
            <input type="radio" name="series"  value="橡胶"/>
            橡胶<br />
            <input type="radio" name="series"  value="气摩"/>
            气摩<br />
            <input type="radio" name="series"  value="加工"/>
            加工<br />
            <input type="radio" name="series"  value="服饰"/>
            服饰<br />
            <input type="radio" name="series"  value="房地产"/>
            房地产<br />
            <input type="radio" name="series"  value="政府"/>
            政府
        </form>
    <input type="text" name="reciver2" id="reciver2" size="10"  onpropertychange="location.href='show.aspx?key2='+document.getElementById('reciver2').value" style="visibility:hidden;" />





        <div class="k10"></div>
    <script type="text/javascript">
    function chuanzhi3(){
    var select=document.getElementById("select3").options;//下拉列表元素值for(var i=0;i<select.length;i++){
    if(select[i].selected==true){
    document.getElementById("reciver3").value=select[i].value;//收件人
    }
    }
    }
    </script>
        <form id="select3"  onpropertychange="chuanzhi3()">
            <img src="../../cn/gspic/dmz.jpg" width="12" height="12"  class="pad5r"/>按模式分:<br />
            <input type="radio" name="series"  value="定制建站"/>
            定制建站<br />
            <input type="radio" name="series"  value="智能建站"/>
            智能建站
        </form>
    <input type="text" name="reciver3" id="reciver3" size="10"  onpropertychange="location.href='show.aspx?key3='+document.getElementById('reciver3').value"  style="visibility:hidden;"/>
        <div class="k10"></div>
        <dl>
            <dt><img src="../../cn/gspic/dmz.jpg" width="12" height="12"  class="pad5r"/><a href="jdshow.aspx">经典案例</a></dt>
        </dl>
    </div>







            </div>
            <div id="nmainr">
                <div class="size14 bold"><img src="../../cn/gspic/hq.jpg" width="13" height="16" class="pad5r"/>网站案例</div>
                <div class="k10"></div>
                <div id="nmainrbj">
                    <p>网站案例</p>
                </div>
                <div><img src="../../cn/gspic/xian.jpg" width="873" height="33" /></div>
                <div class="clearfloat"></div>
                <div id="show">
                    <ul>
                        


    <!--Repeater TableName="Wcms_Products" Where="Products_State='1' and #Products_CateID={Get.ProductsCateID,wzal}#  and Products_ExFlag3 like '%{Get.key1,}%' " OrderBy="Products_Id Desc" SqlType="select" PrimaryKey="Products_Id" SelectDir="thisandsub" PageSize="30" IsPage="True"-->
    <!--Item-->
    <li><img src="{Wcms_Products.Products_MinImage}" width="210" height="140" /> <span class="size14 bold">{Wcms_Products.Products_Title,10}</span><br />
                            <span class="c7000a">成交产品:</span>{Wcms_Products.Products_ExFlag2}<br />
                            <span  class="c7000a">成交金额:</span>{Wcms_Products.Products_Prices} <br />
                            <span  class="c7000a">客户行业:</span>{Wcms_Products.Products_ExFlag4}<br />
                            <span  class="c7000a">官方网址:</span><a href="{Wcms_Products.Products_ExFlag6}">{Wcms_Products.Products_ExFlag6,8}</a></li><!--/Item-->
    <!--/Repeater-->















                        
                    </ul>
                </div>
            </div>
        </div>
        <div class="clearfloat"></div>
    <div style="clear:both;"></div><Wcms:chkPermissions ID="chkPermissions_0" runat="server" />
        <!--#include file="_foot.asp"--> 
    </div>
    </body>
    </html>
      

  5.   

    我把我隐藏的文本框显示出来 然后直接在文本框中输入相应的类型,就可以正常显示了。那就说明还是radio的值没有传给text。