本文整理汇总了PHP中Sections::get_radio_buttons方法的典型用法代码示例。如果您正苦于以下问题:PHP Sections::get_radio_buttons方法的具体用法?PHP Sections::get_radio_buttons怎么用?PHP Sections::get_radio_buttons使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Sections
的用法示例。
在下文中一共展示了Sections::get_radio_buttons方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: array
$input = ARTICLES_UNPUBLISH_IMG . i18n::s('not published');
}
$fields[] = array($label, $input);
// the expiry date
$label = i18n::s('Expiry date');
if (isset($item['expiry_date']) && $item['expiry_date'] > NULL_DATE) {
$input = Surfer::from_GMT($item['expiry_date']);
} else {
$input = i18n::s('never');
}
$fields[] = array($label, $input);
// the parent section
if (is_object($anchor)) {
if (isset($item['id']) && Articles::is_owned($item, $anchor)) {
$label = i18n::s('Section');
$input =& Skin::build_box(i18n::s('Select parent container'), Sections::get_radio_buttons($anchor->get_reference()), 'folded');
$fields[] = array($label, $input);
} else {
$text .= '<input type="hidden" name="anchor" value="' . $anchor->get_reference() . '" />';
}
}
// append fields
if (is_object($anchor)) {
$label = sprintf(i18n::s('Contribution to "%s"'), $anchor->get_title());
} else {
$label = i18n::s('Contribution to parent container');
}
$text .= Skin::build_box($label, Skin::build_form($fields), 'folded');
$fields = array();
// the source
$label = i18n::s('Source');
示例2: array
$input = Skin::build_input_time('expiry_date', $value, 'date_time');
$hint = i18n::s('Remove content on dead-line - automatically');
$fields[] = array($label, $input, $hint);
// provide my id
$me = isset($item['id']) ? $item['id'] : NULL;
// reference to parent section
$ref = is_object($anchor) ? $anchor->get_reference() : NULL;
// associates can anchor the section anywhere
if (Surfer::is_associate()) {
$label = i18n::s('Section');
$input =& Skin::build_box(i18n::s('Select parent container'), Sections::get_radio_buttons($ref, $me), 'folded');
$fields[] = array($label, $input);
// parent section is defined and surfer is an editor of it
} elseif (is_object($anchor) && $anchor->is_assigned()) {
$label = i18n::s('Section');
$input =& Skin::build_box(i18n::s('Select parent container'), Sections::get_radio_buttons($ref, $me), 'folded');
$fields[] = array($label, $input);
// preserve the existing anchor
} else {
$text .= '<input type="hidden" name="anchor" value="' . $anchor->get_reference() . '" />';
}
// append fields
$parent .= Skin::build_form($fields);
$fields = array();
// append fields
if (is_object($anchor)) {
$label = sprintf(i18n::s('Contribution to "%s"'), $anchor->get_title());
} else {
$label = i18n::s('Appearance at the site map');
}
$text .= Skin::build_box($label, $parent, 'folded');