Re: [PHP] Deprecated features in PHP 5.5.x

[email protected] (Richard)
Newsgroups php.general
Message-ID <138A4E188101B6BB72CCBA5E@[192.168.1.35]>

> Date: Wednesday, February 22, 2017 11:54:07 -0300
> From: Release Edl <[email protected]>
>
> Hi there,
> 
> Torsten gave a good help. Now I'm having a trouble with php 7.1.
> The script works properly in php 5.6:
> 
> <?php
> 
> include("_restrito/conexao.php");
> 
>  $conexao = mysqli_connect($host,$user,$pass,$db);
> 
>     if(!$conexao)
> 
>     die("Nao foi possivel conectar no servidor MySQL. Erro: " .
> mysqli_error());
> 
>     mysqli_select_db($conexao,$db) or die("Nao foi possivel usar o
> banco de dados. Erro: " . mysqli_error());
> 
>     $pagina = $_GET['pagina'];
> 
>     $banco = mysqli_select_db("mensagem");
> 
>  $busca = "SELECT * FROM portfolio ORDER BY id DESC";
> 
>  $total_reg = "5";
>  if (!$pagina) {
>     $pc = "1";
> } else {
>     $pc = $pagina;
> }
> 
> $inicio = $pc - 1;
> $inicio = $inicio * $total_reg;
> 
> $limite = mysqli_query("$busca LIMIT $inicio,$total_reg");
> $todos = mysqli_query("$busca");
> 
> $tr = mysqli_num_rows($todos);
> $tp = $tr / $total_reg;
> 
> while ($dados = mysqli_fetch_array($limite)) {
> 
> ?>
> 
> Could you help?
> 

Where/what fails? I.e., have you tried debugging it? Have you tried
putting in debug (e.g., print/echo) statements and/or taking it apart
so you know how far it gets and what it is failing (including
relevant values at that point)?


[even though the list is set that way, do *not* include my direct
address in a reply. reply only to the list. thank you.]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.