本文整理汇总了PHP中ca_lists::getLabelForDisplay方法的典型用法代码示例。如果您正苦于以下问题:PHP ca_lists::getLabelForDisplay方法的具体用法?PHP ca_lists::getLabelForDisplay怎么用?PHP ca_lists::getLabelForDisplay使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ca_lists
的用法示例。
在下文中一共展示了ca_lists::getLabelForDisplay方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getHierarchyName
/**
* Returns name of hierarchy for currently loaded item or, if specified, item with item_id = to optional $pn_id parameter
*/
public function getHierarchyName($pn_id = null)
{
if ($pn_id) {
$t_item = new ca_list_items($pn_id);
$vn_hierarchy_id = $t_item->get('list_id');
} else {
$vn_hierarchy_id = $this->get('list_id');
}
$t_list = new ca_lists($vn_hierarchy_id);
return $t_list->getLabelForDisplay(false);
}
示例2: join
if (is_array($va_list) && sizeof($va_list)) {
print $va_setting_info['label'] . " = " . join("; ", $va_list) . "<br/>\n";
}
break;
case 'relationship_type':
case 'restrict_to_relationship_types':
if (!is_array($vs_setting_value)) {
$vs_setting_value = array($vs_setting_value);
}
if (is_array($va_list = $t_rel->relationshipTypeListToTypeCodes($t_relationship->tableName(), $vs_setting_value)) && sizeof($va_list)) {
print $va_setting_info['label'] . " = " . join("; ", $va_list) . "<br/>\n";
}
break;
case 'list':
if ($t_list->load($vs_setting_value)) {
print $va_setting_info['label'] . " = " . $t_list->getLabelForDisplay() . " [" . $t_list->get('list_code') . "]<br/>\n";
}
break;
default:
if (is_array($vs_setting_value) && sizeof($vs_setting_value)) {
print $va_setting_info['label'] . " = " . join("; ", $vs_setting_value) . "<br/>\n";
} else {
if (strlen($vs_setting_value)) {
print $va_setting_info['label'] . " = " . $vs_setting_value . "<br/>\n";
}
}
break;
}
}
?>
</td>