apply_filters( 'pre_get_table_charset', string|WP_Error|null $charset, string $table )

Filters the table charset value before the DB is checked.


Description

Returning a non-null value from the filter will effectively short-circuit checking the DB for the charset, returning that value instead.


Parameters

$charset

The character set to use, WP_Error object if it couldn't be found. Default null.

$table

The name of the table being checked.


Source

File: wp-includes/class-wpdb.php

View on GitHub



Changelog

Changelog
Version Description
4.2.0 Introduced.