[ Index ] |
PHP Cross Reference of WordPress |
[Source view] [Print] [Project Stats]
WordPress Upgrade API Most of the functions are pluggable and can be overwritten.
File Size: | 3564 lines (110 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
wp_install( $blog_title, $user_name, $user_email, $is_public, $deprecated = '', $user_password = '', $language = '' ) X-Ref |
Installs the site. Runs the required functions to set up and populate the database, including primary admin user and initial options. param: string $blog_title Site title. param: string $user_name User's username. param: string $user_email User's email. param: bool $is_public Whether the site is public. param: string $deprecated Optional. Not used. param: string $user_password Optional. User's chosen password. Default empty (random password). param: string $language Optional. Language chosen. Default empty. return: array { since: 2.1.0 |
wp_install_defaults( $user_id ) X-Ref |
Creates the initial content for a newly-installed site. Adds the default "Uncategorized" category, the first post (with comment), first page, and default widgets for default theme for the current version. param: int $user_id User ID. since: 2.1.0 |
wp_install_maybe_enable_pretty_permalinks() X-Ref |
Maybe enable pretty permalinks on installation. If after enabling pretty permalinks don't work, fallback to query-string permalinks. return: bool Whether pretty permalinks are enabled. False otherwise. since: 4.2.0 |
wp_new_blog_notification( $blog_title, $blog_url, $user_id, $password ) X-Ref |
Notifies the site admin that the installation of WordPress is complete. Sends an email to the new administrator that the installation is complete and provides them with a record of their login credentials. param: string $blog_title Site title. param: string $blog_url Site URL. param: int $user_id Administrator's user ID. param: string $password Administrator's password. Note that a placeholder message is since: 2.1.0 |
wp_upgrade() X-Ref |
Runs WordPress Upgrade functions. Upgrades the database if needed during a site update. since: 2.1.0 |
upgrade_all() X-Ref |
Functions to be called in installation and upgrade scripts. Contains conditional checks to determine which upgrade scripts to run, based on database version and WP version being updated-to. since: 1.0.1 |
upgrade_100() X-Ref |
Execute changes made in WordPress 1.0. since: 1.0.0 |
upgrade_101() X-Ref |
Execute changes made in WordPress 1.0.1. since: 1.0.1 |
upgrade_110() X-Ref |
Execute changes made in WordPress 1.2. since: 1.2.0 |
upgrade_130() X-Ref |
Execute changes made in WordPress 1.5. since: 1.5.0 |
upgrade_160() X-Ref |
Execute changes made in WordPress 2.0. since: 2.0.0 |
upgrade_210() X-Ref |
Execute changes made in WordPress 2.1. since: 2.1.0 |
upgrade_230() X-Ref |
Execute changes made in WordPress 2.3. since: 2.3.0 |
upgrade_230_options_table() X-Ref |
Remove old options from the database. since: 2.3.0 |
upgrade_230_old_tables() X-Ref |
Remove old categories, link2cat, and post2cat database tables. since: 2.3.0 |
upgrade_old_slugs() X-Ref |
Upgrade old slugs made in version 2.2. since: 2.2.0 |
upgrade_250() X-Ref |
Execute changes made in WordPress 2.5.0. since: 2.5.0 |
upgrade_252() X-Ref |
Execute changes made in WordPress 2.5.2. since: 2.5.2 |
upgrade_260() X-Ref |
Execute changes made in WordPress 2.6. since: 2.6.0 |
upgrade_270() X-Ref |
Execute changes made in WordPress 2.7. since: 2.7.0 |
upgrade_280() X-Ref |
Execute changes made in WordPress 2.8. since: 2.8.0 |
upgrade_290() X-Ref |
Execute changes made in WordPress 2.9. since: 2.9.0 |
upgrade_300() X-Ref |
Execute changes made in WordPress 3.0. since: 3.0.0 |
upgrade_330() X-Ref |
Execute changes made in WordPress 3.3. since: 3.3.0 |
upgrade_340() X-Ref |
Execute changes made in WordPress 3.4. since: 3.4.0 |
upgrade_350() X-Ref |
Execute changes made in WordPress 3.5. since: 3.5.0 |
upgrade_370() X-Ref |
Execute changes made in WordPress 3.7. since: 3.7.0 |
upgrade_372() X-Ref |
Execute changes made in WordPress 3.7.2. since: 3.7.2 |
upgrade_380() X-Ref |
Execute changes made in WordPress 3.8.0. since: 3.8.0 |
upgrade_400() X-Ref |
Execute changes made in WordPress 4.0.0. since: 4.0.0 |
upgrade_420() X-Ref |
Execute changes made in WordPress 4.2.0. since: 4.2.0 |
upgrade_430() X-Ref |
Executes changes made in WordPress 4.3.0. since: 4.3.0 |
upgrade_430_fix_comments() X-Ref |
Executes comments changes made in WordPress 4.3.0. since: 4.3.0 |
upgrade_431() X-Ref |
Executes changes made in WordPress 4.3.1. since: 4.3.1 |
upgrade_440() X-Ref |
Executes changes made in WordPress 4.4.0. since: 4.4.0 |
upgrade_450() X-Ref |
Executes changes made in WordPress 4.5.0. since: 4.5.0 |
upgrade_460() X-Ref |
Executes changes made in WordPress 4.6.0. since: 4.6.0 |
upgrade_500() X-Ref |
Executes changes made in WordPress 5.0.0. since: 5.0.0 |
upgrade_510() X-Ref |
Executes changes made in WordPress 5.1.0. since: 5.1.0 |
upgrade_530() X-Ref |
Executes changes made in WordPress 5.3.0. since: 5.3.0 |
upgrade_550() X-Ref |
Executes changes made in WordPress 5.5.0. since: 5.5.0 |
upgrade_560() X-Ref |
Executes changes made in WordPress 5.6.0. since: 5.6.0 |
upgrade_590() X-Ref |
Executes changes made in WordPress 5.9.0. since: 5.9.0 |
upgrade_600() X-Ref |
Executes changes made in WordPress 6.0.0. since: 6.0.0 |
upgrade_network() X-Ref |
Executes network-level upgrade routines. since: 3.0.0 |
maybe_create_table( $table_name, $create_ddl ) X-Ref |
Creates a table in the database, if it doesn't already exist. This method checks for an existing database and creates a new one if it's not already present. It doesn't rely on MySQL's "IF NOT EXISTS" statement, but chooses to query all tables first and then run the SQL statement creating the table. param: string $table_name Database table name. param: string $create_ddl SQL statement to create table. return: bool True on success or if the table already exists. False on failure. since: 1.0.0 |
drop_index( $table, $index ) X-Ref |
Drops a specified index from a table. param: string $table Database table name. param: string $index Index name to drop. return: true True, when finished. since: 1.0.1 |
add_clean_index( $table, $index ) X-Ref |
Adds an index to a specified table. param: string $table Database table name. param: string $index Database table index column. return: true True, when done with execution. since: 1.0.1 |
maybe_add_column( $table_name, $column_name, $create_ddl ) X-Ref |
Adds column to a database table, if it doesn't already exist. param: string $table_name Database table name. param: string $column_name Table column name. param: string $create_ddl SQL statement to add column. return: bool True on success or if the column already exists. False on failure. since: 1.3.0 |
maybe_convert_table_to_utf8mb4( $table ) X-Ref |
If a table only contains utf8 or utf8mb4 columns, convert it to utf8mb4. param: string $table The table to convert. return: bool True if the table was converted, false if it wasn't. since: 4.2.0 |
get_alloptions_110() X-Ref |
Retrieve all options as it was for 1.2. return: stdClass List of options. since: 1.2.0 |
__get_option( $setting ) X-Ref |
Utility version of get_option that is private to installation/upgrade. param: string $setting Option name. return: mixed since: 1.5.1 |
deslash( $content ) X-Ref |
Filters for content to remove unnecessary slashes. param: string $content The content to modify. return: string The de-slashed content. since: 1.5.0 |
dbDelta( $queries = '', $execute = true ) X-Ref |
Modifies the database based on specified SQL statements. Useful for creating new tables and updating existing tables to a new structure. param: string[]|string $queries Optional. The query to run. Can be multiple queries param: bool $execute Optional. Whether or not to execute the query right away. return: array Strings containing the results of the various update queries. since: 1.5.0 |
make_db_current( $tables = 'all' ) X-Ref |
Updates the database tables to a new schema. By default, updates all the tables to use the latest defined schema, but can also be used to update a specific set of tables in wp_get_db_schema(). param: string $tables Optional. Which set of tables to update. Default is 'all'. since: 1.5.0 |
make_db_current_silent( $tables = 'all' ) X-Ref |
Updates the database tables to a new schema, but without displaying results. By default, updates all the tables to use the latest defined schema, but can also be used to update a specific set of tables in wp_get_db_schema(). param: string $tables Optional. Which set of tables to update. Default is 'all'. since: 1.5.0 |
make_site_theme_from_oldschool( $theme_name, $template ) X-Ref |
Creates a site theme from an existing theme. {@internal Missing Long Description}} param: string $theme_name The name of the theme. param: string $template The directory name of the theme. return: bool since: 1.5.0 |
make_site_theme_from_default( $theme_name, $template ) X-Ref |
Creates a site theme from the default theme. {@internal Missing Long Description}} param: string $theme_name The name of the theme. param: string $template The directory name of the theme. return: void|false since: 1.5.0 |
make_site_theme() X-Ref |
Creates a site theme. {@internal Missing Long Description}} return: string|false since: 1.5.0 |
translate_level_to_role( $level ) X-Ref |
Translate user level to user role name. param: int $level User level. return: string User role name. since: 2.0.0 |
wp_check_mysql_version() X-Ref |
Checks the version of the installed MySQL binary. since: 2.1.0 |
maybe_disable_automattic_widgets() X-Ref |
Disables the Automattic widgets plugin, which was merged into core. since: 2.2.0 |
maybe_disable_link_manager() X-Ref |
Disables the Link Manager on upgrade if, at the time of upgrade, no links exist in the DB. since: 3.5.0 |
pre_schema_upgrade() X-Ref |
Runs before the schema is upgraded. since: 2.9.0 |
install_global_terms() X-Ref |
Install global terms. since: 3.0.0 |
wp_should_upgrade_global_tables() X-Ref |
Determine if global tables should be upgraded. This function performs a series of checks to ensure the environment allows for the safe upgrading of global WordPress database tables. It is necessary because global tables will commonly grow to millions of rows on large installations, and the ability to control their upgrade routines can be critical to the operation of large networks. In a future iteration, this function may use `wp_is_large_network()` to more- intelligently prevent global table upgrades. Until then, we make sure WordPress is on the main site of the main network, to avoid running queries more than once in multi-site or multi-network environments. return: bool Whether to run the upgrade routines on global tables. since: 4.3.0 |
Generated: Sun Dec 22 01:00:02 2024 | Cross-referenced by PHPXref 0.7.1 |