PHP Classes
elePHPant
Icontem

File: sample1.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of helmut kemper  >  PHP 2 Install  >  sample1.php  >  Download  
File: sample1.php
Role: Example script
Content type: text/plain
Description: sample file
Class: PHP 2 Install
Generate PHP script archives for site installation
Author: By
Last change:
Date: 10 years ago
Size: 1,263 bytes
 

Contents

Class file image Download
<?PHP
/*
This example generates an installer for the bank in the local server
with the data:

Base name: LocaBase
User: root
Paswword: 123
Host: localhost

E in the remote server with the data:

Base name: RemoteBase
User: RemoteUser
Paswword: RemotePassword
Host: remote.host.com

--------------------------------------------------------------------------------
Este exemplo gera um instalador para o banco no servidor local com os dados:

Base name: LocaBase
User: root
Paswword: 123
Host: localhost

E no servidor remoto com os dados:

Base name: RemoteBase
User: RemoteUser
Paswword: RemotePassword
Host: remote.host.com
*/
   
include ("./php2install.class.php");
   
   
$vgoInstall = new php2install ();
   
   
$vgoInstall -> setEncodeDbName ("LocaBase");
   
$vgoInstall -> setEncodeDbHost ("localhost");
   
$vgoInstall -> setEncodeDbUser ("root");
   
$vgoInstall -> setEncodeDbPassword ("123");
   
   
$vgoInstall -> setDecodeDbName ("RemoteBase");
   
$vgoInstall -> setDecodeDbHost ("remote.host.com");
   
$vgoInstall -> setDecodeDbUser ("RemoteUser");
   
$vgoInstall -> setDecodeDbPassword ("RemotePassword");
   
   
$vgoInstall -> setDecodeDbPath ("./site_out/site.sql.php");
   
   
$vgoInstall -> encodeDataBase ();
?>