PHP code example of danieltm / mysql_query

1. Go to this page and download the library: Download danieltm/mysql_query library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

danieltm / mysql_query example snippets

shell
     MysqlQuery\Master;
     $sql = new Master("host", "user", "senha");
  
shell
      $sql->useDB($database); // $database é o nome da base de dados criada
      $tabela = "Table_name";
      $lista = $sql->GetAllElements($tabela);
      foreach($lista as $key){
        echo $key[//'nome da sua coluna'];
      }
   
shell
     MysqlQuery\Master;
     $sqlPdo = new PdoMaster("host", "senha", "tipodebanco(mysql/postgresql)", "user");