<?php

if (!isset($gCms)) exit;

$db =& $gCms->GetDb();
$taboptarray = array('mysql' => 'TYPE=MyISAM');
$dict = NewDataDictionary($db);

$flds = "
	id I KEY,
	name C(80),
	location C(255),
	description X,
	player I,
	params X,
	width I,
	height I
	";

$sqlarray = $dict->CreateTableSQL(cms_db_prefix()."module_play_records", $flds, $taboptarray);
$dict->ExecuteSQLArray($sqlarray);

$db->CreateSequence(cms_db_prefix()."module_play_records_seq");


$flds = "
	id I KEY,
	name C(80),
	location C(255),
	template X,
	params X,
	paramlist X,
	width I,
	height I,
	locked L
	";

$sqlarray = $dict->CreateTableSQL(cms_db_prefix()."module_play_players", $flds, $taboptarray);
$dict->ExecuteSQLArray($sqlarray);

$db->CreateSequence(cms_db_prefix()."module_play_players_seq");

require_once dirname(__FILE__).'/method.installdefault.php';



// create a permission
$this->CreatePermission('Use Play', 'Use Play');

$this->Audit( 0, $this->Lang('friendlyname'), $this->Lang('installed',$this->GetVersion()));

?>