Tools_Page
Generates the Tools page.
Namespace: WebberZone\Top_Ten\Admin
Since: 3.3.0
Source: includes/admin/class-tools-page.php line 24
Methods
__construct()
Constructor class.
Since: 3.3.0
Line: 40
public function __construct( );
admin_menu()
Admin Menu.
Since: 3.3.0
Line: 58
public function admin_menu( );
network_admin_menu()
Admin Menu.
Since: 3.3.0
Line: 77
public function network_admin_menu( );
admin_enqueue_scripts()
Enqueue scripts in admin area.
Since: 3.3.0
Line: 98
public function admin_enqueue_scripts( $hook );
| Type | Name | Description |
|---|---|---|
string |
$hook |
The current admin page. |
render_page()
Render the tools settings page.
Since: 2.5.0
Line: 128
public function render_page( ): void;
Returns: void
recreate_primary_key() static
Function to delete and create the primary keys in the database table.
Since: 2.5.6
Line: 406
static public function recreate_primary_key( );
recreate_primary_key_html() static
Retrieves the SQL code to recreate the PRIMARY KEY.
Since: 2.5.7
Line: 436
static public function recreate_primary_key_html( );
recreate_tables() static
Retrieves the SQL code to recreate the PRIMARY KEY.
Since: 2.7.0
Line: 467
static public function recreate_tables( );
fix_crons() static
Clear and reschedule the Top 10 cron jobs.
Since: 4.4.0
Line: 504
static public function fix_crons( $network_wide = ... ): string|\WP_Error;
| Type | Name | Description |
|---|---|---|
bool |
$network_wide |
Whether to repair cron schedules for all active sites. |
Returns: string|\WP_Error — Success message or WP_Error if a job could not be rescheduled.
help_tabs() static
Generates the Tools help page.
Since: 3.3.0
Line: 654
static public function help_tabs( );
check_table_status() static
Check if tables exist and create them if they don’t.
Since: 4.2.0
Line: 697
static public function check_table_status( ): array;
Returns: array — Array of table statuses indicating whether they are installed.
get_db_status_report() static
Get database status report.
Since: 4.2.0
Line: 745
static public function get_db_status_report( ): string;
Returns: string — HTML output for the database status report.
handle_create_missing_tables_action() static
Handle the create-missing-tables GET action triggered from the admin notice.
Since: 4.3.0
Line: 886
static public function handle_create_missing_tables_action( );
handle_recreate_tables_action() static
Handle the recreate-tables GET action from the tools page.
Since: 4.1.0
Line: 931
static public function handle_recreate_tables_action( );