Public Member Functions | Static Public Member Functions

InstallHandler Class Reference

Inheritance diagram for InstallHandler:
Collaboration diagram for InstallHandler:

List of all members.

Public Member Functions

 act_begin_install ()
 get_plugins ()
 get_themes ()
 form_defaults ()
 check_mysql ()
 check_pgsql ()
 activate_theme ()
 activate_plugins ()
 htaccess ()
 check_htaccess ()
 write_htaccess ($exists=false, $update=false, $rewritebase=true)
 sqlite_contents ()
 secure_sqlite ()
 upgrade_db ()
 upgrade_db_post_5111 ()
 upgrade_db_post_5112 ()
 ajax_check_mysql_credentials ()
 ajax_check_pgsql_credentials ()
 ajax_check_sqlite_credentials ()

Static Public Member Functions

static get_feature_list ($features)

Detailed Description

The class which responds to installer actions

Definition at line 14 of file installhandler.php.


Member Function Documentation

InstallHandler::act_begin_install (  ) 

Entry point for installation. The reason there is a begin_install method to handle is that conceivably, the user can stop installation mid-install and need an alternate entry point action at a later time.

Set user selected Locale or default

Check .htaccess first because ajax doesn't work without it.

Add the AJAX hooks

Let's check the config.php file if no POST data was submitted

Definition at line 22 of file installhandler.php.

InstallHandler::ajax_check_mysql_credentials (  ) 

Validate database credentials for MySQL Try to connect and verify if database name exists

Definition at line 1874 of file installhandler.php.

Referenced by act_begin_install().

InstallHandler::ajax_check_pgsql_credentials (  ) 

Validate database credentials for PostgreSQL Try to connect and verify if database name exists

Definition at line 1945 of file installhandler.php.

Referenced by act_begin_install().

InstallHandler::ajax_check_sqlite_credentials (  ) 

Validate database credentials for SQLite Try to connect and verify if database name exists

Definition at line 2016 of file installhandler.php.

Referenced by act_begin_install().

InstallHandler::check_htaccess (  ) 

checks for the presence of an .htaccess file invokes write_htaccess() as needed

Definition at line 1095 of file installhandler.php.

Referenced by act_begin_install().

InstallHandler::check_mysql (  ) 

Validate database credentials for MySQL Try to connect and verify if database name exists

Definition at line 549 of file installhandler.php.

InstallHandler::check_pgsql (  ) 

Validate database credentials for PostgreSQL Try to connect and verify if database name exists

Definition at line 582 of file installhandler.php.

static InstallHandler::get_feature_list ( features  )  [static]

Return a comma-separated list of features, given a SimpleXMLElement

Parameters:
\SimpleXMLElement $features An element containing children of <feature>
Returns:
string A comma-separated list of those features

Definition at line 2135 of file installhandler.php.

Referenced by get_plugins().

InstallHandler::get_plugins (  ) 

Helper function to grab list of plugins

Definition at line 204 of file installhandler.php.

InstallHandler::get_themes (  ) 

Helper function to grab list of themes

Definition at line 251 of file installhandler.php.

InstallHandler::htaccess (  ) 

returns an array of .htaccess declarations used by Habari

Definition at line 1069 of file installhandler.php.

Referenced by act_begin_install().

InstallHandler::secure_sqlite (  ) 

attempts to write the Files clause to the .htaccess file if the clause for this sqlite doesn't exist.

Returns:
bool success or failure

Definition at line 1222 of file installhandler.php.

Referenced by act_begin_install().

InstallHandler::sqlite_contents (  ) 

returns an array of Files declarations used by Habari

Definition at line 1202 of file installhandler.php.

Referenced by act_begin_install().

InstallHandler::upgrade_db (  ) 

Upgrade the database when the database version stored is lower than the one in source

Todo:
Make more db-independent

Definition at line 1391 of file installhandler.php.

InstallHandler::write_htaccess ( exists = false,
update = false,
rewritebase = true 
)

attempts to write the .htaccess file if none exists or to write the Habari-specific portions to an existing .htaccess

Parameters:
bool whether an .htaccess file already exists or not
bool whether to remove and re-create any existing Habari block
bool whether to try a rewritebase in the .htaccess

Definition at line 1152 of file installhandler.php.


The documentation for this class was generated from the following file: