Overview

Packages

  • Translation

Classes

  • Horde_Translation
  • Horde_Translation_Handler_Gettext

Interfaces

  • Horde_Translation_Handler

Exceptions

  • Horde_Translation_Exception
  • Overview
  • Package
  • Class
  • Tree

Class Horde_Translation_Handler_Gettext

The Horde_Translation_Handler_Gettext provides translations through the gettext extension, but fails gracefully if gettext is not installed.

Horde_Translation_Handler_Gettext implements Horde_Translation_Handler
Package: Translation
Author: Jan Schneider jan@horde.org
Located at Horde/Translation/Handler/Gettext.php
Methods summary
public
# __construct( string $domain, string $path )

Constructor.

Constructor.

Parameters

$domain
The translation domain, e.g. package name.
$path
The path to the gettext catalog.
public string
# t( string $message )

Returns the translation of a message.

Returns the translation of a message.

Parameters

$message
The string to translate.

Returns

string

The string translation, or the original string if no translation exists.

Implementation of

Horde_Translation_Handler::t()
public string
# ngettext( string $singular, string $plural, integer $number )

Returns the plural translation of a message.

Returns the plural translation of a message.

Parameters

$singular
The singular version to translate.
$plural
The plural version to translate.
$number
The number that determines singular vs. plural.

Returns

string

The string translation, or the original string if no translation exists.

Implementation of

Horde_Translation_Handler::ngettext()
API documentation generated by ApiGen