Moved admin files to their own directory, trying to get a comprehensive structure in place

This commit is contained in:
2021-10-06 09:50:36 -06:00
parent 753aafe24d
commit bd6e3f2d60
7 changed files with 63 additions and 9 deletions

View File

@ -6,7 +6,7 @@ if ( ! defined( 'ABSPATH' ) ) {
exit;
}
class Settings {
class AdminSettings {
/**
* Class constructor.
@ -93,4 +93,4 @@ class Settings {
}
new Settings();
new AdminSettings();

17
admin/class-install.php Normal file
View File

@ -0,0 +1,17 @@
<?php
namespace PluginNamespace;
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
class Install {
private static $db_updates = array(
'1.1.0' => array(
'dh_update_110_options',
),
);
}

View File

@ -0,0 +1,18 @@
<?php
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
/**
* Update something in the database
*
* @since 1.1.0
*
* @return void
*/
function dh_update_110_options() {
global $wpdb;
// do the thing here to update the database
}