Psst.. new poll here.
Psst.. new forums here.
Microsoft is blocking us again (TY IP Reputation!) so just use oauth login instead. :)
Paste
Pasted as PHP by salvar ( 3 years ago )
<?php
$nome = $_GET["nome"];
$curso = $_GET["curso"];
$servidor = "localhost";
$username = "539681";
$password = "123456";
$database = "539681";
$con = mysqli_connect($servidor,$username,$password,$database);
$sql = "insert into aluno(nome,curso) values('{$nome}','{$curso}')";
mysqli_query($con,$sql);
$sql = "select * from aluno";
$res = mysqli_query($con,$sql);
$linhas = array();
while($linha=mysqli_fetch_assoc($res)){
//$linha["ra"];
$linhas[] = $linha;
}
echo json_encode($linhas);
?>
Revise this Paste