src/Translator.php
public static function extractPluralsForms($header)
    {
        $headers = explode("\n", $header);
        $expr = 'nplurals=2; plural=n == 1 ? 0 : 1;';
        foreach ($headers as $header) {
            if (stripos($header, 'Plural-Forms:') === 0) {
                $expr = substr($header, 13);
            }
        }

        return $expr;
    }
public static function extractPluralsForms($header)
    {
        $headers = explode("\n", $header);
        $expr = 'nplurals=2; plural=n == 1 ? 0 : 1;';
        foreach ($headers as $header) {
            if (stripos($header, 'Plural-Forms:') === 0) {
                $expr = substr($header, 13);
            }
        }

        return $expr;
    }
public static function extractPluralsForms ( $ header ) { $ headers = explode ( "\n" , $ header ) ; $ expr = 'nplurals=2; plural=n == 1 ? 0 : 1;' ; foreach ( $ headers as $ header ) { if ( stripos ( $ header , 'Plural-Forms:' ) === 0 ) { $ expr = substr ( $ header , 13 ) ; } } return $ expr ; }
Parse full PO header and extract only plural forms line.

@param string $header Gettext header

@return string verbatim plural form header field
Parse full PO header and extract only plural forms line .