Commit 7531d8a73863fae063248e1d74d10e227f8f4321
1 parent
8a654980
Exists in
mysqli
mysqli
Showing
3 changed files
with
7 additions
and
7 deletions
Show diff stats
inc/lkpcep.php
... | ... | @@ -11,7 +11,7 @@ |
11 | 11 | //include("../inc/autenticar.php"); |
12 | 12 | include("../inc/security.php"); |
13 | 13 | |
14 | - $q = $_REQUEST['q']; | |
14 | + $q = DB::esc($_REQUEST['q']); | |
15 | 15 | |
16 | 16 | $sql = "select cep, logradouro, bairro, cidade as municipio, uf as estado |
17 | 17 | from vw_cep |
... | ... | @@ -20,9 +20,9 @@ |
20 | 20 | and uf = 'RN' |
21 | 21 | limit 0,10"; |
22 | 22 | |
23 | - $resultado = execQuery($sql); | |
23 | + $resultado = DB::execQuery($sql); | |
24 | 24 | $codigos = ""; |
25 | - while ($row = mysql_fetch_array($resultado)){ | |
25 | + while ($row = mysqli_fetch_array($resultado)){ | |
26 | 26 | |
27 | 27 | $codigos .= '"'.$row['cep'].'",' ; |
28 | 28 | $nomes .= '"'.htmlentities($row['logradouro']).' - '.htmlentities($row['bairro']).', '.htmlentities($row['municipio']).'/'.$row['estado'].'",' ; | ... | ... |
inc/security.php
... | ... | @@ -74,8 +74,8 @@ function PHPMailerSendMail($to, $subject, $body, $from="", $fromname=""){ |
74 | 74 | } |
75 | 75 | if(empty($from)){ |
76 | 76 | $sql = "SELECT nomeremetenteemail, emailremetente FROM lda_configuracao"; |
77 | - $rs = execQuery($sql); | |
78 | - $row = mysql_fetch_array($rs); | |
77 | + $rs = DB::execQuery($sql); | |
78 | + $row = mysqli_fetch_array($rs); | |
79 | 79 | $mail->From = $row['emailremetente']; |
80 | 80 | $mail->FromName = $row['nomeremetenteemail']; |
81 | 81 | }else{ | ... | ... |
restrito/inc/security.php
... | ... | @@ -74,8 +74,8 @@ function PHPMailerSendMail($to, $subject, $body, $from="", $fromname=""){ |
74 | 74 | } |
75 | 75 | if(empty($from)){ |
76 | 76 | $sql = "SELECT nomeremetenteemail, emailremetente FROM lda_configuracao"; |
77 | - $rs = execQuery($sql); | |
78 | - $row = mysql_fetch_array($rs); | |
77 | + $rs = DB::execQuery($sql); | |
78 | + $row = mysqli_fetch_array($rs); | |
79 | 79 | $mail->From = $row['emailremetente']; |
80 | 80 | $mail->FromName = $row['nomeremetenteemail']; |
81 | 81 | }else{ | ... | ... |