<input name="newq22" type="button" class="button1"  id="newq2"  value=" + " onclick="document.getElementById('sdf3').value=document.getElementById('sdf3').value+this.value">

解决方案 »

  1.   

    <%@ page contentType="text/html; charset=gb2312" %>
    <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
    <html>
    <head>
    <link href="../../inc/sysplatform.css" rel="stylesheet" type="text/css"><!-- /q3app -->
    <title>正则表达式校验工具</title>
    </head>
    <Script Language="Javascript" Src="/Inc/Main.js"></Script>
    <body >
          <TABLE cellSpacing=1 width=100% align=center border=0>
            <TBODY>
              <TR>
                <TD><h1 style="font-size:16px"><span class="blue">正则表达式校验工具</span></h1></TD>
              </TR>
            </TBODY>
          </TABLE>
          <table width="790" border="0" cellpadding="0" cellspacing="0">
            <!--DWLayoutTable-->
            <tr valign="middle" bgcolor="#999999">
              <td width="20" height="20">&nbsp;</td>
              <td colspan="5" valign="middle"><input name="newq23" type="button" class="button1"  id="newq24" onClick="" value="确定">
                <input name="newq32" type="reset" class="button1"  id="newq3" onClick="" value="取消">
                <input name="newq42" type="button" class="button1"  id="newq43" onClick="" value="校验">          
              <!--  -->          </td>
              <td width="188" colspan="8" align="right">            <option>
              </option>          </td>
            </tr>
          </table>
          <table width="790" border="0" cellpadding="0" cellspacing="0">
            <!--DWLayoutTable-->
            <tr valign="middle">
              <td height="15" colspan="12">&nbsp;&nbsp;&nbsp;表达式:</td>
              <td width="20"></td>
            </tr>
          </table>
          <table width="790" bgcolor="#F5F5F5" cellpadding=4 cellspacing=0>
            <tr>
              <td><textarea name="sdf3" id="sdf3" class="textarea5" style="width:615;height:120"></textarea></td>
            </tr>
          </table>
        </td>
      </tr>
    </table>
    <table width="790" border="0">
      <tr>
        <td width="164"><br><br><table width="161" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td height="30" align="center"><input name="newq22" type="button" class="button1"  id="newq2" onClick="sdf3.innerText = sdf3.innerText+'+'" value=" + "></td>
            <td height="30"><input name="newq222" type="button" class="button1"  id="newq22" onClick="sdf3.innerText = sdf3.innerText+'-'" value=" - "></td>
          </tr>
          <tr>
            <td height="30" align="center"><input name="newq223" type="button" class="button1"  id="newq222" onClick="sdf3.innerText = sdf3.innerText+'*'" value=" * "></td>
            <td height="30"><input name="newq224" type="button" class="button1"  id="newq223" onClick="sdf3.innerText = sdf3.innerText+'/'" value=" / "></td>
          </tr>
          <tr>
            <td height="30" align="center"><input name="newq225" type="button" class="button1"  id="newq224" onClick="sdf3.innerText = sdf3.innerText+'('" value=" ( "></td>
            <td height="30"><input name="newq226" type="button" class="button1"  id="newq225" onClick="sdf3.innerText = sdf3.innerText+')'" value=" ) "></td>
          </tr>
        </table></td>
        <td width="256"><p>函数:</p>
        <p>
          <select name="status" size="6" multiple class="select1" ondblclick =" sdf3.innerText = sdf3.innerText+this.options[this.selectedIndex].innerText">        <option value='1' >abs(x)</option>
            <option value='2'>acos(x)</option>
            <option value='3'>asin(s)</option>
          </select>
    </p></td>
        <td width="356"><p>列名:</p>
        <p>
          <select name="select" size="6" multiple class="select1" ondblclick =" sdf3.innerText = sdf3.innerText+this.options[this.selectedIndex].innerText">
            <option value='1'>dsads</option>
            <option value='2'>urtyu</option>
            <option value='3'>rwdgfd</option>
          </select>
        </p></td>
      </tr>
    </table>
    <!--alert(this.options[this.selectedIndex].innerText)-->
    </body>
    </html>
      

  2.   

    hbhbhbhbhb1021(天外水火(我要多努力)) <input name="newq22" type="button" class="button1"  id="newq2"  value=" + " onclick="document.getElementById('sdf3').value=document.getElementById('sdf3').value+this.value">正解