hi,
I am having a page with a table which is created dynamically. I have 2 problems
one is how to identify which row the user clicks and send the cell value to a new page
thanks in advance
pass a cell value
Moderator: General Moderators
- MarK (CZ)
- Forum Contributor
- Posts: 239
- Joined: Tue Apr 13, 2004 12:51 am
- Location: Prague (CZ) / Vienna (A)
- Contact:
Code: Select all
<a href='page.php?value=<?php echo $value; ?>'>text</a>Code: Select all
<script language="javascript">
function changeText(tdObj){
window.location="mypage.php?cell="+tdObj.id;
}
</script>
<table>
<tr>
<td id="row_1_cell_1" onClick="changeText(this)">text</td>
<td id="row_1_cell_2" onClick="changeText(this)">text</td>
</tr>
</table>edit: moved to clientside.