PHP Classes

File: index.php

Recommend this page to a friend!
  Classes of Ali YILMAZ  >  PHP API Service  >  index.php  >  Download  
File: index.php
Role: Example script
Content type: text/plain
Description: Example script
Class: PHP API Service
Implements a project API using the Mind framework
Author: By
Last change:
Date: 6 months ago
Size: 1,109 bytes


Class file image Download

require './Mind.php';

$conf = array(
'drive' => 'mysql', // mysql, sqlite
'host' => 'localhost',
'dbname' => 'apiservice', // apiservice, app/migration/apiservice.sqlite
'username' => 'root',
'password' => '',
'charset' => 'utf8mb4'
// 'csrf'=>false, // d??ar?dan eri?imler išin kapat?lmal?d?r.

$Mind = new Mind($conf);

$Mind->route('/', ['app/views/partners', 'app/views/branches', 'app/views/products'], 'app/migration/restore');
$Mind->route('api', 'app/api/partner'); // post
$Mind->route('test/api', 'app/views/api'); // form

$Mind->route('new_partner', 'app/views/new_partner');
$Mind->route('new_branch', 'app/views/new_branch');
$Mind->route('new_product', 'app/views/new_product');

$Mind->route('install', 'app/migration/install');
$Mind->route('backup', 'app/migration/backup');
$Mind->route('restore', 'app/migration/restore');

For more information send a message to info at phpclasses dot org.