Como capturar 2 parámetros de entrada y 2 parámetros de salida de un sp mysql desde código PHP

<?php
/* Send a query to the server */
if ($result = mysqli_query($link, "call add_cuenta('test',0,@respuesta,@descrespuesta)")) {

$result2=mysqli_query($link,"Select @respuesta, @desrespuesta,");


while( $row = mysqli_fetch_array($result2) ){
echo ($row[0]. "--------- SR. " . $row[1] . "<br>");
}
/* Destroy the result set and free the memory used for it */
mysqli_free_result($result);
}
/* Close the connection */
mysqli_close($link);
?>

{
/* Fetch the results of the query */
while( $row = mysqli_fetch_array($result) ){
echo ($row[0]. "--------- SR. " . $row[1] . "<br>");
}
mysqli_free_result($result);

$result2->close();
}
mysqli_close($link);
?>

agradezco la ayuda que me puedan prestar

Añade tu respuesta

Haz clic para o