1
I need urgent the following PHP that was built in msql is written in mysqli it is part of an application in which I am developing I have no knowledge in PHP I’ve broken my head behind a conversion and did not find it very necessary to help.
The Code is as follows
<?php
$serve = mysql_connect('127.0.0.1', 'root', '');
if(!$serve){ echo 'erro';}
$db = mysql_select_db('pizzas', $serve);
if($_GET['acao'] == 'listapizzas'){
$SQL = "SELECT * FROM tipos";
$re = mysql_query($SQL, $serve);
$num = mysql_num_rows($re);
if($num > 0){
while($Linha = mysql_fetch_object($re)){
echo "{$Linha->Nome}<br />";
}
}
else{
echo 'nenhuma pizza cadastrada';
}
}
?>
This question may help you: http://answall.com/questions/47880/comond-update-mycodow-mysql-para-mysqli It’s not difficult!
– user41630