znframework/package-database

ZN Framework Database Package


Keywords
database, znframework
License
MIT

Documentation

ZN Framework Database Package

Follow the steps below for installation and use.

Installation

You only need to run the following code for the installation.

composer require znframework/package-database

Documentation

Click for documentation of your library.

Example Usage

Basic level usage is shown below.

<?php require 'vendor/autoload.php';

ZN\ZN::run();

# The default settings are in the ZN\Database\DatabaseDefaultConfiguration file. 
# You can make your settings in this file.
# The Config::set() method should be used if you need to configure settings externally.
Config::database('database', 
[
    'driver'   => 'mysqli',
    'host'     => 'localhost', 
    'database' => 'test',
    'user'     => 'root',
    'password' => '',
    'prefix'   => ''
]);

$persons = DB::persons();

Output::display($persons->result());