Good day!
i have the following code where i am retrieving data from the database and created an onclick event link to call the detail view screen where data is populated according to the selected id, i am not sure exactly how i can call the detail view of the selected id
while($row = mysql_fetch_row($result))
{
$id=$row[0]; ?>
<tr onclick="window.location.href='crimereport_view.php?id=<?php echo $id; ?>'" onMouseOver="this.style.cursor='pointer'"> //
<?php
// $row is array... foreach( .. ) puts every element
// of $row to $cell variable
foreach($row as $cell)
echo "<td id=\"tablecon\">$cell</td>";
echo "</tr>\n";
}
<tr onclick="window.location.href='crimereport_view.php?id=<?php echo $id; ?>'" onMouseOver="this.style.cursor='pointer'"> // how can i access the detailed view of the crimereport form according the the id/row selected, i hope am understandable?
Please assist.
linking to the Detailed view of a form according the the id
-
- Posts: 26
- Joined: 2015-01-12 13:01
-
- Posts: 26
- Joined: 2015-01-12 13:01
Re: linking to the Detailed view of a form according the the
Its working i got the solution thanks any way:
while($row = mysql_fetch_row($result))
{
$id=$row[0]; ?>
<tr onclick="window.location.href='crimereport_view.php?SelectedID=<?php echo $id?>'" onMouseOver="this.style.cursor='pointer'"> //
solution
<?php
// $row is array... foreach( .. ) puts every element
// of $row to $cell variable
foreach($row as $cell)
echo "<td id=\"tablecon\">$cell</td>";
echo "</tr>\n";
}
while($row = mysql_fetch_row($result))
{
$id=$row[0]; ?>
<tr onclick="window.location.href='crimereport_view.php?SelectedID=<?php echo $id?>'" onMouseOver="this.style.cursor='pointer'"> //

<?php
// $row is array... foreach( .. ) puts every element
// of $row to $cell variable
foreach($row as $cell)
echo "<td id=\"tablecon\">$cell</td>";
echo "</tr>\n";
}