split sql schema from php
This commit is contained in:
@@ -24,19 +24,7 @@
|
||||
|
||||
require_once("opendb.php");
|
||||
try {
|
||||
$query = <<<EOD
|
||||
create table if not exists
|
||||
user (
|
||||
name
|
||||
varchar(50) not null primary key
|
||||
comment "unique name of the user",
|
||||
pubkey
|
||||
text not null
|
||||
comment "armored gnupg public key of the user"
|
||||
) character set utf8 engine=innodb
|
||||
comment="list of all registered users and their public keys";
|
||||
EOD;
|
||||
$db->query($query);
|
||||
$db->query(file_get_contents("usertable.sql"));
|
||||
} catch (Exception $e) {
|
||||
error('database error on server');
|
||||
}
|
||||
|
Reference in New Issue
Block a user