当前位置: 首页>>代码示例>>PHP>>正文


PHP Loc::getMsg方法代码示例

本文整理汇总了PHP中Bitrix\Main\Localization\Loc::getMsg方法的典型用法代码示例。如果您正苦于以下问题:PHP Loc::getMsg方法的具体用法?PHP Loc::getMsg怎么用?PHP Loc::getMsg使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Bitrix\Main\Localization\Loc的用法示例。


在下文中一共展示了Loc::getMsg方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: array

$days = array(Loc::getMsg("culture_su"), Loc::getMsg("culture_mo"), Loc::getMsg("culture_tu"), Loc::getMsg("culture_we"), Loc::getMsg("culture_th"), Loc::getMsg("culture_fr"), Loc::getMsg("culture_sa"));
while ($culture = $data->Fetch()) {
    $id = htmlspecialcharsbx($culture["ID"]);
    $name = htmlspecialcharsbx($culture["NAME"]);
    $row =& $adminList->AddRow($id, $culture, "culture_edit.php?ID=" . $id . "&lang=" . LANGUAGE_ID, Loc::getMsg("LANG_EDIT_TITLE"));
    $row->AddViewField("ID", $id);
    $row->AddField("NAME", '<a href="culture_edit.php?ID=' . $id . '&amp;lang=' . LANGUAGE_ID . '" title="' . Loc::getMsg("LANG_EDIT_TITLE") . '">' . $name . '</a>', $name);
    $row->AddInputField("CODE");
    $row->AddInputField("FORMAT_DATE");
    $row->AddInputField("FORMAT_DATETIME");
    $row->AddInputField("FORMAT_NAME");
    $row->AddViewField("WEEK_START", $days[$culture["WEEK_START"]]);
    $row->AddInputField("CHARSET");
    $row->AddViewField("DIRECTION", $culture["DIRECTION"] == Culture::LEFT_TO_RIGHT ? Loc::getMsg("culture_left_to_right") : Loc::getMsg("culture_right_to_left"));
    $arActions = array();
    $arActions[] = array("ICON" => "edit", "TEXT" => Loc::getMsg("CHANGE"), "ACTION" => $adminList->ActionRedirect("culture_edit.php?ID=" . $f_ID));
    if ($isAdmin) {
        $arActions[] = array("ICON" => "copy", "TEXT" => Loc::getMsg("COPY"), "ACTION" => $adminList->ActionRedirect("culture_edit.php?COPY_ID=" . $f_ID));
        $arActions[] = array("SEPARATOR" => true);
        $arActions[] = array("ICON" => "delete", "TEXT" => Loc::getMsg("DELETE"), "ACTION" => "if(confirm('" . Loc::getMsg('CONFIRM_DEL') . "')) " . $adminList->ActionDoGroup($f_ID, "delete"));
    }
    $row->AddActions($arActions);
}
$adminList->AddFooter(array(array("title" => GetMessage("MAIN_ADMIN_LIST_SELECTED"), "value" => $data->SelectedRowsCount()), array("counter" => true, "title" => GetMessage("MAIN_ADMIN_LIST_CHECKED"), "value" => "0")));
$adminList->AddGroupActionTable(array("delete" => GetMessage("MAIN_ADMIN_LIST_DELETE")));
$aContext = array(array("TEXT" => Loc::getMsg("ADD_LANG"), "LINK" => "culture_edit.php?lang=" . LANGUAGE_ID, "TITLE" => Loc::getMsg("ADD_LANG_TITLE"), "ICON" => "btn_new"));
$adminList->AddAdminContextMenu($aContext);
$adminList->CheckListMode();
require $_SERVER["DOCUMENT_ROOT"] . BX_ROOT . "/modules/main/include/prolog_admin_after.php";
$adminList->DisplayList();
require $_SERVER["DOCUMENT_ROOT"] . BX_ROOT . "/modules/main/include/epilog_admin.php";
开发者ID:nProfessor,项目名称:Mytb,代码行数:31,代码来源:culture_admin.php


注:本文中的Bitrix\Main\Localization\Loc::getMsg方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。