ona  18.1.1
About: OpenNetAdmin provides a database managed inventory of your IP network (with Web and CLI interface).
  Fossies Dox: ona-18.1.1.tar.gz  ("inofficial" and yet experimental doxygen-generated source code documentation)  

install.php File Reference

Go to the source code of this file.

Variables

 $base = dirname(__FILE__)
 
 $text = ''
 
 $status = 0
 
 $onabase = dirname($base)
 
 $runinstall = $onabase.'/www/local/config/run_install'
 
 $xmlfile_tables = $base.'/ona-table_schema.xml'
 
 $xmlfile_data = $base.'/ona-data.xml'
 
 $license_text = file_get_contents($base.'/../docs/LICENSE')
 
 $new_ver = trim(file_get_contents($onabase.'/VERSION'))
 
 $curr_ver = ''
 
 $phpversion = phpversion() > '5.0' ? 'Yes' : '<font color="red">No</font>'
 
 $hasgmp = function_exists( 'gmp_init' ) ? 'Yes' : '<font color="red">No</font>'
 
 $hasmysql = function_exists( 'mysqli_connect' ) ? 'Yes' : 'Recommended'
 
 $hasmbstring = function_exists( 'mb_internal_encoding' ) ? 'Yes' : 'Recommended'
 
 $dbconfwrite = @is_writable($onabase.'/www/local/config/') ? 'Yes' : '<font color="red">No</font>'
 
 $blankmain = "<script>el('main').style.display = 'none';</script>"
 
 $licensediv
 
nbsp {$record['ip_mask']} (/{$record['ip_subnet_mask_cidr']})&nbsp
 
< a style="text-decoration: none;" href="/">< input class='edit' type="button" value="I don't like free stuff?" onclick=""/></a ></center ></div > EOL
 
 $requisitediv
 
 $greet_txt = "It looks as though this is your first time running OpenNetAdmin. Please answer a few questions and we'll initialize the system for you. We've pre-populated some of the fields with suggested values. If the database you specify below already exists, it will be overwritten entirely."
 
 $upgrademain = ''
 
if(!is_array($ona_contexts) and is_array($db_context)) if(@file_exists($dbconffile)) $main
 
 input2text = '<b>Database Admin:</b> The username for the database administrator. This account will be used to create the new database and must have proper privledges to do so.'
 
 input3text = '<b>Database Admin Password:</b> The password for the database administrator account.'
 
 input4text = '<b>Database Name:</b> The name of the database that will store the OpenNetAdmin tables. We suggest "default", which will become "ona_default" when created.'
 
 input5text = '<b>System User Name:</b> The application username used by the php code to connect to the database. We suggest "ona_sys"'
 
 input6text = '<b>System User Password:</b> The password for the application user.'
 
 input7text = '<b>Default Domain Name:</b> The default DNS domain for your site. This will be your primary domain to add hosts to and will serve the default domain for certain tasks.'
 
 inputtext_dbtype = '<b>Database Type:</b> The type of database running on the database host.'
 
n n $ona_contexts =".var_export($ona_contexts,TRUE)."
 

Variable Documentation

◆ $base

$base = dirname(__FILE__)

Definition at line 8 of file install.php.

◆ $blankmain

$blankmain = "<script>el('main').style.display = 'none';</script>"

Definition at line 28 of file install.php.

◆ $curr_ver

$curr_ver = ''

Definition at line 19 of file install.php.

◆ $dbconfwrite

$dbconfwrite = @is_writable($onabase.'/www/local/config/') ? 'Yes' : '<font color="red">No</font>'

Definition at line 26 of file install.php.

Referenced by check_requirements().

◆ $greet_txt

$greet_txt = "It looks as though this is your first time running OpenNetAdmin. Please answer a few questions and we'll initialize the system for you. We've pre-populated some of the fields with suggested values. If the database you specify below already exists, it will be overwritten entirely."

Definition at line 57 of file install.php.

◆ $hasgmp

$hasgmp = function_exists( 'gmp_init' ) ? 'Yes' : '<font color="red">No</font>'

Definition at line 23 of file install.php.

Referenced by check_requirements().

◆ $hasmbstring

$hasmbstring = function_exists( 'mb_internal_encoding' ) ? 'Yes' : 'Recommended'

Definition at line 25 of file install.php.

Referenced by check_requirements().

◆ $hasmysql

$hasmysql = function_exists( 'mysqli_connect' ) ? 'Yes' : 'Recommended'

Definition at line 24 of file install.php.

Referenced by check_requirements().

◆ $license_text

$license_text = file_get_contents($base.'/../docs/LICENSE')

Definition at line 17 of file install.php.

◆ $licensediv

$licensediv
Initial value:
= <<<EOL
<div id="license">
<center><b>OpenNetAdmin is released under the following license:</b></center>
<textarea class="edit" rows="25" cols="75">{$license_text}</textarea><br><br>
<center>
<input class='edit' type="button" value="I Agree!" onclick="el('work').style.display = '';el('input1').focus();el('license').style.display = 'none';" />&nbsp

Definition at line 31 of file install.php.

◆ $main

if (!is_array( $ona_contexts) and is_array( $db_context)) if ( @file_exists( $dbconffile)) $main

Definition at line 158 of file install.php.

◆ $new_ver

$new_ver = trim(file_get_contents($onabase.'/VERSION'))

Definition at line 18 of file install.php.

◆ $ona_contexts

n n xml version n n $ona_contexts =".var_export($ona_contexts,TRUE)."

Definition at line 354 of file install.php.

Referenced by db_pconnect(), new_install(), upgrade(), and ws_switch_context().

◆ $onabase

$onabase = dirname($base)

Definition at line 13 of file install.php.

◆ $phpversion

$phpversion = phpversion() > '5.0' ? 'Yes' : '<font color="red">No</font>'

Definition at line 22 of file install.php.

Referenced by check_requirements().

◆ $requisitediv

$requisitediv
Initial value:
= <<<EOL
<div id="checksdiv">
<table id="checks">
<tr><th colspan="5">Prerequisite checks</th></tr>
<tr><td>PHP version > 5.0:</td><td>{$phpversion}</td></tr>
<tr title="The PHP mysqli database modules are used to connect to mysql databases"><td>PHP mysqli support:</td><td>{$hasmysql}</td></tr>
<tr title="The PHP GMP modules are required for IPv6 support."><td>Has GMP support:</td><td>{$hasgmp}</td></tr>
<tr title="The PHP mbstring modules provide better text encoding for UTF etc, but are not required."><td>Has mbstring support:</td><td>{$hasmbstring}</td></tr>
<tr title="The local config directory must be writable by the web server user: {$_ENV['APACHE_RUN_USER']}"><td>{$onabase}/www/local/config dir writable by '{$_ENV['APACHE_RUN_USER']}':</td><td>{$dbconfwrite}</td></tr>
</table>
</div>

Definition at line 43 of file install.php.

◆ $runinstall

$runinstall = $onabase.'/www/local/config/run_install'

Definition at line 14 of file install.php.

◆ $status

$status = 0

Definition at line 12 of file install.php.

Referenced by add_module(), add_permission(), block_add(), block_del(), block_display(), block_modify(), auth_local\checkPass(), config_add(), config_chksum(), config_display(), custom_attribute_add(), custom_attribute_del(), custom_attribute_display(), custom_attribute_modify(), custom_attribute_type_display(), dhcp_entry_add(), dhcp_entry_del(), dhcp_entry_display(), dhcp_entry_modify(), dhcp_failover_group_add(), dhcp_failover_group_del(), dhcp_failover_group_display(), dhcp_failover_group_modify(), dhcp_pool_add(), dhcp_pool_del(), dhcp_pool_modify(), dhcp_server_add(), dhcp_server_del(), dns_record_add(), dns_record_del(), dns_record_display(), dns_record_modify(), domain_add(), domain_del(), domain_display(), domain_modify(), domain_server_add(), domain_server_del(), find_config(), format_array(), get_a_record_suggestions(), get_class_c_html(), get_custom_attribute_info_html(), get_domain_suggestions(), get_host_interface_list_html(), get_host_suggestions(), get_interface_cluster_list_html(), get_ip_suggestions(), get_ipv6_64_html(), get_message_lines_html(), get_module_list(), get_perms(), get_subnet_html(), get_subnet_usage(), get_text_suggestions(), auth_local\getUserData(), host_add(), host_del(), host_display(), host_modify(), interface_add(), interface_del(), interface_display(), interface_modify(), interface_move(), interface_move_host(), interface_share(), interface_share_del(), load_module(), location_add(), location_del(), location_modify(), message_add(), nat_add(), nat_del(), ona_build_domain_name(), ona_find_config(), ona_find_custom_attribute(), ona_find_device(), ona_find_device_type(), ona_find_dhcp_option(), ona_find_dns_record(), ona_find_domain(), ona_find_host(), ona_find_interface(), ona_find_location(), ona_find_subnet(), ona_find_subnet_type(), ona_find_vlan(), ona_get_config_record(), ona_get_custom_attribute_record(), ona_get_dhcp_option_entry_record(), ona_get_dns_record(), ona_get_domain_record(), ona_get_host_record(), ona_get_interface_record(), ona_get_model_record(), ona_get_next_id(), ona_get_subnet_record(), ona_get_vlan_record(), printmsg(), quick_free_ip_search(), quick_interface_move(), quick_pool_server_search(), quick_search(), quick_subnet_search(), report_run(), rpt_get_data(), rpt_output_html(), rpt_output_text(), rpt_run(), run_module(), sess_destroy(), sess_gc(), sess_read(), sess_write(), subnet_add(), subnet_del(), subnet_display(), subnet_modify(), subnet_nextip(), tag_add(), tag_del(), vlan_add(), vlan_campus_add(), vlan_campus_del(), vlan_campus_display(), vlan_campus_modify(), vlan_del(), vlan_modify(), ws_change_user_password(), ws_delete(), ws_delete_config(), ws_delete_configs(), ws_display(), ws_display_config(), ws_display_list(), ws_editor(), ws_enablerecord(), ws_free_ip(), ws_interface_move_save(), ws_interface_nat_save(), ws_interface_share_del(), ws_interface_share_save(), ws_location(), ws_logingo(), ws_makeprimary(), ws_more_host_options(), ws_process_alerts_submit(), ws_run_report(), ws_save(), ws_search_results_submit(), ws_subnet(), ws_tag_html(), and ws_vlan().

◆ $text

◆ $upgrademain

$upgrademain = ''

Definition at line 60 of file install.php.

◆ $xmlfile_data

$xmlfile_data = $base.'/ona-data.xml'

Definition at line 16 of file install.php.

◆ $xmlfile_tables

$xmlfile_tables = $base.'/ona-table_schema.xml'

Definition at line 15 of file install.php.

◆ EOL

◆ input2text

input2text = '<b>Database Admin:</b> The username for the database administrator. This account will be used to create the new database and must have proper privledges to do so.'

Definition at line 197 of file install.php.

◆ input3text

input3text = '<b>Database Admin Password:</b> The password for the database administrator account.'

Definition at line 198 of file install.php.

◆ input4text

input4text = '<b>Database Name:</b> The name of the database that will store the OpenNetAdmin tables. We suggest "default", which will become "ona_default" when created.'

Definition at line 199 of file install.php.

◆ input5text

input5text = '<b>System User Name:</b> The application username used by the php code to connect to the database. We suggest "ona_sys"'

Definition at line 200 of file install.php.

◆ input6text

input6text = '<b>System User Password:</b> The password for the application user.'

Definition at line 201 of file install.php.

◆ input7text

input7text = '<b>Default Domain Name:</b> The default DNS domain for your site. This will be your primary domain to add hosts to and will serve the default domain for certain tasks.'

Definition at line 202 of file install.php.

◆ inputtext_dbtype

inputtext_dbtype = '<b>Database Type:</b> The type of database running on the database host.'

Definition at line 203 of file install.php.

◆ nbsp

$hasmbstring
$hasmbstring
Definition: install.php:25
$hasmysql
$hasmysql
Definition: install.php:24
$license_text
$license_text
Definition: install.php:17
onclick
_button onclick
Definition: app_advanced_search.inc.php:50
EOL
< a style="text-decoration: none;" href="/">< input class='edit' type="button" value="I don't like free stuff?" onclick=""/></a ></center ></div > EOL
Definition: install.php:40
nbsp
& nbsp
Definition: install.php:36
$onabase
$onabase
Definition: install.php:13
$dbconfwrite
$dbconfwrite
Definition: install.php:26
$phpversion
$phpversion
Definition: install.php:22
$hasgmp
$hasgmp
Definition: install.php:23