Translation_Entry::key()publicWP 1.0

Generates a unique key for this entry.

{} Это метод класса: Translation_Entry{}

Хуков нет.

Возвращает

Строку|false. The key or false if the entry is null.

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

$Translation_Entry = new Translation_Entry();
$Translation_Entry->key();

Код Translation_Entry::key() WP 6.1.1

public function key() {
	if ( null === $this->singular ) {
		return false;
	}

	// Prepend context and EOT, like in MO files.
	$key = ! $this->context ? $this->singular : $this->context . "\4" . $this->singular;
	// Standardize on \n line endings.
	$key = str_replace( array( "\r\n", "\r" ), "\n", $key );

	return $key;
}