1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
|
<?php
$tables = array(
'adodb_logsql' => "
created T NOT NULL,
sql0 C(250) NOTNULL,
sql1 X NOTNULL,
params X NOTNULL,
tracer X NOTNULL,
timer N(16.6) NOTNULL
",
'kernel_prefs' => "
name C(40) PRIMARY,
package C(100),
value C(250)
",
'mail_notifications' => "
event C(200),
object C(200),
email C(200)
",
);
global $gBitInstaller;
foreach( array_keys( $tables ) AS $tableName ) {
$gBitInstaller->registerSchemaTable( KERNEL_PKG_NAME, $tableName, $tables[$tableName], TRUE );
}
$gBitInstaller->registerPackageInfo( KERNEL_PKG_NAME, array(
'description' => "This is the heart of the application. Without this --> nothing.",
'license' => '<a href="http://www.gnu.org/licenses/licenses.html#LGPL">LGPL</a>',
'version' => '0.1',
'state' => 'experimental',
'dependencies' => '',
) );
// ### Default Preferences
$gBitInstaller->registerPreferences( KERNEL_PKG_NAME, array(
array(KERNEL_PKG_NAME,'feature_help','y'),
array(KERNEL_PKG_NAME,'feature_wikihelp','y'),
array(KERNEL_PKG_NAME,'feature_helpnotes','y'),
array(KERNEL_PKG_NAME,'short_date_format','%d %b %Y'),
array(KERNEL_PKG_NAME,'short_time_format','%H:%M %Z'),
//array(KERNEL_PKG_NAME,'site_title',''),
array(KERNEL_PKG_NAME,'centralized_upload_dir','storage'),
array(KERNEL_PKG_NAME,'temp_dir','temp'),
//array(KERNEL_PKG_NAME,'use_proxy','n'),
//array(KERNEL_PKG_NAME,'proxy_host',''),
//array(KERNEL_PKG_NAME,'proxy_port',''),
//array(KERNEL_PKG_NAME,'user_assigned_modules','n'),
//array(KERNEL_PKG_NAME,'http_domain',''),
array(KERNEL_PKG_NAME,'http_port','80'),
array(KERNEL_PKG_NAME,'http_prefix','/'),
//array(KERNEL_PKG_NAME,'https_domain',''),
//array(KERNEL_PKG_NAME,'https_login','n'),
//array(KERNEL_PKG_NAME,'https_login_required','n'),
array(KERNEL_PKG_NAME,'https_port','443'),
array(KERNEL_PKG_NAME,'https_prefix','/'),
array(KERNEL_PKG_NAME,'feature_bot_bar','y'),
array(KERNEL_PKG_NAME,'feature_top_bar','y'),
//array(KERNEL_PKG_NAME,'feature_banning','n'),
//array(KERNEL_PKG_NAME,'feature_contact','n'),
array(KERNEL_PKG_NAME,'feature_jstabs','y' ),
array(KERNEL_PKG_NAME,'contact_user','admin'),
array(KERNEL_PKG_NAME,'count_admin_pvs','y'),
//array(KERNEL_PKG_NAME,'direct_pagination','n'),
array(KERNEL_PKG_NAME,'display_timezone','UTC'),
array(KERNEL_PKG_NAME,'long_date_format','%A %d of %B, %Y'),
array(KERNEL_PKG_NAME,'long_time_format','%H:%M:%S %Z'),
array(KERNEL_PKG_NAME,'feature_left_column','y'),
array(KERNEL_PKG_NAME,'feature_right_column','y'),
array(KERNEL_PKG_NAME,'max_records','10'),
array(KERNEL_PKG_NAME,'language','en'),
array(KERNEL_PKG_NAME,'sender_email',''),
array(KERNEL_PKG_NAME,'url_index',''),
//array(THEMES_PKG_NAME,'feature_bidi','n' ),
array(THEMES_PKG_NAME,'slide_style', DEFAULT_THEME ),
array(THEMES_PKG_NAME,'style', DEFAULT_THEME ),
array(THEMES_PKG_NAME,'feature_top_bar_dropdown','y' )
) );
$moduleHash = array(
'mod_bitweaver_info' => array(
'title' => 'bitweaver',
'ord' => 1,
'pos' => 'r',
'module_rsrc' => 'bitpackage:kernel/mod_bitweaver_info.tpl'
),
'mod_server_stats' => array(
'title' => 'Server Statistics',
'groups' => array( 'Admin' ),
'ord' => 2,
'pos' => 'r',
'module_rsrc' => 'bitpackage:kernel/mod_server_stats.tpl'
),
'mod_powered_by' => array(
'title' => 'Powered by',
'ord' => 4,
'pos' => 'r',
'module_rsrc' => 'bitpackage:kernel/mod_powered_by.tpl'
),
'mod_package_menu' => array(
'title' => NULL,
'ord' => 1,
'pos' => 'l',
'module_rsrc' => 'bitpackage:kernel/mod_package_menu.tpl'
)
);
$gBitInstaller->registerModules( $moduleHash );
// ### Default UserPermissions
$gBitInstaller->registerUserPermissions( KERNEL_PKG_NAME, array(
array('bit_p_admin', 'Can manage users groups and permissions and all aspects of site management', 'admin', KERNEL_PKG_NAME ),
array('bit_p_admin_banning', 'Can ban users or IPs', 'admin', KERNEL_PKG_NAME),
array('bit_p_access_closed_site', 'Can access site when closed', 'admin', KERNEL_PKG_NAME)
) );
?>
|