本文整理汇总了PHP中html_radio_field函数的典型用法代码示例。如果您正苦于以下问题:PHP html_radio_field函数的具体用法?PHP html_radio_field怎么用?PHP html_radio_field使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了html_radio_field函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: build_form_href
function build_form_href($array_tree, $ref = '')
{
$entry_string = '';
if (is_array($array_tree)) {
foreach ($array_tree as $key => $entry) {
$new_ref = $ref . $key;
$entry_string .= '<table border="0" cellpadding="1" cellspacing="1"><tr>' . chr(10);
if (isset($entry['children'])) {
$entry_string .= '<td><a id="rpt_' . $new_ref . '" href="javascript:Toggle(\'' . $new_ref . '\');">';
$entry_string .= html_icon('status/folder-open.png', TEXT_EXPAND, 'small', $params = 'hspace="0" vspace="0"') . '</a>';
} else {
$entry_string .= '<td>' . html_radio_field('id', 'f' . $key, false);
}
$entry_string .= ' ' . $entry['desc'] . '</td>' . chr(10);
$entry_string .= '</tr></table>' . chr(10);
if (isset($entry['children'])) {
$entry_string .= '<div id="' . $new_ref . '" style="display:none; margin-left:1em;">' . chr(10) . chr(10);
$entry_string .= build_form_href($entry['children'], $new_ref) . chr(10);
$entry_string .= '</div>' . chr(10);
}
}
}
return $entry_string;
}
开发者ID:jigsmaheta,项目名称:puerto-argentino,代码行数:24,代码来源:builder_functions.php
示例2: html_radio_field
<?php
echo html_radio_field('TruncLongDesc', '0', $FormParams['Prefs']['trunclong'] != '1' ? true : false) . TEXT_NO;
?>
</td>
</tr>
<tr>
<td><?php
echo RW_TEXT_TOTAL_ONLY;
?>
</td>
<td colspan="4">
<?php
echo html_radio_field('TotalOnly', '1', $FormParams['Prefs']['totalonly'] == '1' ? true : false) . TEXT_YES;
?>
<?php
echo html_radio_field('TotalOnly', '0', $FormParams['Prefs']['totalonly'] != '1' ? true : false) . TEXT_NO;
?>
</td>
</tr>
<?php
} else {
// for forms
?>
<tr>
<td><?php
echo RW_FRM_SET_PRINTED . '<sup>1</sup>';
$notes .= '<br /><sup>1 </sup>' . RW_FRM_SET_PRINTED_NOTE;
?>
</td>
<td colspan="4"><?php
echo html_pull_down_menu('SetPrintedFlag', $kFields, $FormParams['Prefs']['setprintedflag']);
开发者ID:jigsmaheta,项目名称:puerto-argentino,代码行数:31,代码来源:template_crit_setup.php
示例3: create_row
function create_row($array)
{
global $odd, $settings;
if (!empty($array['submenu']) && $array['text'] != BOX_HEADING_CONFIGURATION) {
foreach ($array['submenu'] as $menu_item) {
create_row($menu_item);
}
} else {
if ($array['security_id'] == '') {
return;
}
// && $item['heading'] <> MENU_HEADING_TOOLS) continue; // special case for reports listings not in Tools menu
$checked = array();
if ($array['show_in_users_settings'] === false) {
return;
// skip if menu only item
} elseif (isset($settings[$array['security_id']])) {
$checked[0] = false;
$checked[$settings[$array['security_id']]] = true;
} elseif ($error) {
$checked[0] = false;
$checked[$_POST['sID_' . $array['security_id']]] = true;
} else {
$checked[0] = true;
// default to no access
}
echo '<tr valign="top" class="' . ($odd ? 'odd' : 'even') . '">';
echo '<td>' . $array['text'] . '</td>' . chr(10);
echo '<td align="center">' . html_radio_field('sID_' . $array['security_id'], '4', $checked[4]) . '</td>' . chr(10);
echo '<td align="center">' . html_radio_field('sID_' . $array['security_id'], '3', $checked[3]) . '</td>' . chr(10);
echo '<td align="center">' . html_radio_field('sID_' . $array['security_id'], '2', $checked[2]) . '</td>' . chr(10);
echo '<td align="center">' . html_radio_field('sID_' . $array['security_id'], '1', $checked[1]) . '</td>' . chr(10);
echo '<td align="center">' . html_radio_field('sID_' . $array['security_id'], '0', $checked[0]) . '</td></tr>' . chr(10);
$odd = !$odd;
}
}
开发者ID:siwiwit,项目名称:PhreeBooksERP,代码行数:36,代码来源:template_detail.php
示例4: html_radio_field
echo html_radio_field('entry_type', $value = 'time', $cInfo->entry_type == 'time' ? true : false, '', $system_disable ? ' disabled ' : '');
echo ' ' . TEXT_TIME;
?>
</td>
<td class="main"> </td>
</tr>
<tr>
<td class="main" valign="top">
<?php
echo html_radio_field('entry_type', $value = 'date_time', $cInfo->entry_type == 'date_time' ? true : false, '', $system_disable ? ' disabled ' : '');
echo ' ' . INV_LABEL_DATE_TIME_FIELD;
?>
</td>
<td class="main"> </td>
</tr>
<tr>
<td class="main" valign="top">
<?php
echo html_radio_field('entry_type', $value = 'time_stamp', $cInfo->entry_type == 'time_stamp' ? true : false, '', $system_disable ? ' disabled ' : '');
echo ' ' . INV_LABEL_TIME_STAMP_FIELD;
?>
</td>
<td class="main"><?php
echo INV_LABEL_TIME_STAMP_VALUE;
?>
</td>
</tr>
</table></td>
</tr>
</table>
</form>
开发者ID:jigsmaheta,项目名称:puerto-argentino,代码行数:31,代码来源:template_detail.php
示例5: html_radio_field
<tr>
<td> <?php
echo html_radio_field('conv_type', 'so', true, '', '') . ($jID == 3 ? ORD_CONVERT_TO_PO : ORD_CONVERT_TO_SO) . chr(10);
?>
</td>
<td><?php
echo ($jID == 3 ? ORD_HEADING_NUMBER_4 : ORD_HEADING_NUMBER_10) . html_input_field('so_num', $so_num, '') . '<br />' . chr(10);
?>
</td>
</tr>
<?php
if ($jID != 3) {
?>
<tr>
<td><?php
echo html_radio_field('conv_type', 'inv', false, '', '') . ORD_CONVERT_TO_INV . '<br />' . chr(10);
?>
</td>
<td><?php
echo ORD_HEADING_NUMBER_12 . html_input_field('inv_num', $inv_num, '') . '<br />' . chr(10);
?>
</td>
</tr>
<?php
}
?>
</tbody>
</table>
<?php
echo ORD_SO_INV_MESSAGE;
?>
开发者ID:siwiwit,项目名称:PhreeBooksERP,代码行数:31,代码来源:template_main.php
示例6: html_radio_field
</tr>
<tr>
<td><?php
echo RW_FORM_DELIVERY_METHOD;
?>
</td>
<td align="center"><?php
echo RW_BROWSER . html_radio_field('delivery_method', 'I', $delivery_method == 'I' ? true : false, '', 'onclick="hideEmail();"', false);
?>
</td>
<td align="center"><?php
echo RW_DOWNLOAD . html_radio_field('delivery_method', 'D', $delivery_method == 'D' ? true : false, '', 'onclick="hideEmail();"', false);
?>
</td>
<td align="center"><?php
echo TEXT_EMAIL . html_radio_field('delivery_method', 'S', $delivery_method == 'S' ? true : false, '', 'onclick="hideEmail();"', false);
?>
</td>
</tr>
<?php
if ($Prefs['dateselect'] != '') {
// show the date choices only if form requires it
?>
<tr>
<th colspan="2"> </th>
<th align="center"><?php
echo TEXT_FROM;
?>
</th>
<th align="center"><?php
echo TEXT_TO;
开发者ID:jigsmaheta,项目名称:puerto-argentino,代码行数:31,代码来源:template_filter.php
示例7: html_checkbox_field
?>
<tr>
<td><?php
echo html_checkbox_field($mod, '1', !in_array($mod, $core_modules) && $error && !isset($_POST[$mod]) ? false : true, '', in_array($mod, $core_modules) ? 'disabled="disabled"' : '') . ' ' . TEXT_MODULE . ': ' . $mod;
?>
</td>
<td align="center"><?php
echo html_radio_field($mod . '_action', 'core', $_POST[$mod . '_action'] == 'core' ? true : false, '', $parameters = '');
?>
</td>
<td align="center"><?php
echo html_radio_field($mod . '_action', 'demo', $_POST[$mod . '_action'] == 'demo' ? true : false, '', $parameters = '');
?>
</td>
<td align="center"><?php
echo html_radio_field($mod . '_action', 'data', !isset($_POST[$mod . '_action']) || $_POST[$mod . '_action'] == 'data' ? true : false, '', $parameters = '');
?>
</td>
</tr>
<?php
}
?>
</table>
</fieldset>
<fieldset>
<legend><?php
echo SETUP_CO_MGR_DEL_CO;
?>
</legend>
<table>
<tr>
开发者ID:siwiwit,项目名称:PhreeBooksERP,代码行数:31,代码来源:template_tab_manager.php
示例8: html_radio_field
?>
<fieldset class="formAreaTitle">
<legend><?php
echo ACT_CATEGORY_PAYMENT_TERMS;
?>
</legend>
<table border="0" width="100%" cellspacing="0" cellpadding="1">
<tr>
<td class="main">
<?php
echo html_radio_field('special_terms', 0, $terms[0] == '0' || $terms[0] == '' ? true : false, '', 'onclick="changeOptions()"') . ACT_TERMS_USE_DEFAULTS . '<br />' . chr(10);
echo html_radio_field('special_terms', 1, $terms[0] == '1' ? true : false, '', 'onclick="changeOptions()"') . ACT_COD_SHORT . '<br />' . chr(10);
echo html_radio_field('special_terms', 2, $terms[0] == '2' ? true : false, '', 'onclick="changeOptions()"') . ACT_PREPAID . '<br />' . chr(10);
echo html_radio_field('special_terms', 3, $terms[0] == '3' ? true : false, '', 'onclick="changeOptions()"') . ACT_SPECIAL_TERMS . '<br />' . chr(10);
echo html_radio_field('special_terms', 4, $terms[0] == '4' ? true : false, '', 'onclick="changeOptions()"') . ACT_DAY_NEXT_MONTH . '<br />' . chr(10);
echo html_radio_field('special_terms', 5, $terms[0] == '5' ? true : false, '', 'onclick="changeOptions()"') . ACT_END_OF_MONTH . chr(10);
?>
</td>
<td class="main" valign="top">
<?php
// terms[3] may contain either the net days or a date, set the defaults
if ($terms[0] == '4' || $terms[0] == '5') {
$net_terms = constant($terms_type . '_NUM_DAYS_DUE');
$date_terms = $terms[3];
} else {
$net_terms = $terms[3] != '' ? $terms[3] : constant($terms_type . '_NUM_DAYS_DUE');
$date_terms = '';
}
echo TEXT_CURRENT . ' - ' . gen_terms_to_language($cInfo->special_terms, false, $terms_type) . '<br />' . chr(10);
echo ACT_DISCOUNT . html_input_field('early_percent', $terms[1] != '' ? $terms[1] : constant($terms_type . '_PREPAYMENT_DISCOUNT_PERCENT'), 'size="4"') . ACT_EARLY_DISCOUNT . '<br />' . chr(10);
echo ACT_DUE_IN . html_input_field('early_days', $terms[2] != '' ? $terms[2] : constant($terms_type . '_PREPAYMENT_DISCOUNT_DAYS'), 'size="3"') . ACT_TERMS_EARLY_DAYS . '<br />' . chr(10);
开发者ID:jigsmaheta,项目名称:puerto-argentino,代码行数:31,代码来源:template_v_general.php
示例9: html_pull_down_menu
echo RW_RPT_PGLAYOUT;
?>
</th>
</tr>
<tr>
<td colspan="4" width="50%" align="center">
<?php
echo TEXT_PAPER . ' ' . html_pull_down_menu('papersize', gen_build_pull_down($PaperSizes), $myrow['papersize']);
?>
</td>
<td colspan="4" width="50%" align="center">
<?php
echo TEXT_ORIEN . ' ' . html_radio_field('paperorientation', 'P', $myrow['paperorientation'] == 'P' ? true : false) . ' ' . TEXT_PORTRAIT;
?>
<?php
echo ' ' . html_radio_field('paperorientation', 'L', $myrow['paperorientation'] == 'L' ? true : false) . ' ' . TEXT_LANDSCAPE;
?>
</td>
</tr>
<tr>
<th colspan="8"><?php
echo RW_RPT_PGMARGIN;
?>
</th>
</tr>
<tr>
<td colspan="2" width="25%" align="center"><?php
echo TEXT_TOP . ' ' . html_input_field('margintop', $myrow['margintop'], 'size="5" maxlength="3"') . ' ' . TEXT_MM;
?>
</td>
<td colspan="2" width="25%" align="center"><?php
开发者ID:jigsmaheta,项目名称:puerto-argentino,代码行数:31,代码来源:template_page_setup.php
示例10: array
echo '</tr>';
echo '<tr><td valign="top">';
$report_types_heading = array('0' => RW_RPT_MYRPT, '1' => RW_RPT_DEFRPT);
foreach ($report_types_heading as $standard => $fieldset_title) {
echo '<fieldset><legend>' . $fieldset_title . '</legend>';
$definitions->Move(0);
$definitions->MoveNext();
while (!$definitions->EOF) {
$report_id = $definitions->fields['id'];
if (!isset($rr_security[$report_id])) {
$rr_security[$report_id] = 'u:0;e:0;d:0';
// enable everyone if security not set
}
if (security_check($rr_security[$report_id])) {
if ($definitions->fields['groupname'] == $key && $definitions->fields['standard_report'] == $standard) {
echo html_radio_field('id', 'r' . $report_id, false);
echo ' ' . stripslashes($definitions->fields['description']) . '<br />' . chr(10);
}
}
$definitions->MoveNext();
}
echo '</fieldset>' . chr(10);
}
echo '</td>' . chr(10);
// show form list
$temp = build_form_href($form_array[$key]['children'], 'rpt_' . $key);
if ($temp) {
echo '<td valign="top"><fieldset>' . $temp . '</fieldset></td>' . chr(10);
} else {
echo '<td valign="top"> </td>' . chr(10);
}
开发者ID:jigsmaheta,项目名称:puerto-argentino,代码行数:31,代码来源:template_main.php
示例11: html_radio_field
?>
</td>
</tr>
<tr class="ui-widget-header"><th colspan="3"><?php
echo TEXT_OPTIONS;
?>
</th></tr>
<tr>
<td colspan="3"><?php
echo html_radio_field('dl_type', 'file', true, '', '') . GEN_BACKUP_DB_ONLY;
?>
</td>
</tr>
<tr>
<td colspan="3"><?php
echo html_radio_field('dl_type', 'dir', false, '', '') . GEN_BACKUP_FULL;
?>
</td>
</tr>
<tr>
<td colspan="2"><?php
echo html_checkbox_field('save_local', '1', false, '', '') . GEN_BACKUP_SAVE_LOCAL;
?>
</td>
<td align="right"><?php
echo html_button_field('backup_db', GEN_BACKUP_ICON_TITLE, 'onclick="submitToDo(\'save\', true)"');
?>
</td>
</tr>
</tbody>
</table>
开发者ID:siwiwit,项目名称:PhreeBooksERP,代码行数:31,代码来源:template_main.php
示例12: foreach
$show_active = false;
foreach ($tab_groups as $key => $value) {
$active = !$show_active ? ' class="active"' : '';
echo '<li><a href="#' . $key . '"' . $active . '>' . $value . '</a></li>' . chr(10);
$show_active = true;
}
?>
</ul>
<?php
$query_raw = "select id, group_id, custom, security, title, description, table_name\r\n\tfrom " . TABLE_IMPORT_EXPORT . " order by group_id";
$definitions = $db->Execute($query_raw);
foreach ($tab_groups as $key => $value) {
echo '<div id="' . $key . '" class="tabset_content">' . chr(10);
echo '<h2 class="tabset_label">' . $value . '</h2>' . chr(10);
$definitions->Move(0);
$definitions->MoveNext();
while (!$definitions->EOF) {
if ($definitions->fields['group_id'] == $key) {
echo html_radio_field('id', $definitions->fields['id'], false, '', '');
echo $definitions->fields['title'] . ' - ' . $definitions->fields['description'] . chr(10);
echo '<br />';
}
$definitions->MoveNext();
}
echo '</div>' . chr(10);
}
?>
</td>
</tr>
</table>
</form>
开发者ID:jigsmaheta,项目名称:puerto-argentino,代码行数:31,代码来源:template_main.php
示例13: build_form_html
function build_form_html($action, $id = '')
{
global $db;
require_once DIR_FS_MODULES . 'phreebooks/functions/phreebooks.php';
$tax_authorities_array = gen_build_tax_auth_array();
if ($action != 'new' && $this->error == false) {
$sql = "select description_short, description_long, rate_accounts, freight_taxable \n\t from " . $this->db_table . " where tax_rate_id = " . $id;
$result = $db->Execute($sql);
foreach ($result->fields as $key => $value) {
$this->{$key} = $value;
}
}
$output = '<table style="border-collapse:collapse;margin-left:auto; margin-right:auto;">' . chr(10);
$output .= ' <thead class="ui-widget-header">' . "\n";
$output .= ' <tr>' . chr(10);
$output .= ' <th colspan="2">' . ($action == 'new' ? SETUP_HEADING_NEW_TAX_RATE : SETUP_HEADING_EDIT_TAX_RATE) . '</th>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' </thead>' . "\n";
$output .= ' <tbody class="ui-widget-content">' . "\n";
$output .= ' <tr>' . chr(10);
$output .= ' <td colspan="2">' . ($action == 'new' ? SETUP_TAX_INSERT_INTRO : SETUP_TAX_EDIT_INTRO) . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . SETUP_INFO_DESC_SHORT . '</td>' . chr(10);
$output .= ' <td>' . html_input_field('description_short', $this->description_short, 'size="16" maxlength="15"') . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . SETUP_INFO_DESC_LONG . '</td>' . chr(10);
$output .= ' <td>' . html_input_field('description_long', $this->description_long, 'size="33" maxlength="64"') . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . SETUP_INFO_TAX_AUTHORITIES . '</td>' . chr(10);
$output .= ' <td>' . html_hidden_field('rate_accounts', $this->rate_accounts) . $this->draw_tax_auths($this->rate_accounts, $tax_authorities_array) . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . SETUP_INFO_TAX_AUTH_ADD . '</td>' . chr(10);
$output .= ' <td>' . html_pull_down_menu('tax_auth_id_add', $this->get_tax_auths()) . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . SETUP_INFO_TAX_AUTH_DELETE . '</td>' . chr(10);
$output .= ' <td>' . html_pull_down_menu('tax_auth_id_delete', $this->get_selected_tax_auths($this->rate_accounts, $tax_authorities_array)) . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . SETUP_INFO_FREIGHT_TAXABLE . '</td>' . chr(10);
$output .= ' <td>' . html_radio_field('freight_taxable', '0', !$this->freight_taxable) . TEXT_NO . html_radio_field('freight_taxable', '1', $this->freight_taxable) . TEXT_YES . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' </tbody>' . "\n";
$output .= '</table>' . chr(10);
return $output;
}
开发者ID:siwiwit,项目名称:PhreeBooksERP,代码行数:50,代码来源:tax_rates.php
示例14: build_form_html
//.........这里部分代码省略.........
$output .= ' <td>' . TEXT_DESCRIPTION . '</td>' . chr(10);
$output .= ' <td>' . html_input_field('description', $this->description, 'size="65" maxlength="64"') . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . TEXT_SORT_ORDER . '</td>' . chr(10);
$output .= ' <td>' . html_input_field('sort_order', $this->sort_order, 'size="65" maxlength="64"') . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . TEXT_GROUP . '</td>' . chr(10);
$output .= ' <td>' . html_input_field('group_by', $this->group_by, 'size="65" maxlength="64"') . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
if (is_array($this->type_array)) {
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . $this->type_desc . '</td>' . chr(10);
$output .= ' <td>';
while ($type = array_shift($this->type_array)) {
if (!is_array($choices)) {
$output .= html_checkbox_field('type_' . $type['id'], true, false, '', '') . $type['text'];
$output .= '<br />';
} elseif (in_array($type['id'], $choices)) {
$output .= html_checkbox_field('type_' . $type['id'], true, true, '', '') . $type['text'];
$output .= '<br />';
} else {
$output .= html_checkbox_field('type_' . $type['id'], true, false, '', '') . $type['text'];
$output .= '<br />';
}
}
$output .= ' </td>';
$output .= '</tr>' . chr(10);
}
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . INV_CATEGORY_MEMBER . '</td>' . chr(10);
$output .= ' <td>' . html_pull_down_menu('tab_id', $tab_list, $this->tab_id, $disabled) . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr class="ui-widget-header">' . chr(10);
$output .= ' <th colspan="2">' . TEXT_PROPERTIES . '</th>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>';
$output .= html_radio_field('entry_type', 'text', $this->entry_type == 'text' ? true : false, '', $disabled) . ' ' . INV_LABEL_TEXT_FIELD . '<br />';
$output .= html_radio_field('entry_type', 'html', $this->entry_type == 'html' ? true : false, '', $disabled) . ' ' . INV_LABEL_HTML_TEXT_FIELD . '</td>' . chr(10);
$output .= ' <td>' . INV_LABEL_MAX_NUM_CHARS;
$output .= '<br />' . html_input_field('length', $this->length ? $this->length : DEFAULT_TEXT_LENGTH, $readonly . 'size="10" maxlength="9"');
$output .= '<br />' . INV_LABEL_DEFAULT_TEXT_VALUE . '<br />' . INV_LABEL_MAX_255;
$output .= '<br />' . html_textarea_field('text_default', 35, 6, $this->text_default, $readonly);
$output .= ' </td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr class="ui-widget-content">' . chr(10);
$output .= ' <td>';
$output .= html_radio_field('entry_type', 'hyperlink', $this->entry_type == 'hyperlink' ? true : false, '', $disabled) . ' ' . INV_LABEL_HYPERLINK . '<br />';
$output .= html_radio_field('entry_type', 'image_link', $this->entry_type == 'image_link' ? true : false, '', $disabled) . ' ' . INV_LABEL_IMAGE_LINK . '<br />';
$output .= html_radio_field('entry_type', 'inventory_link', $this->entry_type == 'inventory_link' ? true : false, '', $disabled) . ' ' . INV_LABEL_INVENTORY_LINK;
$output .= ' </td>' . chr(10);
$output .= ' <td>' . INV_LABEL_FIXED_255_CHARS;
$output .= '<br />' . INV_LABEL_DEFAULT_TEXT_VALUE;
$output .= '<br />' . html_textarea_field('link_default', 35, 3, $this->link_default, $readonly);
$output .= ' </td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . html_radio_field('entry_type', 'integer', $this->entry_type == 'integer' ? true : false, '', $disabled) . ' ' . INV_LABEL_INTEGER_FIELD . '</td>' . chr(10);
$output .= ' <td>' . INV_LABEL_INTEGER_RANGE;
$output .= '<br />' . html_pull_down_menu('integer_range', gen_build_pull_down($integer_lengths), $this->integer_range, $disabled);
$output .= '<br />' . INV_LABEL_DEFAULT_TEXT_VALUE . html_input_field('integer_default', $this->integer_default, $readonly . 'size="16"');
$output .= ' </td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr class="ui-widget-content">' . chr(10);
$output .= ' <td>' . html_radio_field('entry_type', 'decimal', $this->entry_type == 'decimal' ? true : false, '', $disabled) . ' ' . INV_LABEL_DECIMAL_FIELD . '</td>' . chr(10);
$output .= ' <td>' . INV_LABEL_DECIMAL_RANGE;
$output .= html_pull_down_menu('decimal_range', gen_build_pull_down($decimal_lengths), $this->decimal_range, $disabled);
$output .= '<br />' . INV_LABEL_DEFAULT_DISPLAY_VALUE . html_input_field('decimal_display', $this->decimal_display ? $this->decimal_display : DEFAULT_REAL_DISPLAY_FORMAT, $readonly . 'size="6" maxlength="5"');
$output .= '<br />' . INV_LABEL_DEFAULT_TEXT_VALUE . html_input_field('decimal_default', $this->decimal_default, $readonly . 'size="16"');
$output .= ' </td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>';
$output .= html_radio_field('entry_type', 'multi_check_box', $this->entry_type == 'multi_check_box' ? true : false, '', $disabled) . ' ' . INV_LABEL_MULTI_SELECT_FIELD . '<br />';
$output .= html_radio_field('entry_type', 'drop_down', $this->entry_type == 'drop_down' ? true : false, '', $disabled) . ' ' . INV_LABEL_DROP_DOWN_FIELD . '<br />';
$output .= html_radio_field('entry_type', 'data_list', $this->entry_type == 'data_list' ? true : false, '', $disabled) . ' ' . TEXT_DATA_LIST . '<br />';
$output .= html_radio_field('entry_type', 'radio', $this->entry_type == 'radio' ? true : false, '', $disabled) . ' ' . INV_LABEL_RADIO_FIELD;
$output .= ' </td>' . chr(10);
$output .= ' <td>' . INV_LABEL_CHOICES . '<br />' . html_textarea_field('radio_default', 35, 6, $this->radio_default, $readonly) . '<br />';
$output .= INV_LABEL_RADIO_EXPLANATION . '<br />' . TEXT_DATA_LIST_EXPLANATION . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr class="ui-widget-content">' . chr(10);
$output .= ' <td>' . html_radio_field('entry_type', 'check_box', $this->entry_type == 'check_box' ? true : false, '', $disabled) . ' ' . INV_LABEL_CHECK_BOX_FIELD . '</td>' . chr(10);
$output .= ' <td>' . INV_LABEL_DEFAULT_TEXT_VALUE . html_pull_down_menu('check_box_range', gen_build_pull_down($check_box_choices), $this->check_box_range, $disabled) . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>';
$output .= html_radio_field('entry_type', 'date', $this->entry_type == 'date' ? true : false, '', $disabled) . ' ' . TEXT_DATE . '<br />';
$output .= html_radio_field('entry_type', 'time', $this->entry_type == 'time' ? true : false, '', $disabled) . ' ' . TEXT_TIME . '<br />';
$output .= html_radio_field('entry_type', 'date_time', $this->entry_type == 'date_time' ? true : false, '', $disabled) . ' ' . INV_LABEL_DATE_TIME_FIELD . '<br />';
$output .= html_radio_field('entry_type', 'time_stamp', $this->entry_type == 'time_stamp' ? true : false, '', $disabled) . ' ' . INV_LABEL_TIME_STAMP_FIELD;
$output .= ' </td>' . chr(10);
$output .= ' <td>' . INV_LABEL_TIME_STAMP_VALUE . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' </tbody>' . "\n";
$output .= '</table>' . chr(10);
return $output;
}
开发者ID:siwiwit,项目名称:PhreeBooksERP,代码行数:101,代码来源:fields.php
示例15: html_radio_field
<?php
echo html_radio_field('truncate', '0', $report->truncate != '1' ? true : false) . TEXT_NO;
?>
</td>
</tr>
<tr>
<td><?php
echo TEXT_TOTAL_ONLY;
?>
</td>
<td>
<?php
echo html_radio_field('totalonly', '1', $report->totalonly == '1' ? true : false) . TEXT_YES;
?>
<?php
echo html_radio_field('totalonly', '0', $report->totalonly != '1' ? true : false) . TEXT_NO;
?>
</td>
</tr>
<?php
} elseif ($report->reporttype == 'frm') {
?>
<tr>
<td><?php
echo PHREEFORM_SERIAL_FORM;
?>
</td>
<td><?php
echo html_checkbox_field('serialform', '1', $report->serialform ? true : false, '', '');
?>
</td>
开发者ID:siwiwit,项目名称:PhreeBooksERP,代码行数:31,代码来源:tab_prop_setup.php
示例16: build_field_entry
function build_field_entry($param_array, $cInfo)
{
$output = '<tr><td class="main">' . $param_array['description'] . '</td>';
$params = unserialize($param_array['params']);
switch ($params['type']) {
case 'text':
case 'html':
if ($params['length'] < 256) {
$length = $params['length'] > 120 ? 'size="120"' : 'size="' . $params['length'] . '"';
$output .= '<td class="main">' . html_input_field($param_array['field_name'], $cInfo->{$param_array}['field_name'], $length) . '</td></tr>';
} else {
$output .= '<td class="main">' . html_textarea_field($param_array['field_name'], DEFAULT_INPUT_FIELD_LENGTH, 4, $cInfo->{$param_array}['field_name']) . '</td></tr>';
}
break;
case 'hyperlink':
case 'image_link':
case 'inventory_link':
$output .= '<td class="main">' . html_input_field($param_array['field_name'], $cInfo->{$param_array}['field_name'], 'size="' . DEFAULT_INPUT_FIELD_LENGTH . '"') . '</td></tr>';
break;
case 'integer':
case 'decimal':
$output .= '<td class="main">' . html_input_field($param_array['field_name'], $cInfo->{$param_array}['field_name'], 'size="13" maxlength="12" style="text-align:right"') . '</td></tr>';
break;
case 'date':
case 'time':
case 'date_time':
$output .= '<td class="main">' . html_input_field($param_array['field_name'], $cInfo->{$param_array}['field_name'], 'size="21" maxlength="20"') . '</td></tr>';
break;
case 'drop_down':
case 'enum':
$choices = explode(',', $params['default']);
$pull_down_selection = array();
$default_selection = '';
while ($choice = array_shift($choices)) {
$values = explode(':', $choice);
$pull_down_selection[] = array('id' => $values[0], 'text' => $values[1]);
if ($cInfo->{$param_array}['field_name'] == $values[0]) {
$default_selection = $values[0];
}
}
$output .= '<td class="main">' . html_pull_down_menu($param_array['field_name'], $pull_down_selection, $default_selection) . '</td></tr>';
break;
case 'radio':
$output .= '<td class="main">';
$choices = explode(',', $params['default']);
while ($choice = array_shift($choices)) {
$values = explode(':', $choice);
$values[0] = trim($values[0]);
$cInfo->{$param_array}['field_name'] = trim($cInfo->{$param_array}['field_name']);
$cmp = strcmp($values[0], $cInfo->{$param_array}['field_name']);
$output .= html_radio_field($param_array['field_name'], $values[0], $cmp == 0 ? true : false);
$output .= ' ' . $values[1] . ' ';
}
$output .= '</td></tr>';
break;
case 'check_box':
$output .= '<td class="main">' . html_checkbox_field($param_array['field_name'], '1', $cInfo->{$param_array}['field_name'] == 1 ? true : false) . '</td></tr>';
break;
case 'time_stamp':
default:
$output = '';
}
return $output;
}
开发者ID:jigsmaheta,项目名称:puerto-argentino,代码行数:64,代码来源:inventory.php
示例17: build_form_html
function build_form_html($action, $id = '')
{
global $db, $messageStack;
global $integer_lengths, $decimal_lengths, $check_box_choices;
$cInfo = '';
if ($action != 'new') {
$result = $db->Execute("select id, entry_type, field_name, description, id, params \n\t from " . TABLE_EXTRA_FIELDS . " where id = '" . $id . "'");
$params = unserialize($result->fields['params']);
foreach ($params as $key => $value) {
$result->fields[$key] = $value;
}
$form_array = xtra_field_prep_form($result->fields);
$cInfo = new objectInfo($form_array);
}
// build the tab list
$tab_list = gen_build_pull_down(xtra_field_get_tabs('assets'));
array_shift($tab_list);
if ($action == 'new' && sizeof($tab_list) < 1) {
$messageStack->add(EXTRA_FIELDS_ERROR_NO_TABS, 'error');
echo $messageStack->output();
}
$output = '<table style="border-collapse:collapse;margin-left:auto; margin-right:auto;">' . chr(10);
$output .= ' <thead class="ui-widget-header">' . "\n";
$output .= ' <tr>' . chr(10);
$output .= ' <th colspan="2">' . ($action == 'new' ? TEXT_NEW_FIELD : TEXT_EDIT_FIELD) . '</th>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' </thead>' . "\n";
$output .= ' <tbody class="ui-widget-content">' . "\n";
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . INV_FIELD_NAME . '</td>' . chr(10);
$output .= ' <td>' . html_input_field('field_name', $cInfo->field_name, 'size="33" maxlength="32"') . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td colspan="2">' . INV_FIELD_NAME_RULES . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . TEXT_DESCRIPTION . '</td>' . chr(10);
$output .= ' <td>' . html_input_field('description', $cInfo->description, 'size="65" maxlength="64"') . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . INV_CATEGORY_MEMBER . '</td>' . chr(10);
$output .= ' <td>' . html_pull_down_menu('tab_id', $tab_list, $cInfo->tab_id) . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr class="ui-widget-header">' . chr(10);
$output .= ' <th colspan="2">' . TEXT_PROPERTIES . '</th>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>';
$output .= html_radio_field('entry_type', 'text', $cInfo->entry_type == 'text' ? true : false) . ' ' . INV_LABEL_TEXT_FIELD . '<br />';
$output .= html_radio_field('entry_type', 'html', $cInfo->entry_type == 'html' ? true : false) . ' ' . INV_LABEL_HTML_TEXT_FIELD . '</td>' . chr(10);
$output .= ' <td>' . INV_LABEL_MAX_NUM_CHARS;
$output .= '<br />' . html_input_field('text_length', $cInfo->text_length ? $cInfo->text_length : DEFAULT_TEXT_LENGTH, 'size="10" maxlength="9"');
$output .= '<br />' . INV_LABEL_DEFAULT_TEXT_VALUE . '<br />' . INV_LABEL_MAX_255;
$output .= '<br />' . html_textarea_field('text_default', 35, 6, $cInfo->text_default);
$output .= ' </td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>';
$output .= html_radio_field('entry_type', 'hyperlink', $cInfo->entry_type == 'hyperlink' ? true : false) . ' ' . INV_LABEL_HYPERLINK . '<br />';
$output .= html_radio_field('entry_type', 'image_link', $cInfo->entry_type == 'image_link' ? true : false) . ' ' . INV_LABEL_IMAGE_LINK . '<br />';
$output .= html_radio_field('entry_type', 'inventory_link', $cInfo->entry_type == 'inventory_link' ? true : false) . ' ' . INV_LABEL_INVENTORY_LINK;
$output .= ' </td>' . chr(10);
$output .= ' <td>' . INV_LABEL_FIXED_255_CHARS;
$output .= '<br />' . INV_LABEL_DEFAULT_TEXT_VALUE;
$output .= '<br />' . html_textarea_field('link_default', 35, 3, $cInfo->link_default);
$output .= ' </td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . html_radio_field('entry_type', 'integer', $cInfo->entry_type == 'integer' ? true : false) . ' ' . INV_LABEL_INTEGER_FIELD . '</td>' . chr(10);
$output .= ' <td>' . INV_LABEL_INTEGER_RANGE;
$output .= '<br />' . html_pull_down_menu('integer_range', gen_build_pull_down($integer_lengths), $cInfo->integer_range);
$output .= '<br />' . INV_LABEL_DEFAULT_TEXT_VALUE . html_input_field('integer_default', $cInfo->integer_default, 'size="16"');
$output .= ' </td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . html_radio_field('entry_type', 'decimal', $cInfo->entry_type == 'decimal' ? true : false) . ' ' . INV_LABEL_DECIMAL_FIELD . '</td>' . chr(10);
$output .= ' <td>' . INV_LABEL_DECIMAL_RANGE;
$output .= html_pull_down_menu('decimal_range', gen_build_pull_down($decimal_lengths), $cInfo->decimal_range);
$output .= '<br />' . INV_LABEL_DEFAULT_DISPLAY_VALUE . html_input_field('decimal_display', $cInfo->decimal_display ? $cInfo->decimal_display : DEFAULT_REAL_DISPLAY_FORMAT, 'size="6" maxlength="5"');
$output .= '<br />' . INV_LABEL_DEFAULT_TEXT_VALUE . html_input_field('decimal_default', $cInfo->decimal_default, 'size="16"');
$output .= ' </td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>';
$output .= html_radio_field('entry_type', 'drop_down', $cInfo->entry_type == 'drop_down' ? true : false) . ' ' . INV_LABEL_DROP_DOWN_FIELD . '<br />';
$output .= html_radio_field('entry_type', 'radio', $cInfo->entry_type == 'radio' ? true : false) . ' ' . INV_LABEL_RADIO_FIELD;
$output .= ' </td>' . chr(10);
$output .= ' <td>' . INV_LABEL_CHOICES . '<br />' . html_textarea_field('radio_default', 35, 6, $cInfo->radio_default) . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . html_radio_field('entry_type', 'check_box', $cInfo->entry_type == 'check_box' ? true : false) . ' ' . INV_LABEL_CHECK_BOX_FIELD . '</td>' . chr(10);
$output .= ' <td>' . INV_LABEL_DEFAULT_TEXT_VALUE . html_pull_down_menu('check_box_range', gen_build_pull_down($check_box_choices), $cInfo->check_box_range) . '</td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . html_radio_field('entry_type', 'date', $cInfo->entry_type == 'date' ? true : false) . ' ' . TEXT_DATE . '</td>' . chr(10);
$output .= ' <td> </td>' . chr(10);
$output .= ' </tr>' . chr(10);
$output .= ' <tr>' . chr(10);
$output .= ' <td>' . html_radio_field('entry_type', 'time', $cInfo->entry_type == 'time' ? true : false) . ' ' . TEXT_TIME . '</td>' . chr(10);
$
|
请发表评论