WPDev.one

_nc()

_nc( mixed $single, mixed $plural, mixed $number, mixed $domain = 'default' )

Legacy version of _n(), which supports contexts.

Parameters 4 required

Name / Type Description
$single
string

The text to be used if the number is singular.

Required
$plural
string

The text to be used if the number is plural.

Required
$number
int

The number to compare against to use either the singular or plural form.

Required
string

$domain Optional. Text domain. Unique identifier for retrieving translated strings. Default 'default'.

Required

Return Value

(string)
The translated singular or plural form.

Function Information

Since Version
2.7.0
Source File
wp-includes/deprecated.php
Advertisement