PHP Classes

PHP Code Generator for MySQL Open Source: Generate classes to access database from dump file

Recommend this page to a friend!
     
  Info   Example   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not yet rated by the usersTotal: 168 All time: 8,873 This week: 206Up
Version Licenses PHP version Categories
phpcodegenerator 1.0.0Public Domain, Th...5PHP 5, Databases, Code Generation
Description 

Author

This class can generate classes to access database from dump file.

It can take a file of a MySQL database dump with SQL statements and parses it to extract the structure of tables and fields that the database contains.

The class can generate file with code of a class that can access the given MySQL database performing common operations like retrieving, inserting, updating and deleting database table records.

PHP source code generator is an idea of make a framework that help us and minimize the process of write and repeat write some thing else.

Picture of Helio Barbosa
Name: Helio Barbosa <contact>
Classes: 2 packages by
Country: Brazil Brazil
Age: ???
All time rank: 3858310 in Brazil Brazil
Week rank: 214 Up16 in Brazil Brazil Up

Example

<script type="text/javascript">
    //window.setTimeout("history.back(-2)", 5000);
</script>
<head>
    <!-- <meta http-equiv="Refresh" CONTENT="5;URL=ClassesPHP.txt"> -->
    <!-- apos 5 segundos exibi o arquivo com todas as classes geradas -->
</head>
<?php
/*
    Programm: gerador_classes.php
    Objective: Generated all class for object orientation in PHP from archeve sql
    Autor: Hélio Barbosa

    http://solucaofinal.com

    GitHub: https://github.com/helhoso/PHPCodeGenerator.git
    linkedin: https://br.linkedin.com/in/helio-barbosa-32718082
    email: hflb01@gmail.com
    youtube: https://www.youtube.com/user/1908HELIO
*/
   
echo ("</br>Gerando Classes PHP....</br>") ;
    echo (
"Recebendo arquivo....</br>") ;
   
$nome_temporario=$_FILES["Arquivo"]["tmp_name"];
   
$nome_real=$_FILES["Arquivo"]["name"];
   
copy($nome_temporario,"arq_sql/$nome_real");

    include_once(
"gerador_gerar_classes.php") ;
   
$NewGerar = New Gerar() ;
   
$NewGerar->setArquivoSQL($nome_temporario);
   
$myClassGerated = $NewGerar->gerarObjPHP();
    echo (
"<a href='". $myClassGerated . "'> Baixar arquivo com Classes </a>") ;
?>
</body>


  Files folder image Files (6)  
File Role Description
Accessible without login Plain text file gerador_classes.php Aux. Auxiliary script
Accessible without login Plain text file gerador_classes_gerar.php Example Example script
Plain text file gerador_gerar_classes.php Class Class source
Plain text file myclasses.php Class Class source
Accessible without login Plain text file usuario_inc.php Example Example script
Accessible without login Plain text file usuario_inc0.php Aux. Auxiliary script

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 100%
Total:168
This week:0
All time:8,873
This week:206Up