<html>
<head>
<title>PersistentObject Testpad</title>
</head>
<body>
<?php
/**
* @Author: Paul Campbell <paul@campbell-multimedia.com>
* @Company: Campbell Multimedia <www.campbell-multimedia.com>
* @Date: 2nd July 2003
*/
require_once( "config.php" );
$c = new CustomerPlain();
$c->load( $db, 1 );
print "<p>Just a load...</p>";
$c->render($db);
$c->set( "name", "Different Name" );
$c->commit($db);
$c->load( $db, 1 );
print "<p>After modification, commit() and load()</p>";
$c->render();
$c = new CustomerPlain();
$c->create("NewCustomer");
$c->commit($db);
$c->load( $db , $c->id );
print "<p>A new customer, inserted into the DB as a new row, loaded and rendered.</p>";
print "<p>New CustomerID = $c->id</p>";
$c->render();
?><br /><?
?>
|