本文整理汇总了PHP中start_form函数的典型用法代码示例。如果您正苦于以下问题:PHP start_form函数的具体用法?PHP start_form怎么用?PHP start_form使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了start_form函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: gl_inquiry_controls
function gl_inquiry_controls()
{
$dim = get_company_pref('use_dimension');
start_form();
start_table(TABLESTYLE_NOBORDER);
start_row();
gl_all_accounts_list_cells(_("Account:"), 'account', null, false, false, _("All Accounts"));
date_cells(_("from:"), 'TransFromDate', '', null, -30);
date_cells(_("to:"), 'TransToDate');
end_row();
end_table();
start_table(TABLESTYLE_NOBORDER);
start_row();
if ($dim >= 1) {
dimensions_list_cells(_("Dimension") . " 1:", 'Dimension', null, true, " ", false, 1);
}
if ($dim > 1) {
dimensions_list_cells(_("Dimension") . " 2:", 'Dimension2', null, true, " ", false, 2);
}
small_amount_cells(_("Amount min:"), 'amount_min', null, " ");
small_amount_cells(_("Amount max:"), 'amount_max', null, " ");
submit_cells('Show', _("Show"), '', '', 'default');
end_row();
end_table();
echo '<hr>';
end_form();
}
示例2: gl_payment_controls
function gl_payment_controls()
{
global $table_style2;
$home_currency = get_company_currency();
start_form(false, true);
start_table($table_style2, 5, 7);
echo "<tr><td valign=top>";
// outer table
echo "<table>";
bank_accounts_list_row(tr("From Account:"), 'FromBankAccount', null, true);
bank_accounts_list_row(tr("To Account:"), 'ToBankAccount', null, true);
date_row(tr("Transfer Date:"), 'DatePaid');
$from_currency = get_bank_account_currency($_POST['FromBankAccount']);
$to_currency = get_bank_account_currency($_POST['ToBankAccount']);
if ($from_currency != "" && $to_currency != "" && $from_currency != $to_currency) {
amount_row(tr("Amount:"), 'amount', null, null, $from_currency);
exchange_rate_display($from_currency, $to_currency, $_POST['DatePaid']);
} else {
amount_row(tr("Amount:"), 'amount');
}
echo "</table>";
echo "</td><td valign=top class='tableseparator'>";
// outer table
echo "<table>";
bank_trans_types_list_row(tr("Transfer Type:"), 'TransferType', null);
ref_row(tr("Reference:"), 'ref', references::get_next(systypes::bank_transfer()));
textarea_row(tr("Memo:"), 'memo_', null, 40, 4);
end_table(1);
echo "</td></tr>";
end_table(1);
// outer table
submit_center('AddPayment', tr("Enter Transfer"));
end_form();
}
示例3: edit_allocations_for_transaction
function edit_allocations_for_transaction($type, $trans_no)
{
global $systypes_array;
$cart = $_SESSION['alloc'];
display_heading(sprintf(_("Allocation of %s # %d"), $systypes_array[$cart->type], $cart->trans_no));
display_heading($cart->person_name);
display_heading2(_("Date:") . " <b>" . $cart->date_ . "</b>");
display_heading2(_("Total:") . " <b>" . price_format($cart->bank_amount) . ' ' . $cart->currency . "</b>");
if ($cart->currency != $cart->person_curr) {
$total = _("Total in clearing currency:") . " <b>" . price_format($cart->amount) . "</b>" . sprintf(" %s (%s %s/%s)", $cart->person_curr, exrate_format($cart->bank_amount / $cart->amount), $cart->currency, $cart->person_curr);
display_heading2($total);
}
echo "<br>";
start_form();
div_start('alloc_tbl');
if (count($cart->allocs) > 0) {
show_allocatable(true);
submit_center_first('UpdateDisplay', _("Refresh"), _('Start again allocation of selected amount'), true);
submit('Process', _("Process"), true, _('Process allocations'), 'default');
submit_center_last('Cancel', _("Back to Allocations"), _('Abandon allocations and return to selection of allocatable amounts'), 'cancel');
} else {
display_note(_("There are no unsettled transactions to allocate."), 0, 1);
submit_center('Cancel', _("Back to Allocations"), true, _('Abandon allocations and return to selection of allocatable amounts'), 'cancel');
}
div_end();
end_form();
}
示例4: gl_inquiry_controls
function gl_inquiry_controls()
{
$dim = get_company_pref('use_dimension');
start_form();
start_table(TABLESTYLE_NOBORDER);
$date = today();
if (!isset($_POST['TransFromDate'])) {
$_POST['TransFromDate'] = begin_month($date);
}
if (!isset($_POST['TransToDate'])) {
$_POST['TransToDate'] = end_month($date);
}
date_cells(_("From:"), 'TransFromDate');
date_cells(_("To:"), 'TransToDate');
if ($dim >= 1) {
dimensions_list_cells(_("Dimension") . " 1:", 'Dimension', null, true, " ", false, 1);
}
if ($dim > 1) {
dimensions_list_cells(_("Dimension") . " 2:", 'Dimension2', null, true, " ", false, 2);
}
check_cells(_("No zero values"), 'NoZero', null);
check_cells(_("Only balances"), 'Balance', null);
submit_cells('Show', _("Show"), '', '', 'default');
end_table();
end_form();
}
示例5: gl_inquiry_controls
function gl_inquiry_controls()
{
start_form();
start_table("class='tablestyle_noborder'");
date_cells(tr("From:"), 'TransFromDate', null, -30);
date_cells(tr("To:"), 'TransToDate');
check_cells(tr("No zero values"), 'NoZero', null);
submit_cells('Show', tr("Show"));
end_table();
end_form();
}
示例6: tax_inquiry_controls
function tax_inquiry_controls()
{
start_form();
start_table(TABLESTYLE_NOBORDER);
start_row();
date_cells(_("from:"), 'TransFromDate', '', null, -30);
date_cells(_("to:"), 'TransToDate');
submit_cells('Show', _("Show"), '', '', 'default');
end_row();
end_table();
end_form();
}
示例7: show_navigation
function show_navigation($start_with)
{
start_form("", "get");
if ($start_with > 0) {
echo get_href("<p>Previous", set_var(get_current_url(), "start", max(0, $start_with - SHOW_ITEMS)));
} else {
echo "Previous";
}
echo " ";
echo get_href("Next", set_var(get_current_url(), "start", $start_with + SHOW_ITEMS));
end_form();
}
示例8: display_reval
function display_reval()
{
global $Refs;
start_form();
start_table(TABLESTYLE2);
if (!isset($_POST['date'])) {
$_POST['date'] = Today();
}
date_row(_("Date for Revaluation:"), 'date', '', null, 0, 0, 0, null, true);
ref_row(_("Reference:"), 'ref', '', $Refs->get_next(ST_JOURNAL));
textarea_row(_("Memo:"), 'memo_', null, 40, 4);
end_table(1);
submit_center('submit', _("Revaluate Currencies"), true, false);
end_form();
}
示例9: display_grn_items_for_selection
function display_grn_items_for_selection()
{
global $table_style;
$result = get_grn_items(0, $_SESSION['supp_trans']->supplier_id, true);
if (db_num_rows($result) == 0) {
display_note(tr("There are no outstanding items received from this supplier that have not been invoiced by them."), 0, 1);
end_page();
exit;
}
/*Set up a table to show the outstanding GRN items for selection */
start_form(false, true);
display_heading2(tr("Items Received Yet to be Invoiced"));
start_table("{$table_style} colspan=7 width=95%");
$th = array(tr("Delivery"), tr("Sequence #"), tr("P.O."), tr("Item"), tr("Description"), tr("Received On"), tr("Quantity Received"), tr("Quantity Invoiced"), tr("Uninvoiced Quantity"), tr("Order Price"), tr("Total"));
table_header($th);
$i = $k = 0;
while ($myrow = db_fetch($result)) {
$grn_already_on_invoice = False;
foreach ($_SESSION['supp_trans']->grn_items as $entered_grn) {
if ($entered_grn->id == $myrow["id"]) {
$grn_already_on_invoice = True;
}
}
if ($grn_already_on_invoice == False) {
alt_table_row_color($k);
label_cell(get_trans_view_str(25, $myrow["grn_batch_id"]));
//text_cells(null, 'grn_item_id', $myrow["id"]);
submit_cells('grn_item_id', $myrow["id"]);
label_cell(get_trans_view_str(systypes::po(), $myrow["purch_order_no"]));
label_cell($myrow["item_code"]);
label_cell($myrow["description"]);
label_cell(sql2date($myrow["delivery_date"]));
qty_cell($myrow["qty_recd"]);
qty_cell($myrow["quantity_inv"]);
qty_cell($myrow["qty_recd"] - $myrow["quantity_inv"]);
amount_cell($myrow["unit_price"]);
amount_cell(round($myrow["unit_price"] * ($myrow["qty_recd"] - $myrow["quantity_inv"]), user_price_dec()));
end_row();
$i++;
if ($i > 15) {
$i = 0;
table_header($th);
}
}
}
end_table();
}
示例10: display_controls
function display_controls()
{
global $table_style2;
start_form(false, true);
if (!isset($_POST['supplier_id'])) {
$_POST['supplier_id'] = get_global_supplier(false);
}
if (!isset($_POST['DatePaid'])) {
$_POST['DatePaid'] = Today();
if (!is_date_in_fiscalyear($_POST['DatePaid'])) {
$_POST['DatePaid'] = end_fiscalyear();
}
}
start_table($table_style2, 5, 7);
echo "<tr><td valign=top>";
// outer table
echo "<table>";
bank_accounts_list_row(tr("From Bank Account:"), 'bank_account', null, true);
amount_row(tr("Amount of Payment:"), 'amount');
amount_row(tr("Amount of Discount:"), 'discount');
date_row(tr("Date Paid") . ":", 'DatePaid');
echo "</table>";
echo "</td><td valign=top class='tableseparator'>";
// outer table
echo "<table>";
supplier_list_row(tr("Payment To:"), 'supplier_id', null, false, true);
set_global_supplier($_POST['supplier_id']);
$supplier_currency = get_supplier_currency($_POST['supplier_id']);
$bank_currency = get_bank_account_currency($_POST['bank_account']);
if ($bank_currency != $supplier_currency) {
exchange_rate_display($bank_currency, $supplier_currency, $_POST['DatePaid']);
}
bank_trans_types_list_row(tr("Payment Type:"), 'PaymentType', null);
ref_row(tr("Reference:"), 'ref', references::get_next(22));
text_row(tr("Memo:"), 'memo_', null, 52, 50);
echo "</table>";
echo "</td></tr>";
end_table(1);
// outer table
submit_center('ProcessSuppPayment', tr("Enter Payment"));
if ($bank_currency != $supplier_currency) {
display_note(tr("The amount and discount are in the bank account's currency."), 2, 0);
}
end_form();
}
示例11: voiding_controls
function voiding_controls()
{
global $table_style2;
start_form(false, true);
start_table($table_style2);
systypes_list_row(tr("Transaction Type:"), "filterType", null, true);
text_row(tr("Transaction #:"), 'trans_no', null, 12, 12);
date_row(tr("Voiding Date:"), 'date_');
textarea_row(tr("Memo:"), 'memo_', null, 30, 4);
end_table(1);
if (!isset($_POST['ProcessVoiding'])) {
submit_center('ProcessVoiding', tr("Void Transaction"));
} else {
display_note(tr("Are you sure you want to void this transaction ? This action cannot be undone."), 0, 1);
submit_center_first('ConfirmVoiding', tr("Proceed"));
submit_center_last('CancelVoiding', tr("Cancel"));
}
end_form();
}
示例12: viewing_controls
function viewing_controls()
{
display_note(tr("Only documents can be printed."));
start_form(false, true);
start_table("class='tablestyle_noborder'");
start_row();
systypes_list_cells(tr("Type:"), 'filterType', null, true);
if (!isset($_POST['FromTransNo'])) {
$_POST['FromTransNo'] = "1";
}
if (!isset($_POST['ToTransNo'])) {
$_POST['ToTransNo'] = "999999";
}
ref_cells(tr("from #:"), 'FromTransNo');
ref_cells(tr("to #:"), 'ToTransNo');
submit_cells('ProcessSearch', tr("Search"));
end_row();
end_table(1);
end_form();
}
示例13: gl_inquiry_controls
function gl_inquiry_controls()
{
global $table_style2;
$dim = get_company_pref('use_dimension');
start_form();
//start_table($table_style2);
start_table("class='tablestyle_noborder'");
start_row();
gl_all_accounts_list_cells(tr("Account:"), 'account', null);
date_cells(tr("from:"), 'TransFromDate', null, -30);
date_cells(tr("to:"), 'TransToDate');
submit_cells('Show', tr("Show"));
end_row();
if ($dim >= 1) {
dimensions_list_row(tr("Dimension") . " 1", 'Dimension', null, true, " ", false, 1);
}
if ($dim > 1) {
dimensions_list_row(tr("Dimension") . " 2", 'Dimension2', null, true, " ", false, 2);
}
end_table();
end_form();
}
示例14: edit_allocations_for_transaction
function edit_allocations_for_transaction($type, $trans_no)
{
global $systypes_array;
start_form();
display_heading(_("Allocation of") . " " . $systypes_array[$_SESSION['alloc']->type] . " # " . $_SESSION['alloc']->trans_no);
display_heading($_SESSION['alloc']->person_name);
display_heading2(_("Date:") . " <b>" . $_SESSION['alloc']->date_ . "</b>");
display_heading2(_("Total:") . " <b>" . price_format(-$_SESSION['alloc']->amount) . "</b>");
echo "<br>";
div_start('alloc_tbl');
if (count($_SESSION['alloc']->allocs) > 0) {
show_allocatable(true);
submit_center_first('UpdateDisplay', _("Refresh"), _('Start again allocation of selected amount'), true);
submit('Process', _("Process"), true, _('Process allocations'), 'default');
submit_center_last('Cancel', _("Back to Allocations"), _('Abandon allocations and return to selection of allocatable amounts'), 'cancel');
} else {
display_note(_("There are no unsettled transactions to allocate."), 0, 1);
submit_center('Cancel', _("Back to Allocations"), true, _('Abandon allocations and return to selection of allocatable amounts'), 'cancel');
}
div_end();
end_form();
}
示例15: gl_payment_controls
function gl_payment_controls()
{
global $Refs;
$home_currency = get_company_currency();
start_form();
start_outer_table(TABLESTYLE2);
table_section(1);
bank_accounts_list_row(_("From Account:"), 'FromBankAccount', null, true);
bank_balance_row($_POST['FromBankAccount']);
bank_accounts_list_row(_("To Account:"), 'ToBankAccount', null, true);
if (!isset($_POST['DatePaid'])) {
// init page
$_POST['DatePaid'] = new_doc_date();
if (!is_date_in_fiscalyear($_POST['DatePaid'])) {
$_POST['DatePaid'] = end_fiscalyear();
}
}
date_row(_("Transfer Date:"), 'DatePaid', '', true, 0, 0, 0, null, true);
ref_row(_("Reference:"), 'ref', '', $Refs->get_next(ST_BANKTRANSFER));
table_section(2);
$from_currency = get_bank_account_currency($_POST['FromBankAccount']);
$to_currency = get_bank_account_currency($_POST['ToBankAccount']);
if ($from_currency != "" && $to_currency != "" && $from_currency != $to_currency) {
amount_row(_("Amount:"), 'amount', null, null, $from_currency);
amount_row(_("Bank Charge:"), 'charge', null, null, $from_currency);
amount_row(_("Incoming Amount:"), 'target_amount', null, '', $to_currency, 2);
} else {
amount_row(_("Amount:"), 'amount');
amount_row(_("Bank Charge:"), 'charge');
}
textarea_row(_("Memo:"), 'memo_', null, 40, 4);
end_outer_table(1);
// outer table
submit_center('AddPayment', _("Enter Transfer"), true, '', 'default');
end_form();
}