Quantcast
Channel: Adobe Community: Message List
Viewing all articles
Browse latest Browse all 90168

Could anyone tell me where is the error in this code

$
0
0

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>Untitled Document</title>

</head>

  <script type="text/javascript" src="http://code.jquery.com/jquery-1.7.js"></script>

 

 

<script src="js/AddRemRows.js" type="text/javascript"></script>

 

 

<script type="text/javascript">

 

 

    function doAdd(ths)

    {

 

 

    var x = $(this).closest('tr').find('input.x').val();

    var y = $(this).closest('tr').find('input.y').val();

 

 

    y=x;

   

 

 

   }

</script>

 

<body>

<table width="411" height="64" border="1" cellpadding="0" cellspacing="0" id="myTable">

    <tr>

        <td width="43%">Y</td>

        <td width="57%">X</td>

    </tr>

    <tr>

      <td width="43%"><select class="y" name="y" id="y" onchange="doAdd(this)">

          <option value="0">0 </option>

          <option value="1">1</option>

          <option value="2">2</option>

        </select></td>

       

        <td><input class="x" type="text" name="x" id="x" /></td>

    </tr>

</table>

<p>

  <input name="addrow" type="button" id="addrow" onclick="addRow('myTable')" value="add" />

</p>

 

 

</body>

</html>


Viewing all articles
Browse latest Browse all 90168

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>