maybe_create_table [ WordPress Function ]
maybe_create_table ( $table_name, $create_ddl )
| Parameters: |
|
| Returns: |
|
| Defined at: |
|
Benzer Fonksiyonlar: wpmu_create_blog, wp_create_tag, wp_create_term, _maybe_update_themes, _maybe_update_core
{@internal Missing Short Description}}
{@internal Missing Long Description}}
Source
<?php
function maybe_create_table($table_name, $create_ddl) {
global $wpdb;
if ( $wpdb->get_var("SHOW TABLES LIKE '$table_name'") == $table_name )
return true;
//didn't find it try to create it.
$q = $wpdb->query($create_ddl);
// we cannot directly tell that whether this succeeded!
if ( $wpdb->get_var("SHOW TABLES LIKE '$table_name'") == $table_name )
return true;
return false;
}
?>
Examples [ wp-snippets.com ]
Google Arama Sonuçlarý
- WordPress › Support » dbDelta vs maybe_create_table()
Hello all,. I need to create a table for my plugin. I found two methods to create a table: dbDelta: as used in the Creating Tables with Plugins page on the codex ...
wordpress.org - #6747 (function maybe_create_table() declared in two files ...
The function maybe_create_table() is a nice helper for plugins that need to create a database table. As it is not available by default, one has to include the file ...
core.trac.wordpress.org - PHPXRef 0.7 : WordPress : Function Reference: maybe_create_table()
Function and Method Cross Reference. maybe_create_table(). Defined at: /wp- admin/includes/upgrade.php -> line 1316 · /wp-admin/install-helper.php -> line ...
phpxref.ftwr.co.uk - maybe_create_table (WordPress Function) - WPSeek.com
WordPress lookup for maybe_create_table, a WordPress Function. wpseek.com is a WordPress-centric search tool for developers and theme authors.
wpseek.com