I have two functions with single parameter each. These functions are being called when table data is clicked. Now the problem is the first one is functioning well when called bt the second one can’t, but when i make the second one without parameters it’s working well. So how can i deal with this because i need to pass values in all functions. Thanks for your help in advance
I tried removing parameters in the second function and it worked well bt that’s not what i want so as to serve the objective.
<script>
function getusers(cd){
alert(cd);
}
function getdata(db){
alert(db);
}
</script>
<?php
$code = 'example';
echo"<tr><td onclick='getdata($code)'>DATA</td>
<td onclick='getusers($code)'>DATA</td>";
</tr>
?>
1