Commit d70072645b30379da4cc9f0d2d4d7dbfd0d4c7be
1 parent
787c8d5f
Exists in
mysqli
Classe DB
Showing
2 changed files
with
6 additions
and
6 deletions
Show diff stats
restrito/inc/database.php
restrito/inc/topo.php
... | ... | @@ -9,6 +9,7 @@ |
9 | 9 | ***********************************************************************************/ |
10 | 10 | |
11 | 11 | require_once("config.php"); |
12 | +include_once(DIR_CLASSES_LEIACESSO."/db.class.php"); | |
12 | 13 | ?> |
13 | 14 | <!DOCTYPE html> |
14 | 15 | <html> |
... | ... | @@ -93,9 +94,9 @@ require_once("config.php"); |
93 | 94 | order by |
94 | 95 | m.ordem, t.ordem, t.nome"; |
95 | 96 | |
96 | - $rs = execQuery($sql); | |
97 | + $rs = DB::execQuery($sql); | |
97 | 98 | |
98 | - while($row = mysql_fetch_array($rs)){ | |
99 | + while($row = mysqli_fetch_array($rs)){ | |
99 | 100 | ?><li class="opcao"><a href="../inc/menu.php?m=<?php echo $row['idmenu'];?>"><?php echo $row['menu'];?></a></li><?php |
100 | 101 | ?><img src="../css/img/pipe.png" /><?php |
101 | 102 | } |
... | ... | @@ -114,9 +115,8 @@ require_once("config.php"); |
114 | 115 | $sql = "SELECT siglasecretaria, idsecretaria FROM vw_secretariausuario |
115 | 116 | WHERE idusuario = '".getSession('uid')."'"; |
116 | 117 | |
117 | - $rs = execQuery($sql); | |
118 | - | |
119 | - while($row = mysql_fetch_array($rs)){ | |
118 | + $rs = DB::execQuery($sql); | |
119 | + while($row = mysqli_fetch_array($rs)){ | |
120 | 120 | ?><option value="<?php echo md5($row['idsecretaria']);?>" <?php echo (getSession('idsecretaria') == $row['idsecretaria'])?"selected":"";?>><?php echo $row['siglasecretaria'];?></option><?php |
121 | 121 | }?> |
122 | 122 | </select> | ... | ... |