0
Hello,
I have a need and I have a great difficulty with PHP, some I managed to help me, I am creating a table with database information, and inside a cell I am putting an Onclick to open a second screen to show the detailing. I need that when the user click on a cell I receive the value of the same on the other page. Follow the code below.
<?php
$SQL = "SELECT * FROM tabela where id = '$_SESSION';";
$BSG = $CONNEXT->prepare($SQL);
$BSG->bindValue(':usr', $USER_, PDO::PARAM_STR);
$BSG->execute();
while ($RESP = $BSG->fetch(PDO::FETCH_ASSOC)) {
//header('Content-Type: text/html; charset=iso-8859-1,utf-8;q=0.7,*;q=0.7');
$percentagem = $RESP[quantidade] / $_erb * 100;
$ta = "";
if($RESP[taRaiz] != ""){
//// preciso recuperar esse valor que esta na celula e abrir em outra
//// pagina para efetuar uma outra consulta, coloquei google, mas eu
//// criar uma outra pagina para receber
$ta = "<td href=\"\" onClick=\"window.open('http://google.com','Janela','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=600,height=300,left=25,top=25'); return false;\">$RESP[taRaiz]</td>";
}else{
$ta = "<td class=\style3\></td>";
}
echo ("<tr>
<td class=\style3\>$RESP[rota]</td>
$ta
<td class=\style3\>$percentagem%</td>
</tr>");
}
?>
Thanks It worked
– Renan Silveira