Yoast\WP\Lib

Model::get_table_name()public staticYoast 1.0

Exposes method to get the table name to use.

Метод класса: Model{}

Хуков нет.

Возвращает

Строку. Prepared full table name.

Использование

$result = Model::get_table_name( $table_name, $yoast_prefix );
$table_name(строка) (обязательный)
Simple table name.
$yoast_prefix(true|false)
True to prefix the table name with the Yoast prefix.
По умолчанию: true

Код Model::get_table_name() Yoast 22.4

public static function get_table_name( $table_name, $yoast_prefix = true ) {
	global $wpdb;

	// Allow the use of WordPress internal tables.
	if ( $yoast_prefix ) {
		$table_name = 'yoast_' . $table_name;
	}

	return $wpdb->prefix . \strtolower( $table_name );
}