PHP Classes

File: examples/db/example_activerecord_sqlite.php

Recommend this page to a friend!
  Classes of Haseeb Ahmad Basil   PHP Skeleton Framework   examples/db/example_activerecord_sqlite.php   Download  
File: examples/db/example_activerecord_sqlite.php
Role: Example script
Content type: text/plain
Description: Example script
Class: PHP Skeleton Framework
Extensive Web application development framework
Author: By
Last change:
Date: 8 years ago
Size: 380 bytes
 

Contents

Class file image Download
<?php
include 'config.php';
#include 'A/Db/Sqlite.php';
#include 'A/Db/Activerecord.php';

class Projects extends A_Db_Activerecord
{
}

$db = new A_Db_Sqlite3($ConfigArray['DBDSN_SQLITE']);
$db->connect();
if (
$db->isError()) die('ERROR: ' . $db->getMessage());

$project = new Projects($db);

$project->find(2);
dump($project->sql);
dump($project->toArray());