var tempname = <%=rs("name")%>;a onMouseOver="javascript:parent.document.all.list.value=tempname">good </a> 

解决方案 »

  1.   

    this.innerHTML='<%=rs("name")%>'
      

  2.   

    a onMouseOver="test()" >good </a> 
    function test()
    {
      var name='<%=rs("name")%>';
      window.parent.document.all.list.value=name;
    }
      

  3.   

    直接写进去
    a onMouseOver="javascript:parent.document.all.list.value=<%=rs("name")%>">good </a> 
      

  4.   

    可以说说具体问题吗,怎么个不行法?
    建议把那个页面最终的主要源代码贴出来看看,这个<%=rs("name")%>取到值了么?
    取到的值是什么类型的,
      

  5.   

    realy?都有问题?我也试了没问题啊?2L和3L的语句'<%=rs("name")%>'中有csdn自动给<加的空格,是不是你直接复制的就出错了??
      

  6.   

    取得的name就是名称字符串
    ------------------------------------------------------------------
    <%    
        set rs= server.CreateObject("adodb.recordset")
        rs.open "select * from api where name = Brew ",conn,1,1
        do while not rs.eof 
        Set regx = New RegExp 
        regx.Pattern = "(^|\b)("+rs("Brew")+")(\b)" 
        regx.IgnoreCase = false 
        regx.Global = True 
        str = regx.Replace(str, "<a target='left' href='title.asp?id="&rs("id")&"' title='"&rs("name")&" : "&rs("res")&"'  onMouseOver='javascript:parent.document.all.list.value=<%=rs("name")%>'>"&rs("Brew")&"</a>") 
        rs.movenext 
        loop
        rs.close
        set rs=nothing  
    %>
    -----------------------------------------------------------------------
    错误类型:
    Microsoft VBScript 编译器错误 (0x800A03EE)
    缺少 ')'
    /kksn/ok/txt.asp, line 321, column 181
    str = regx.Replace(str, "<a target='left' href='title.asp?id="&rs("id")&"' title='"&rs("name")&" : "&rs("res")&"' onMouseOver='javascript:parent.document.all.list.value=<%=rs("name")
    ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------^
      

  7.   

    [code=JScript]
     str = regx.Replace(str,"<a target='left' href='title.asp?id=" & rs("id") & "'title='" &rs("name")& ":" &rs("res") & "'onMouseOver = 'javascript:parent.document.all.list.value = <%=rs("name")%>'" & ">");
    code]
      

  8.   

    str = regx.Replace(str, " <a target='left' href='title.asp?id="&rs("id")&"' title='"&rs("name")&" : "&rs("res")&"'  onMouseOver='javascript:parent.document.all.list.value=""& rs("name") &""'>"&rs("Brew")&" </a>") 
      

  9.   

    str = regx.Replace(str, " <a target='left' href='title.asp?id="&rs("id")&"' title='"&rs("name")&" : "&rs("res")&"'  onMouseOver='javascript:parent.document.all.list.value="""& rs("name") &"""'>"&rs("Brew")&" </a>")写少了个 "
    这不是js的问题咯。
      

  10.   

    不行是其它原因吧。
    <a onMouseOver="javascript:parent.document.all.list.value='<%=rs("name")%>'">good</a>