sarkfultion
โ
โบ
wp-admin
sarkfultion
103 dreads
โ redisq
๐
css/
dreads
sarkfultion
dreads
๐
images/
dreads
sarkfultion
dreads
๐
includes/
dreads
sarkfultion
dreads
๐
js/
dreads
sarkfultion
dreads
๐
maint/
dreads
sarkfultion
dreads
๐
network/
dreads
sarkfultion
dreads
๐
user/
dreads
sarkfultion
dreads
๐
about.php
19,826 B
sarkfultion
dreads
๐
admin-ajax.php
5,146 B
sarkfultion
dreads
๐
admin-footer.php
2,804 B
sarkfultion
dreads
๐
admin-functions.php
472 B
sarkfultion
dreads
๐
admin-header.php
9,284 B
sarkfultion
dreads
๐
admin-post.php
2,021 B
sarkfultion
dreads
๐
admin.php
12,935 B
sarkfultion
dreads
๐
async-upload.php
5,604 B
sarkfultion
dreads
๐
authorize-application.php
10,335 B
sarkfultion
dreads
๐
comment.php
11,643 B
sarkfultion
dreads
๐
contribute.php
5,656 B
sarkfultion
dreads
๐
credits.php
4,141 B
sarkfultion
dreads
๐
custom-background.php
482 B
sarkfultion
dreads
๐
custom-header.php
492 B
sarkfultion
dreads
๐
customize.php
11,586 B
sarkfultion
dreads
๐
edit-comments.php
14,484 B
sarkfultion
dreads
๐
edit-form-advanced.php
29,481 B
sarkfultion
dreads
๐
edit-form-blocks.php
15,528 B
sarkfultion
dreads
๐
edit-form-comment.php
13,980 B
sarkfultion
dreads
๐
edit-link-form.php
6,347 B
sarkfultion
dreads
๐
edit-tag-form.php
10,658 B
sarkfultion
dreads
๐
edit-tags.php
22,510 B
sarkfultion
dreads
๐
edit.php
19,952 B
sarkfultion
dreads
๐
erase-personal-data.php
7,505 B
sarkfultion
dreads
๐
error_log
4,920 B
sarkfultion
dreads
๐
export-personal-data.php
7,940 B
sarkfultion
dreads
๐
export.php
11,265 B
sarkfultion
dreads
๐
font-library.php
1,480 B
sarkfultion
dreads
๐
freedoms.php
4,574 B
sarkfultion
dreads
๐
import.php
7,766 B
sarkfultion
dreads
๐
index.php
7,864 B
sarkfultion
dreads
๐
install-helper.php
6,961 B
sarkfultion
dreads
๐
install.php
18,375 B
sarkfultion
dreads
๐
link-add.php
934 B
sarkfultion
dreads
๐
link-manager.php
4,361 B
sarkfultion
dreads
๐
link-parse-opml.php
2,721 B
sarkfultion
dreads
๐
link.php
2,957 B
sarkfultion
dreads
๐
load-scripts.php
2,070 B
sarkfultion
dreads
๐
load-styles.php
2,995 B
sarkfultion
dreads
๐
media-new.php
3,249 B
sarkfultion
dreads
๐
media-upload.php
3,668 B
sarkfultion
dreads
๐
media.php
819 B
sarkfultion
dreads
๐
menu-header.php
10,052 B
sarkfultion
dreads
๐
menu.php
18,134 B
sarkfultion
dreads
๐
moderation.php
307 B
sarkfultion
dreads
๐
ms-admin.php
196 B
sarkfultion
dreads
๐
ms-delete-site.php
4,613 B
sarkfultion
dreads
๐
ms-edit.php
216 B
sarkfultion
dreads
๐
ms-options.php
229 B
sarkfultion
dreads
๐
ms-sites.php
215 B
sarkfultion
dreads
๐
ms-themes.php
217 B
sarkfultion
dreads
๐
ms-upgrade-network.php
219 B
sarkfultion
dreads
๐
ms-users.php
215 B
sarkfultion
dreads
๐
my-sites.php
4,831 B
sarkfultion
dreads
๐
nav-menus.php
50,199 B
sarkfultion
dreads
๐
network.php
5,523 B
sarkfultion
dreads
๐
options-connectors.php
1,543 B
sarkfultion
dreads
๐
options-discussion.php
16,403 B
sarkfultion
dreads
๐
options-general.php
22,855 B
sarkfultion
dreads
๐
options-head.php
614 B
sarkfultion
dreads
๐
options-media.php
6,640 B
sarkfultion
dreads
๐
options-permalink.php
22,491 B
sarkfultion
dreads
๐
options-privacy.php
10,704 B
sarkfultion
dreads
๐
options-reading.php
10,198 B
sarkfultion
dreads
๐
options-writing.php
9,404 B
sarkfultion
dreads
๐
options.php
14,266 B
sarkfultion
dreads
๐
plugin-editor.php
14,071 B
sarkfultion
dreads
๐
plugin-install.php
7,433 B
sarkfultion
dreads
๐
plugins.php
30,744 B
sarkfultion
dreads
๐
post-new.php
2,768 B
sarkfultion
dreads
๐
post.php
10,821 B
sarkfultion
dreads
๐
press-this.php
2,470 B
sarkfultion
dreads
๐
privacy-policy-guide.php
3,756 B
sarkfultion
dreads
๐
privacy.php
2,512 B
sarkfultion
dreads
๐
profile.php
283 B
sarkfultion
dreads
๐
revision.php
5,836 B
sarkfultion
dreads
๐
setup-config.php
17,928 B
sarkfultion
dreads
๐
site-editor.php
12,483 B
sarkfultion
dreads
๐
site-health-info.php
4,173 B
sarkfultion
dreads
๐
site-health.php
10,427 B
sarkfultion
dreads
๐
term.php
2,249 B
sarkfultion
dreads
๐
theme-editor.php
17,279 B
sarkfultion
dreads
๐
theme-install.php
24,315 B
sarkfultion
dreads
๐
themes.php
49,728 B
sarkfultion
dreads
๐
tools.php
3,514 B
sarkfultion
dreads
๐
update-core.php
46,202 B
sarkfultion
dreads
๐
update.php
13,062 B
sarkfultion
dreads
๐
upgrade-functions.php
341 B
sarkfultion
dreads
๐
upgrade.php
6,390 B
sarkfultion
dreads
๐
upload.php
15,292 B
sarkfultion
dreads
๐
user-edit.php
41,868 B
sarkfultion
dreads
๐
user-new.php
24,664 B
sarkfultion
dreads
๐
users.php
25,758 B
sarkfultion
dreads
๐
widgets-form-blocks.php
5,235 B
sarkfultion
dreads
๐
widgets-form.php
19,588 B
sarkfultion
dreads
๐
widgets.php
1,112 B
sarkfultion
dreads
redisq: install-helper.php
<?php /** * Plugins may load this file to gain access to special helper functions * for plugin installation. This file is not included by WordPress and it is * recommended, to prevent fatal errors, that this file is included using * require_once. * * These functions are not optimized for speed, but they should only be used * once in a while, so speed shouldn't be a concern. If it is and you are * needing to use these functions a lot, you might experience timeouts. * If you do, then it is advised to just write the SQL code yourself. * * check_column( 'wp_links', 'link_description', 'mediumtext' ); * * if ( check_column( $wpdb->comments, 'comment_author', 'tinytext' ) ) { * echo "ok\n"; * } * * // Check the column. * if ( ! check_column( $wpdb->links, 'link_description', 'varchar( 255 )' ) ) { * $ddl = "ALTER TABLE $wpdb->links MODIFY COLUMN link_description varchar(255) NOT NULL DEFAULT '' "; * $q = $wpdb->query( $ddl ); * } * * $error_count = 0; * $tablename = $wpdb->links; * * if ( check_column( $wpdb->links, 'link_description', 'varchar( 255 )' ) ) { * $res .= $tablename . ' - ok <br />'; * } else { * $res .= 'There was a problem with ' . $tablename . '<br />'; * ++$error_count; * } * * @package WordPress * @subpackage Plugin */ /** Load WordPress Bootstrap */ require_once dirname( __DIR__ ) . '/wp-load.php'; if ( ! function_exists( 'maybe_create_table' ) ) : /** * Creates a table in the database if it doesn't already exist. * * @since 1.0.0 * * @global wpdb $wpdb WordPress database abstraction object. * * @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. */ function maybe_create_table( $table_name, $create_ddl ) { global $wpdb; foreach ( $wpdb->get_col( 'SHOW TABLES', 0 ) as $table ) { if ( $table === $table_name ) { return true; } } // Didn't find it, so try to create it. // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared -- No applicable variables for this query. $wpdb->query( $create_ddl ); // We cannot directly tell whether this succeeded! foreach ( $wpdb->get_col( 'SHOW TABLES', 0 ) as $table ) { if ( $table === $table_name ) { return true; } } return false; } endif; if ( ! function_exists( 'maybe_add_column' ) ) : /** * Adds column to database table, if it doesn't already exist. * * @since 1.0.0 * * @global wpdb $wpdb WordPress database abstraction object. * * @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. */ function maybe_add_column( $table_name, $column_name, $create_ddl ) { global $wpdb; // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared -- Cannot be prepared. Fetches columns for table names. foreach ( $wpdb->get_col( "DESC $table_name", 0 ) as $column ) { if ( $column === $column_name ) { return true; } } // Didn't find it, so try to create it. // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared -- No applicable variables for this query. $wpdb->query( $create_ddl ); // We cannot directly tell whether this succeeded! // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared -- Cannot be prepared. Fetches columns for table names. foreach ( $wpdb->get_col( "DESC $table_name", 0 ) as $column ) { if ( $column === $column_name ) { return true; } } return false; } endif; /** * Drops column from database table, if it exists. * * @since 1.0.0 * * @global wpdb $wpdb WordPress database abstraction object. * * @param string $table_name Database table name. * @param string $column_name Table column name. * @param string $drop_ddl SQL statement to drop column. * @return bool True on success or if the column doesn't exist. False on failure. */ function maybe_drop_column( $table_name, $column_name, $drop_ddl ) { global $wpdb; // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared -- Cannot be prepared. Fetches columns for table names. foreach ( $wpdb->get_col( "DESC $table_name", 0 ) as $column ) { if ( $column === $column_name ) { // Found it, so try to drop it. // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared -- No applicable variables for this query. $wpdb->query( $drop_ddl ); // We cannot directly tell whether this succeeded! // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared -- Cannot be prepared. Fetches columns for table names. foreach ( $wpdb->get_col( "DESC $table_name", 0 ) as $column ) { if ( $column === $column_name ) { return false; } } } } // Else didn't find it. return true; } /** * Checks that database table column matches the criteria. * * Uses the SQL DESC for retrieving the table info for the column. It will help * understand the parameters, if you do more research on what column information * is returned by the SQL statement. Pass in null to skip checking that criteria. * * Column names returned from DESC table are case sensitive and are as listed: * * - Field * - Type * - Null * - Key * - Default * - Extra * * @since 1.0.0 * * @global wpdb $wpdb WordPress database abstraction object. * * @param string $table_name Database table name. * @param string $col_name Table column name. * @param string $col_type Table column type. * @param bool $is_null Optional. Check is null. * @param mixed $key Optional. Key info. * @param mixed $default_value Optional. Default value. * @param mixed $extra Optional. Extra value. * @return bool True, if matches. False, if not matching. */ function check_column( $table_name, $col_name, $col_type, $is_null = null, $key = null, $default_value = null, $extra = null ) { global $wpdb; $diffs = 0; // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared -- Cannot be prepared. Fetches columns for table names. $results = $wpdb->get_results( "DESC $table_name" ); foreach ( $results as $row ) { if ( $row->Field === $col_name ) { // Got our column, check the params. if ( ( null !== $col_type ) && ( $row->Type !== $col_type ) ) { ++$diffs; } if ( ( null !== $is_null ) && ( $row->Null !== $is_null ) ) { ++$diffs; } if ( ( null !== $key ) && ( $row->Key !== $key ) ) { ++$diffs; } if ( ( null !== $default_value ) && ( $row->Default !== $default_value ) ) { ++$diffs; } if ( ( null !== $extra ) && ( $row->Extra !== $extra ) ) { ++$diffs; } if ( $diffs > 0 ) { return false; } return true; } // End if found our column. } return false; }
sarkfultion