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


PHP simbio_form_table_AJAX::addRadio方法代码示例

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


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

示例1: isset

             $cf_default = $cfield['default'];
             $cf_data = isset($cfield['data']) && $cfield['data'] ? $cfield['data'] : array();
             // custom field processing
             if (in_array($cfield['type'], array('text', 'longtext', 'numeric'))) {
                 $cf_max = isset($cfield['max']) ? $cfield['max'] : '200';
                 $cf_width = isset($cfield['width']) ? $cfield['width'] : '50';
                 $form->addTextField($cfield['type'] == 'longtext' ? 'textarea' : 'text', $cf_dbfield, $cf_label, isset($rec_cust_d[$cf_dbfield]) ? $rec_cust_d[$cf_dbfield] : $cf_default, 'style="width: ' . $cf_width . '%;" maxlength="' . $cf_max . '"');
             } else {
                 if ($cfield['type'] == 'dropdown') {
                     $form->addSelectList($cf_dbfield, $cf_label, $cf_data, isset($rec_cust_d[$cf_dbfield]) ? $rec_cust_d[$cf_dbfield] : $cf_default);
                 } else {
                     if ($cfield['type'] == 'checklist') {
                         $form->addCheckBox($cf_dbfield, $cf_label, $cf_data, isset($rec_cust_d[$cf_dbfield]) ? $rec_cust_d[$cf_dbfield] : $cf_default);
                     } else {
                         if ($cfield['type'] == 'choice') {
                             $form->addRadio($cf_dbfield, $cf_label, $cf_data, isset($rec_cust_d[$cf_dbfield]) ? $rec_cust_d[$cf_dbfield] : $cf_default);
                         } else {
                             if ($cfield['type'] == 'date') {
                                 $form->addDateField($cf_dbfield, $cf_label, isset($rec_cust_d[$cf_dbfield]) ? $rec_cust_d[$cf_dbfield] : $cf_default);
                             }
                         }
                     }
                 }
             }
         }
     }
 }
 // biblio hide from opac
 $hide_options[] = array('0', __('Show'));
 $hide_options[] = array('1', __('Hide'));
 $form->addRadio('opacHide', __('Hide in OPAC'), $hide_options, $rec_d['opac_hide'] ? '1' : '0');
开发者ID:purwoko,项目名称:slims3-stable15-jquery,代码行数:31,代码来源:index.php

示例2: array

     $form->addAnything(__('Expiry Date') . '*', $str_input);
 }
 // member institution
 $form->addTextField('text', 'instName', __('Institution'), $rec_d['inst_name'], 'style="width: 100%;"');
 // member type
 // get mtype data related to this record from database
 $mtype_query = $dbs->query("SELECT member_type_id, member_type_name FROM mst_member_type");
 $mtype_options = array();
 while ($mtype_data = $mtype_query->fetch_row()) {
     $mtype_options[] = array($mtype_data[0], $mtype_data[1]);
 }
 $form->addSelectList('memberTypeID', __('Membership Type') . '*', $mtype_options, $rec_d['member_type_id']);
 // member gender
 $gender_chbox[0] = array('1', __('Male'));
 $gender_chbox[1] = array('0', __('Female'));
 $form->addRadio('gender', __('Gender'), $gender_chbox, !empty($rec_d['gender']) ? $rec_d['gender'] : '0');
 // member address
 $form->addTextField('textarea', 'memberAddress', __('Address'), $rec_d['member_address'], 'rows="2" style="width: 100%;"');
 // member postal
 $form->addTextField('text', 'memberPostal', __('Postal Code'), $rec_d['postal_code'], 'style="width: 60%;"');
 // member phone
 $form->addTextField('text', 'memberPhone', __('Phone Number'), $rec_d['member_phone'], 'style="width: 60%;"');
 // member fax
 $form->addTextField('text', 'memberFax', __('Fax Number'), $rec_d['member_fax'], 'style="width: 60%;"');
 // member pin
 $form->addTextField('text', 'memberPIN', __('Personal ID Number'), $rec_d['pin'], 'style="width: 100%;"');
 // member notes
 $form->addTextField('textarea', 'memberNotes', __('Notes'), $rec_d['member_notes'], 'rows="2" style="width: 100%;"');
 // member is_pending
 $form->addCheckBox('isPending', __('Pending Membership'), array(array('1', __('Yes'))), $rec_d['is_pending']);
 // member photo
开发者ID:jgoegelein,项目名称:s3st13,代码行数:31,代码来源:index.php

示例3: array

 $form->addTextField('textarea', 'notes', __('Abstract/Notes'), $rec_d['notes'], 'style="width: 100%;" rows="2"');
 // biblio cover image
 if (!trim($rec_d['image'])) {
     $str_input = simbio_form_element::textField('file', 'image');
     $str_input .= ' Maximum ' . $sysconf['max_image_upload'] . ' KB';
     $form->addAnything(__('Image'), $str_input);
 } else {
     $str_input = '<a href="' . UCS_WEB_ROOT_DIR . 'images/docs/' . $rec_d['image'] . '" target="_blank"><strong>' . $rec_d['image'] . '</strong></a><br />';
     $str_input .= simbio_form_element::textField('file', 'image');
     $str_input .= ' Maximum ' . $sysconf['max_image_upload'] . ' KB';
     $form->addAnything(__('Image'), $str_input);
 }
 // biblio hide from opac
 $hide_options[] = array('0', __('Show'));
 $hide_options[] = array('1', __('Hide'));
 $form->addRadio('opacHide', __('Hide in OPAC'), $hide_options, $rec_d['opac_hide'] ? '1' : '0');
 // edit mode messagge
 if ($form->edit_mode) {
     echo '<div class="infoBox" style="overflow: auto;">' . '<div style="float: left; width: 80%;">' . __('You are going to edit biblio data') . ' : <b>' . $rec_d['title'] . '</b>  <br />' . __('Last Updated') . $rec_d['last_update'] . '</div>';
     //mfc
     if ($rec_d['image']) {
         if (file_exists(IMAGES_BASE_DIR . 'docs/' . $rec_d['image'])) {
             $upper_dir = '';
             if ($in_pop_up) {
                 $upper_dir = '../../';
             }
             echo '<div style="float: right;"><img src="' . $upper_dir . '../lib/phpthumb/phpThumb.php?src=../../images/docs/' . urlencode($rec_d['image']) . '&w=53" style="border: 1px solid #999999" /></div>';
         }
     }
     echo '</div>' . "\n";
 }
开发者ID:slims,项目名称:s3st14,代码行数:31,代码来源:index.php

示例4: openWin

     $str_input .= ' Maximum ' . $sysconf['max_image_upload'] . ' KB';
     $form->addAnything(__('Image'), $str_input);
 } else {
     $str_input = '<a href="' . SENAYAN_WEB_ROOT_DIR . 'images/docs/' . $rec_d['image'] . '" target="_blank"><strong>' . $rec_d['image'] . '</strong></a><br />';
     $str_input .= simbio_form_element::textField('file', 'image');
     $str_input .= ' Maximum ' . $sysconf['max_image_upload'] . ' KB';
     $form->addAnything(__('Image'), $str_input);
 }
 // biblio file attachment
 $str_input = '<div class="' . $visibility . '"><a href="javascript: openWin(\'' . MODULES_WEB_ROOT_DIR . 'bibliography/pop_attach.php?biblioID=' . $rec_d['biblio_id'] . '\', \'popAttach\', 600, 200, true)">' . __('Add Attachment') . '</a></div>';
 $str_input .= '<iframe name="attachIframe" id="attachIframe" class="borderAll" style="width: 100%; height: 70px;" src="' . MODULES_WEB_ROOT_DIR . 'bibliography/iframe_attach.php?biblioID=' . $rec_d['biblio_id'] . '"></iframe>';
 $form->addAnything(__('File Attachment'), $str_input);
 // biblio hide from opac
 $hide_options[] = array('0', __('Show'));
 $hide_options[] = array('1', __('Hide'));
 $form->addRadio('opacHide', __('Hide in OPAC'), $hide_options, $rec_d['opac_hide'] ? '1' : '0');
 // biblio promote to front page
 $promote_options[] = array('0', __('Don\'t Promote'));
 $promote_options[] = array('1', __('Promote'));
 $form->addRadio('promote', __('Promote To Homepage'), $promote_options, $rec_d['promoted'] ? '1' : '0');
 // biblio labels
 $arr_labels = !empty($rec_d['labels']) ? unserialize($rec_d['labels']) : array();
 if ($arr_labels) {
     foreach ($arr_labels as $label) {
         $arr_labels[$label[0]] = $label[1];
     }
 }
 $str_input = '';
 // get label data from database
 $label_q = $dbs->query("SELECT * FROM mst_label LIMIT 20");
 while ($label_d = $label_q->fetch_assoc()) {
开发者ID:sulfan,项目名称:SENAYAN-3-Stable,代码行数:31,代码来源:index.php

示例5: Periode

     // form record title
     $form->record_title = $rec_d['member_type_name'];
     // submit button attribute
     $form->submit_button_attr = 'name="saveData" value="' . __('Update') . '" class="button"';
 }
 /* Form Element(s) */
 // member type name
 $form->addTextField('text', 'memberTypeName', __('Member Type Name') . '*', $rec_d['member_type_name'], 'style="width: 100%;"');
 // loan limit
 $form->addTextField('text', 'loanLimit', __('Loan Limit'), $rec_d['loan_limit'], 'size="5"');
 // loan periode
 $form->addTextField('text', 'loanPeriode', __('Loan Periode (In Days)'), $rec_d['loan_periode'], 'size="5"');
 // enable reserve
 $enable_resv_chbox[0] = array('1', __('Enable'));
 $enable_resv_chbox[1] = array('0', __('Disable'));
 $form->addRadio('enableReserve', __('Reserve'), $enable_resv_chbox, !empty($rec_d['enable_reserve']) ? $rec_d['enable_reserve'] : '1');
 // reserve limit
 $form->addTextField('text', 'reserveLimit', __('Reserve Limit'), $rec_d['reserve_limit'], 'size="5"');
 // membership periode
 $form->addTextField('text', 'memberPeriode', __('Membership Periode (In Days)'), $rec_d['member_periode'], 'size="5"');
 // reborrow limit
 $form->addTextField('text', 'reborrowLimit', __('Reborrow Limit'), $rec_d['reborrow_limit'], 'size="5"');
 // fine each day
 $form->addTextField('text', 'fineEachDay', __('Fine Each Day'), $rec_d['fine_each_day']);
 // overdue grace periode
 $form->addTextField('text', 'gracePeriode', __('Overdue Grace Periode'), $rec_d['grace_periode']);
 // edit mode messagge
 if ($form->edit_mode) {
     echo '<div class="infoBox">' . __('You are going to edit member data') . ' : <b>' . $rec_d['member_type_name'] . '</b> <br />' . __('Last Updated') . ' ' . $rec_d['last_update'] . '</div>' . "\n";
     //mfc
 }
开发者ID:slims,项目名称:s3st15_matoa,代码行数:31,代码来源:member_type.php

示例6: date

 // order date
 $form->addDateField('ordDate', __('Order Date'), $rec_d['order_date'] ? $rec_d['order_date'] : date('Y-m-d'));
 // received date
 $form->addDateField('recvDate', __('Receiving Date'), $rec_d['received_date'] ? $rec_d['received_date'] : date('Y-m-d'));
 // item supplier
 // get item status data from database
 $supplier_q = $dbs->query("SELECT supplier_id, supplier_name FROM mst_supplier");
 $supplier_options[] = array('0', __('Not Applicable'));
 while ($supplier_d = $supplier_q->fetch_row()) {
     $supplier_options[] = array($supplier_d[0], $supplier_d[1]);
 }
 $form->addSelectList('supplierID', __('Supplier'), $supplier_options, $rec_d['supplier_id']);
 // item source
 $source_options[] = array('1', __('Buy'));
 $source_options[] = array('2', __('Prize/Grant'));
 $form->addRadio('source', __('Source'), $source_options, !empty($rec_d['source']) ? $rec_d['source'] : '1');
 // item invoice
 $form->addTextField('text', 'invoice', __('Invoice'), $rec_d['invoice'], 'style="width: 100%;"');
 // invoice date
 $form->addDateField('invcDate', __('Invoice Date'), $rec_d['invoice_date'] ? $rec_d['invoice_date'] : date('Y-m-d'));
 // price
 $str_input = simbio_form_element::textField('text', 'price', !empty($rec_d['price']) ? $rec_d['price'] : '0', 'style="width: 40%;"');
 $str_input .= simbio_form_element::selectList('priceCurrency', $sysconf['currencies'], $rec_d['price_currency']);
 $form->addAnything(__('Price'), $str_input);
 // edit mode messagge
 if ($form->edit_mode) {
     echo '<div class="infoBox">' . __('You are going to edit Item data') . ': <b>' . $rec_d['title'] . '</b> ' . '<br />' . __('Last Updated') . ' ' . $rec_d['last_update'];
     echo '</div>' . "\n";
 }
 // print out the form object
 echo $form->printOut();
开发者ID:slims,项目名称:s3st15_matoa,代码行数:31,代码来源:item.php

示例7: array

     $form->addAnything(__('Expiry Date') . '*', $str_input);
 }
 // member institution
 $form->addTextField('text', 'instName', __('Institution'), $rec_d['inst_name'], 'style="width: 100%;"');
 // member type
 // get mtype data related to this record from database
 $mtype_query = $dbs->query("SELECT member_type_id, member_type_name FROM mst_member_type");
 $mtype_options = array();
 while ($mtype_data = $mtype_query->fetch_row()) {
     $mtype_options[] = array($mtype_data[0], $mtype_data[1]);
 }
 $form->addSelectList('memberTypeID', __('Membership Type') . '*', $mtype_options, $rec_d['member_type_id']);
 // member gender
 $gender_chbox[0] = array('1', __('Male'));
 $gender_chbox[1] = array('0', __('Female'));
 $form->addRadio('gender', __('Gender'), $gender_chbox, !empty($rec_d['gender']) ? $rec_d['gender'] : '0');
 // member address
 $form->addTextField('textarea', 'memberAddress', __('Address'), $rec_d['member_address'], 'rows="2" style="width: 100%;"');
 // member postal
 $form->addTextField('text', 'memberPostal', __('Postal Code'), $rec_d['postal_code'], 'style="width: 60%;"');
 // member mail address
 $form->addTextField('textarea', 'memberMailAddress', __('Mail Address'), $rec_d['member_mail_address'], 'rows="2" style="width: 100%;"');
 // member phone
 $form->addTextField('text', 'memberPhone', __('Phone Number'), $rec_d['member_phone'], 'style="width: 60%;"');
 // member fax
 $form->addTextField('text', 'memberFax', __('Fax Number'), $rec_d['member_fax'], 'style="width: 60%;"');
 // member pin
 $form->addTextField('text', 'memberPIN', __('Personal ID Number'), $rec_d['pin'], 'style="width: 100%;"');
 // member notes
 $form->addTextField('textarea', 'memberNotes', __('Notes'), $rec_d['member_notes'], 'rows="2" style="width: 100%;"');
 /**
开发者ID:ridorido,项目名称:s3st15_matoa,代码行数:31,代码来源:index.php

示例8: array

     $form->edit_mode = true;
     // record ID for delete process
     // form record id
     $form->record_id = $itemID;
     // form record title
     $form->record_title = $rec_d['content_title'];
     // submit button attribute
     $form->submit_button_attr = 'name="saveData" value="' . __('Update') . '" class="btn btn-default"';
 }
 /* Form Element(s) */
 // content title
 $form->addTextField('text', 'contentTitle', __('Content Title') . '*', $rec_d['content_title'], 'style="width: 100%;"');
 // content news flag
 $news_chbox[0] = array('0', __('No'));
 $news_chbox[1] = array('1', __('Yes'));
 $form->addRadio('isNews', __('This is News'), $news_chbox, $rec_d['is_news']);
 // content path
 $form->addTextField('text', 'contentPath', __('Path (Must be unique)') . '*', $rec_d['content_path'], 'style="width: 50%;"');
 // content description
 $form->addTextField('textarea', 'contentDesc', __('Content Description'), htmlentities($rec_d['content_desc'], ENT_QUOTES), 'class="texteditor" tyle="width: 100%; height: 500px;"');
 // edit mode messagge
 if ($form->edit_mode) {
     echo '<div class="infoBox">' . __('You are going to update Content data'), ' : <b>' . $rec_d['content_title'] . '</b> <br />' . __('Last Updated') . $rec_d['last_update'] . '</div>';
     //mfc
 }
 // print out the form object
 echo $form->printOut();
 // texteditor instance
 ?>
 <script type="text/javascript">
     $(document).ready(
开发者ID:mucill,项目名称:slims8_akasia,代码行数:31,代码来源:content.php

示例9: openWin

     $str_input .= ' Maximum ' . $sysconf['max_image_upload'] . ' KB';
     $form->addAnything(lang_mod_biblio_field_image, $str_input);
 } else {
     $str_input = '<a href="' . SENAYAN_WEB_ROOT_DIR . 'images/docs/' . $rec_d['image'] . '" target="_blank"><strong>' . $rec_d['image'] . '</strong></a><br />';
     $str_input .= simbio_form_element::textField('file', 'image');
     $str_input .= ' Maximum ' . $sysconf['max_image_upload'] . ' KB';
     $form->addAnything(lang_mod_biblio_field_image, $str_input);
 }
 // biblio file attachment
 $str_input = '<div class="' . $visibility . '"><a href="javascript: openWin(\'' . MODULES_WEB_ROOT_DIR . 'bibliography/pop_attach.php?biblioID=' . $rec_d['biblio_id'] . '\', \'popAttach\', 600, 200, true)">' . lang_mod_biblio_link_attachment_add . '</a></div>';
 $str_input .= '<iframe name="attachIframe" id="attachIframe" class="borderAll" style="width: 100%; height: 70px;" src="' . MODULES_WEB_ROOT_DIR . 'bibliography/iframe_attach.php?biblioID=' . $rec_d['biblio_id'] . '"></iframe>';
 $form->addAnything(lang_mod_biblio_field_attachment, $str_input);
 // biblio hide from opac
 $hide_options[] = array('0', lang_mod_biblio_field_opt_show);
 $hide_options[] = array('1', lang_mod_biblio_field_opt_hide);
 $form->addRadio('opacHide', lang_mod_biblio_field_hide_opac, $hide_options, $rec_d['opac_hide'] ? '1' : '0');
 // biblio promote to front page
 $promote_options[] = array('0', lang_mod_biblio_field_opt_promotefalse);
 $promote_options[] = array('1', lang_mod_biblio_field_opt_promotetrue);
 $form->addRadio('promote', lang_mod_biblio_field_promote, $promote_options, $rec_d['promoted'] ? '1' : '0');
 // biblio labels
 $arr_labels = !empty($rec_d['labels']) ? unserialize($rec_d['labels']) : array();
 if ($arr_labels) {
     foreach ($arr_labels as $label) {
         $arr_labels[$label[0]] = $label[1];
     }
 }
 $str_input = '';
 // get label data from database
 $label_q = $dbs->query("SELECT * FROM mst_label LIMIT 20");
 while ($label_d = $label_q->fetch_assoc()) {
开发者ID:purwoko,项目名称:SENAYAN-3-Stable,代码行数:31,代码来源:index.php

示例10: date

 // order date
 $form->addDateField('ordDate', lang_mod_biblio_item_field_order_date, $rec_d['order_date'] ? $rec_d['order_date'] : date('Y-m-d'));
 // received date
 $form->addDateField('recvDate', lang_mod_biblio_item_field_received_date, $rec_d['received_date'] ? $rec_d['received_date'] : date('Y-m-d'));
 // item supplier
 // get item status data from database
 $supplier_q = $dbs->query("SELECT supplier_id, supplier_name FROM mst_supplier");
 $supplier_options[] = array('0', lang_mod_biblio_item_field_opt_none);
 while ($supplier_d = $supplier_q->fetch_row()) {
     $supplier_options[] = array($supplier_d[0], $supplier_d[1]);
 }
 $form->addSelectList('supplierID', lang_mod_biblio_item_field_supplier, $supplier_options, $rec_d['supplier_id']);
 // item source
 $source_options[] = array('1', lang_mod_biblio_item_field_opt_buy);
 $source_options[] = array('2', lang_mod_biblio_item_field_opt_grant);
 $form->addRadio('source', lang_mod_biblio_item_field_item_source, $source_options, !empty($rec_d['source']) ? $rec_d['source'] : '1');
 // item invoice
 $form->addTextField('text', 'invoice', lang_mod_biblio_item_field_invoice, $rec_d['invoice'], 'style="width: 100%;"');
 // invoice date
 $form->addDateField('invcDate', lang_mod_biblio_item_field_invoice_date, $rec_d['invoice_date'] ? $rec_d['invoice_date'] : date('Y-m-d'));
 // price
 $str_input = simbio_form_element::textField('text', 'price', !empty($rec_d['price']) ? $rec_d['price'] : '0', 'style="width: 40%;"');
 $str_input .= simbio_form_element::selectList('priceCurrency', $sysconf['currencies'], $rec_d['price_currency']);
 $form->addAnything(lang_mod_biblio_item_field_price, $str_input);
 // edit mode messagge
 if ($form->edit_mode) {
     echo '<div class="infoBox">' . lang_mod_biblio_item_common_edit_message . ': <b>' . $rec_d['title'] . '</b> ' . '<br />' . lang_mod_biblio_item_common_last_update . ' ' . $rec_d['last_update'];
     echo '</div>' . "\n";
 }
 // print out the form object
 echo $form->printOut();
开发者ID:purwoko,项目名称:SENAYAN-3-Stable,代码行数:31,代码来源:item.php

示例11: array

     // form record title
     $form->record_title = $rec_d['member_type_name'];
     // submit button attribute
     $form->submit_button_attr = 'name="saveData" value="' . lang_sys_common_form_update . '" class="button"';
 }
 /* Form Element(s) */
 // member type name
 $form->addTextField('text', 'memberTypeName', lang_mod_member_type_field_name . '*', $rec_d['member_type_name'], 'style="width: 100%;"');
 // loan limit
 $form->addTextField('text', 'loanLimit', lang_mod_circ_field_loan_limit, $rec_d['loan_limit'], 'size="5"');
 // loan periode
 $form->addTextField('text', 'loanPeriode', lang_mod_circ_field_loan_periode, $rec_d['loan_periode'], 'size="5"');
 // enable reserve
 $enable_resv_chbox[0] = array('1', lang_sys_conf_form_option_enable);
 $enable_resv_chbox[1] = array('0', lang_sys_conf_form_option_disable);
 $form->addRadio('enableReserve', lang_mod_circ_field_reserve, $enable_resv_chbox, !empty($rec_d['enable_reserve']) ? $rec_d['enable_reserve'] : '1');
 // reserve limit
 $form->addTextField('text', 'reserveLimit', lang_mod_circ_field_reserve_limit, $rec_d['reserve_limit'], 'size="5"');
 // membership periode
 $form->addTextField('text', 'memberPeriode', lang_mod_member_type_field_periode, $rec_d['member_periode'], 'size="5"');
 // reborrow limit
 $form->addTextField('text', 'reborrowLimit', lang_mod_circ_field_reborrow_limit, $rec_d['reborrow_limit'], 'size="5"');
 // fine each day
 $form->addTextField('text', 'fineEachDay', lang_mod_circ_field_fine_each_day, $rec_d['fine_each_day']);
 // overdue grace periode
 $form->addTextField('text', 'gracePeriode', lang_mod_circ_field_grace_periode, $rec_d['grace_periode']);
 // edit mode messagge
 if ($form->edit_mode) {
     echo '<div class="infoBox">' . lang_mod_member_type_common_edit_message . ' : <b>' . $rec_d['member_type_name'] . '</b> <br />' . lang_mod_member_type_common_last_update . ' ' . $rec_d['last_update'] . '</div>' . "\n";
 }
 // print out the form object
开发者ID:purwoko,项目名称:SENAYAN-3-Stable,代码行数:31,代码来源:member_type.php

示例12: array

     $form->addAnything(lang_mod_membership_field_expiry_date . '*', $str_input);
 }
 // member institution
 $form->addTextField('text', 'instName', lang_mod_membership_field_institution, $rec_d['inst_name'], 'style="width: 100%;"');
 // member type
 // get mtype data related to this record from database
 $mtype_query = $dbs->query("SELECT member_type_id, member_type_name FROM mst_member_type");
 $mtype_options = array();
 while ($mtype_data = $mtype_query->fetch_row()) {
     $mtype_options[] = array($mtype_data[0], $mtype_data[1]);
 }
 $form->addSelectList('memberTypeID', lang_mod_membership_field_membership_type, $mtype_options, $rec_d['member_type_id']);
 // member gender
 $gender_chbox[0] = array('1', lang_mod_membership_field_gender_opt1);
 $gender_chbox[1] = array('0', lang_mod_membership_field_gender_opt2);
 $form->addRadio('gender', lang_mod_membership_field_gender, $gender_chbox, !empty($rec_d['gender']) ? $rec_d['gender'] : '0');
 // member email
 $form->addTextField('text', 'memberEmail', lang_mod_membership_field_email, $rec_d['member_email'], 'style="width: 60%;"');
 // member address
 $form->addTextField('textarea', 'memberAddress', lang_mod_membership_field_address, $rec_d['member_address'], 'rows="2" style="width: 100%;"');
 // member postal
 $form->addTextField('text', 'memberPostal', lang_mod_membership_field_postal_code, $rec_d['postal_code'], 'style="width: 60%;"');
 // member phone
 $form->addTextField('text', 'memberPhone', lang_mod_membership_field_phone_number, $rec_d['member_phone'], 'style="width: 60%;"');
 // member fax
 $form->addTextField('text', 'memberFax', lang_mod_membership_field_fax_number, $rec_d['member_fax'], 'style="width: 60%;"');
 // member pin
 $form->addTextField('text', 'memberPIN', lang_mod_membership_field_personal_id, $rec_d['pin'], 'style="width: 100%;"');
 // member notes
 $form->addTextField('textarea', 'memberNotes', lang_mod_membership_field_notes, $rec_d['member_notes'], 'rows="2" style="width: 100%;"');
 // member is_pending
开发者ID:purwoko,项目名称:SENAYAN-3-Stable,代码行数:31,代码来源:index.php

示例13: isset

         $form->addHidden('themeDir', $_GET['theme']);
         $form->addHidden('themeType', $_GET['customize']);
         // custom field processing
         if (in_array($cfield['type'], array('text', 'longtext', 'numeric'))) {
             $cf_max = isset($cfield['max']) ? $cfield['max'] : '200';
             $cf_width = isset($cfield['width']) ? $cfield['width'] : '50';
             $form->addTextField($cfield['type'] == 'longtext' ? 'textarea' : 'text', $cf_dbfield, $cf_label, isset($sysconf['template'][$cf_dbfield]) ? $sysconf['template'][$cf_dbfield] : $cf_default, 'style="width: ' . $cf_width . '%;" maxlength="' . $cf_max . '"');
         } else {
             if ($cfield['type'] == 'dropdown') {
                 $form->addSelectList($cf_dbfield, $cf_label, $cf_data, isset($sysconf['template'][$cf_dbfield]) ? $sysconf['template'][$cf_dbfield] : $cf_default);
             } else {
                 if ($cfield['type'] == 'checklist') {
                     $form->addCheckBox($cf_dbfield, $cf_label, $cf_data, isset($sysconf['template'][$cf_dbfield]) ? $sysconf['template'][$cf_dbfield] : $cf_default);
                 } else {
                     if ($cfield['type'] == 'choice') {
                         $form->addRadio($cf_dbfield, $cf_label, $cf_data, isset($sysconf['template'][$cf_dbfield]) ? $sysconf['template'][$cf_dbfield] : $cf_default);
                     } else {
                         if ($cfield['type'] == 'date') {
                             $form->addDateField($cf_dbfield, $cf_label, isset($sysconf['template'][$cf_dbfield]) ? $sysconf['template'][$cf_dbfield] : $cf_default);
                         }
                     }
                 }
             }
         }
     }
     // print out the form object
     echo $form->printOut();
 } else {
     echo __('This theme not customizable');
 }
 exit;
开发者ID:slims,项目名称:slims8_akasia,代码行数:31,代码来源:theme.php


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