Download the PHP package kiss-php/tables without Composer

On this page you can find all versions of the php package kiss-php/tables. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package tables

Tables

Tables is a small PHP ORM-like library that maps simple .tbl files to PDO rows. It is designed for quick projects where table definitions live beside the code and the library can create or repair the schema when a table or column is missing.

Install

Or, inside this repository:

Configuration

Connections are read from $_ENV. The default connection uses the DB_ prefix:

MySQL is also supported:

Named connections use DB_<FLAG>_, for example DB_LITLE_TYPE and DB_LITLE_PATH, then pass the flag to TablesManager or Row methods.

Table Definitions

Create .tbl files in a folder, one file per table:

Supported syntax:

Every table gets an auto-increment id column automatically.

Usage

Rows expose dynamic getters and setters. CamelCase method names are converted to snake_case database columns:

Schema Repair

persist() and get() recover from missing tables by creating the table from its .tbl definition. persist() can also add missing columns and retry the operation. This auto-repair behavior is enabled by default because it is the core workflow of the library.

You can disable it for stricter environments:

For explicit setup, call:

Rollback

Rows changed through persist() or delete() are tracked. Calling:

restores updated/deleted rows or removes rows inserted during the current process.

History Logs

Tables keeps a small in-memory history. It stores SQL parameters as they are provided. This keeps the library small and predictable, but it also means you should not print or export history in production unless you are comfortable with the values it contains.

You can route logs wherever you want with an optional callback:

Database exceptions are logged as sanitized error events with the exception class and code, not the raw database error message.

Security and Operational Notes

Tables is a lightweight library, not a full application security layer. Keep these points in mind when using it:

Smoke Test

Run the SQLite smoke test:


All versions of tables with dependencies

PHP Build Version
Package Version
No informations.
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package kiss-php/tables contains the following files

Loading the files please wait ...