本文整理汇总了PHP中langswitch_filter_langs_with_message函数的典型用法代码示例。如果您正苦于以下问题:PHP langswitch_filter_langs_with_message函数的具体用法?PHP langswitch_filter_langs_with_message怎么用?PHP langswitch_filter_langs_with_message使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了langswitch_filter_langs_with_message函数的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: i18n
/**
* Support for i18n with wpml, polyglot or qtrans
*
* @param string $in
* @param string $name (optional) required for wpml to determine the type of translation
* @return string $in localized
*/
static function i18n($in, $name = null)
{
if (function_exists('langswitch_filter_langs_with_message')) {
$in = langswitch_filter_langs_with_message($in);
}
if (function_exists('polyglot_filter')) {
$in = polyglot_filter($in);
}
if (function_exists('qtrans_useCurrentLanguageIfNotFoundUseDefaultLanguage')) {
$in = qtrans_useCurrentLanguageIfNotFoundUseDefaultLanguage($in);
}
if (is_string($name) && !empty($name) && function_exists('icl_translate')) {
$in = icl_translate('plugin_ngg', $name, $in, true);
}
$in = apply_filters('localization', $in);
return $in;
}
示例2: internationalize
function internationalize($in)
{
if (function_exists('langswitch_filter_langs_with_message')) {
$in = langswitch_filter_langs_with_message($in);
}
if (function_exists('polyglot_filter')) {
$in = polyglot_filter($in);
}
if (function_exists('qtrans_useCurrentLanguageIfNotFoundUseDefaultLanguage')) {
$in = qtrans_useCurrentLanguageIfNotFoundUseDefaultLanguage($in);
}
$in = apply_filters('localization', $in);
return $in;
}
示例3: internationalize
function internationalize($in)
{
if (function_exists('langswitch_filter_langs_with_message')) {
$in = langswitch_filter_langs_with_message($in);
}
if (function_exists('polyglot_filter')) {
$in = polyglot_filter($in);
}
return $in;
}