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


PHP simbio_table::appendTableRow方法代码示例

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


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

示例1:

// initial row count
$row = 1;
$row_class = 'alterCell2';
// database list
$module_query = $dbs->query("SELECT * FROM mst_module AS m");
while ($module_data = $module_query->fetch_assoc()) {
    // alternate the row color
    if ($row_class == 'alterCell2') {
        $row_class = 'alterCell';
    } else {
        $row_class = 'alterCell2';
    }
    $read_checked = '';
    $write_checked = '';
    if (isset($priv_data[$module_data['module_id']]['r']) and $priv_data[$module_data['module_id']]['r'] == 1) {
        $read_checked = 'checked';
    }
    if (isset($priv_data[$module_data['module_id']]['w']) and $priv_data[$module_data['module_id']]['w'] == 1) {
        $read_checked = 'checked';
        $write_checked = 'checked';
    }
    $chbox_read = '<input type="checkbox" name="read[]" value="' . $module_data['module_id'] . '" ' . $read_checked . ' />';
    $chbox_write = '<input type="checkbox" name="write[]" value="' . $module_data['module_id'] . '" ' . $write_checked . ' />';
    $table->appendTableRow(array($module_data['module_name'], $chbox_read, $chbox_write));
    $table->setCellAttr($row, 0, 'valign="top" class="' . $row_class . '"');
    $table->setCellAttr($row, 1, 'valign="top" class="' . $row_class . '" style="font-weight: bold; width: 5%;"');
    $table->setCellAttr($row, 2, 'valign="top" class="' . $row_class . '" style="font-weight: bold; width: 5%;"');
    $row++;
}
echo $table->printTable();
$priv_table = ob_get_clean();
开发者ID:purwoko,项目名称:SENAYAN-3-Stable,代码行数:31,代码来源:module_priv_form.inc.php

示例2: foreach

        foreach ($_SESSION['temp_loan'] as $_loan_ID => $temp_loan_list_d) {
            // alternate the row color
            $row_class = $row % 2 == 0 ? 'alterCell' : 'alterCell2';
            // remove link
            $remove_link = '<a href="circulation_action.php?removeID=' . $temp_loan_list_d['item_code'] . '" title="Remove this item" class="trashLink">&nbsp;</a>';
            // check if manually changes loan and due date allowed
            if ($sysconf['allow_loan_date_change']) {
                $loan_date = '<a href="#" title="' . __('Click To Change Loan Date') . '" onclick="changeDateForm(\'' . $_loan_ID . '\', \'loan\', \'loanDate' . $row . '\')" id="loanDate' . $row . '">' . $temp_loan_list_d['loan_date'] . '</a>';
                $due_date = '<a href="#" title="' . __('Click To Change Due Date') . '" onclick="changeDateForm(\'' . $_loan_ID . '\', \'due\', \'dueDate' . $row . '\')" id="dueDate' . $row . '">' . $temp_loan_list_d['due_date'] . '</a>';
            } else {
                $loan_date = $temp_loan_list_d['loan_date'];
                $due_date = $temp_loan_list_d['due_date'];
            }
            // row colums array
            $fields = array($remove_link, $temp_loan_list_d['item_code'], $temp_loan_list_d['title'], $loan_date, $due_date);
            // append data to table row
            $temp_loan_list->appendTableRow($fields);
            // set the HTML attributes
            $temp_loan_list->setCellAttr($row, null, "valign='top' class='{$row_class}'");
            $temp_loan_list->setCellAttr($row, 0, "valign='top' align='center' class='{$row_class}' style='width: 5%;'");
            $temp_loan_list->setCellAttr($row, 1, "valign='top' class='{$row_class}' style='width: 10%;'");
            $temp_loan_list->setCellAttr($row, 2, "valign='top' class='{$row_class}' style='width: 60%;'");
            $row++;
        }
        echo $temp_loan_list->printTable();
    }
}
// get the buffered content
$content = ob_get_clean();
// include the page template
require SENAYAN_BASE_DIR . '/admin/' . $sysconf['admin_template']['dir'] . '/notemplate_page_tpl.php';
开发者ID:edikriting,项目名称:SENAYAN-3-Stable,代码行数:31,代码来源:loan.php

示例3: array

         WHERE item_code=\'' . $loan_d['item_code'] . '\' ORDER BY reserve_date DESC');
     $reserve_d = $reserve_q->fetch_row();
     $member = $reserve_d[1] . ' (' . $reserve_d[0] . ')';
     $reserve_msg = str_replace(array('{itemCode}', '{member}'), array($loan_d['item_code'], $member), __('Item {itemCode} is being reserved by member {member}'));
     //mfc
     $loan_d['title'] .= '<div>' . $reserve_msg . '</div>';
 }
 // write log
 utility::writeLogs($dbs, 'member', $loan_d['member_id'], 'circulation', $_SESSION['realname'] . ' return item (' . $_POST['quickReturnID'] . ') with title (' . $loan_d['title'] . ') with Quick Return method');
 // show loan information
 include SIMBIO_BASE_DIR . 'simbio_GUI/table/simbio_table.inc.php';
 // create table object
 $table = new simbio_table();
 $table->table_attr = 'class="border" style="width: 100%; margin-bottom: 5px;" cellpadding="5" cellspacing="0"';
 // append data to table row
 $table->appendTableRow(array('Item ' . $_POST['quickReturnID'] . __(' successfully returned on') . $return_date));
 //mfc
 $table->appendTableRow(array(__('Title'), $loan_d['title']));
 $table->appendTableRow(array(__('Member Name'), $loan_d['member_name'], __('Member ID'), $loan_d['member_id']));
 $table->appendTableRow(array(__('Loan Date'), $loan_d['loan_date'], __('Due Date'), $loan_d['due_date']));
 // set the cell attributes
 $table->setCellAttr(1, null, 'class="dataListHeader" style="color: #FFFFFF; font-weight: bold;" colspan="4"');
 $table->setCellAttr(2, 0, 'class="alterCell"');
 $table->setCellAttr(2, 1, 'class="alterCell2" colspan="3"');
 $table->setCellAttr(3, 0, 'class="alterCell" width="15%"');
 $table->setCellAttr(3, 1, 'class="alterCell2" width="35%"');
 $table->setCellAttr(3, 2, 'class="alterCell" width="15%"');
 $table->setCellAttr(3, 3, 'class="alterCell2" width="35%"');
 $table->setCellAttr(4, 0, 'class="alterCell" width="15%"');
 $table->setCellAttr(4, 1, 'class="alterCell2" width="35%"');
 $table->setCellAttr(4, 2, 'class="alterCell" width="15%"');
开发者ID:edikriting,项目名称:SENAYAN-3-Stable,代码行数:31,代码来源:circulation_action.php

示例4: foreach

        $table->setCellAttr($row, 0, 'valign="top" class="' . $row_class . '" style="font-weight: bold; width: 5%;"');
        $table->setCellAttr($row, 1, 'valign="top" class="' . $row_class . '" style="font-weight: bold; width: 5%;"');
        $table->setCellAttr($row, 2, 'valign="top" class="' . $row_class . '" style="width: 40%;"');
        $table->setCellAttr($row, 3, 'valign="top" class="' . $row_class . '" style="width: 50%;"');
        $row++;
    }
    echo $table->printTable();
    // hidden form
    echo '<form name="hiddenActionForm" method="post" action="' . $_SERVER['PHP_SELF'] . '"><input type="hidden" name="bid" value="0" /><input type="hidden" name="remove" value="0" /><input type="hidden" name="alsoDeleteFile" value="0" /></form>';
} else {
    if ($_SESSION['biblioAttach']) {
        $table = new simbio_table();
        $table->table_attr = 'align="center" style="width: 100%;" cellpadding="2" cellspacing="0"';
        $row = 1;
        $row_class = 'alterCell2';
        foreach ($_SESSION['biblioAttach'] as $idx => $biblio_session) {
            // remove link
            $remove_link = '<a href="iframe_attach.php?removesess=' . $idx . '" style="color: #000000; text-decoration: underline;">Remove</a>';
            $table->appendTableRow(array($remove_link, $biblio_session['file_name'], $biblio_session['last_update']));
            $table->setCellAttr($row, 0, 'valign="top" class="' . $row_class . '" style="font-weight: bold; background-color: #ffc466; width: 10%;"');
            $table->setCellAttr($row, 1, 'valign="top" class="' . $row_class . '" style="background-color: #ffc466; width: 60%;"');
            $table->setCellAttr($row, 2, 'valign="top" class="' . $row_class . '" style="background-color: #ffc466; width: 30%;"');
            $row++;
        }
        echo $table->printTable();
    }
}
/* main content end */
$content = ob_get_clean();
// include the page template
require SENAYAN_BASE_DIR . '/admin/' . $sysconf['admin_template']['dir'] . '/notemplate_page_tpl.php';
开发者ID:slims,项目名称:s3st15_matoa,代码行数:31,代码来源:iframe_attach.php

示例5: foreach

    if ($_SESSION['biblioAuthor']) {
        $table = new simbio_table();
        $table->table_attr = 'align="center" style="width: 100%;" cellpadding="2" cellspacing="0"';
        $row = 1;
        $row_class = 'alterCell2';
        foreach ($_SESSION['biblioAuthor'] as $biblio_session) {
            // remove link
            $remove_link = '<a href="iframe_author.php?removesess=' . $biblio_session[0] . '"
          style="color: #000000; text-decoration: underline;">Remove</a>';
            if ($biblio_session) {
                $author_q = $dbs->query("SELECT author_name, author_year, authority_type FROM mst_author\n              WHERE author_id=" . $biblio_session[0]);
                $author_d = $author_q->fetch_row();
                $author = $author_d[0];
                $author_year = $author_d[1];
                $authority_type = $author_d[2];
            }
            $table->appendTableRow(array($remove_link, $author, $author_year, $authority_type, $sysconf['authority_level'][$biblio_session[1]]));
            $table->setCellAttr($row, 0, 'valign="top" class="' . $row_class . '" style="font-weight: bold; background-color: #ffc466; width: 10%;"');
            $table->setCellAttr($row, 1, 'valign="top" class="' . $row_class . '" style="background-color: #ffc466; width: 30%;"');
            $table->setCellAttr($row, 2, 'valign="top" class="' . $row_class . '" style="background-color: #ffc466; width: 20%;"');
            $table->setCellAttr($row, 3, 'valign="top" class="' . $row_class . '" style="background-color: #ffc466; width: 20%;"');
            $table->setCellAttr($row, 4, 'valign="top" class="' . $row_class . '" style="background-color: #ffc466; width: 20%;"');
            $row++;
        }
        echo $table->printTable();
    }
}
/* main content end */
$content = ob_get_clean();
// include the page template
require SENAYAN_BASE_DIR . '/admin/' . $sysconf['admin_template']['dir'] . '/notemplate_page_tpl.php';
开发者ID:indonesia,项目名称:slims5_meranti,代码行数:31,代码来源:iframe_author.php

示例6: while

    $row = 1;
    while ($voc_d = $voc_q->fetch_assoc()) {
        if (!is_null($voc_d['scope'])) {
            echo '<b>Scope note: </b>' . $voc_d['scope'] . '<hr>';
        }
        if (is_null($voc_d['scope'])) {
            // fallback related topic id
            $topic_q = $dbs->query('SELECT topic FROM mst_topic WHERE topic_id=' . $voc_d['related_topic_id']);
            $topic_d = $topic_q->fetch_row();
            // alternate the row color
            $row_class = $row % 2 == 0 ? 'alterCell' : 'alterCell2';
            // links
            $edit_link = '<a class="notAJAX btn btn-primary button openPopUp" href="' . MWB . 'master_file/pop_vocabolary_control.php?editTopic=true&itemID=' . $itemID . '&vocID=' . $voc_d['vocabolary_id'] . '" height="450" title="' . __('Vocabolary Control') . '" style="text-decoration: underline;"><i class="glyphicon glyphicon-pencil"></i></a>';
            $remove_link = '<a href="#" class="notAJAX btn button btn-danger btn-delete" onclick="javascript: confirmProcess(' . $itemID . ', ' . $voc_d['vocabolary_id'] . ')"><i class="glyphicon glyphicon-trash"></i></a>';
            $related_term = $voc_d['rt_id'];
            $table->appendTableRow(array($remove_link, $edit_link, $related_term, $topic_d[0]));
            $table->setCellAttr($row, null, 'valign="top" class="' . $row_class . '" style="font-weight: bold; width: auto;"');
            $table->setCellAttr($row, 0, 'valign="top" class="' . $row_class . '" style="font-weight: bold; width: 5%;"');
            $table->setCellAttr($row, 1, 'valign="top" class="' . $row_class . '" style="font-weight: bold; width: 5%;"');
            $table->setCellAttr($row, 2, 'valign="top" class="' . $row_class . '" style="font-weight: bold; width: 8%;"');
            $row++;
        }
    }
    echo $table->printTable();
    // hidden form
    echo '<form name="hiddenActionForm" method="post" action="' . $_SERVER['PHP_SELF'] . '"><input type="hidden" name="tid" value="0" /><input type="hidden" name="remove" value="0" /></form>';
}
/* main content end */
$content = ob_get_clean();
// include the page template
require SB . '/admin/' . $sysconf['admin_template']['dir'] . '/notemplate_page_tpl.php';
开发者ID:slims,项目名称:slims8_akasia,代码行数:31,代码来源:iframe_vocabolary_control.php

示例7: printOut

 public function printOut()
 {
     // create table object
     $_table = new simbio_table();
     // set the table attr
     $_table->table_attr = $this->table_attr;
     if ($this->edit_mode) {
         $this->disable = true;
     }
     // initialize result buffer
     $_buffer = '';
     // check if form tag is included
     if ($this->with_form_tag) {
         $this->submit_target = 'submitExec';
         $_buffer .= $this->startForm() . "\n";
     }
     // loop the form element
     $_row_num = 0;
     foreach ($this->elements as $row) {
         $_form_element = $row['element']->out();
         if ($_form_element_info = trim($row['info'])) {
             $_form_element .= '<div class="formElementInfo">' . $_form_element_info . '</div>';
         }
         // append row
         $_table->appendTableRow(array($row['label'], ':', $_form_element));
         // set the column header attr
         $_table->setCellAttr($_row_num + 1, 0, 'width="20%" valign="top"' . $this->table_header_attr);
         $_table->setCellAttr($_row_num + 1, 1, 'width="1%" valign="top"' . $this->table_header_attr);
         // set the form element column attr
         $_table->setCellAttr($_row_num + 1, 2, 'width="79%" ' . $this->table_content_attr);
         $_row_num++;
     }
     // link and buttons
     $_edit_link = '';
     $_delete_button = '';
     $_back_button = '';
     $_del_value = __('Delete Record');
     $_cancel_value = __('Cancel');
     // check if we are on edit form mode
     if ($this->edit_mode) {
         $_edit_link .= '<a href="#" class="notAJAX editFormLink">EDIT</a>';
         // delete button exists if the record_id properties exists
         if ($this->record_id && $this->delete_button) {
             // create delete button
             $_delete_button = '<input type="button" value="' . $_del_value . '" class="button confirmSubmit" onclick="confSubmit(\'deleteForm\', \'Are you sure to delete ' . addslashes($this->record_title) . '?\\nOnce Deleted it cant be restored again\')" style="color: red; font-weight: bold;" />';
         }
         // back button
         if ($this->back_button) {
             $_back_button = '<input type="button" class="cancelButton button" value="' . $_cancel_value . '" />';
         }
     }
     $_buttons = '';
     // check if form tag is included
     if ($this->with_form_tag) {
         $_buttons = '<table cellspacing="0" cellpadding="3" style="width: 100%; background-color: #dcdcdc;">' . '<tr><td><input type="submit" ' . $this->submit_button_attr . ' /> ' . $_back_button . ' ' . $_delete_button . '</td><td align="right">' . $_edit_link . '</td>' . '</tr></table>' . "\n";
     }
     // get the table result
     $_buffer .= $_buttons;
     $_buffer .= $_table->printTable();
     $_buffer .= $_buttons;
     // extract all hidden elements here
     foreach ($this->hidden_elements as $_hidden) {
         $_buffer .= $_hidden->out();
     }
     // update ID hidden elements
     if ($this->edit_mode and $this->record_id) {
         // add hidden form element flag for detail editing purpose
         $_buffer .= '<input type="hidden" name="updateRecordID" value="' . $this->record_id . '" />';
     }
     // check if form tag is included
     if ($this->with_form_tag) {
         $_buffer .= $this->endForm() . "\n";
     }
     if ($this->edit_mode) {
         // hidden form for deleting records
         $_buffer .= '<form action="' . preg_replace('/\\?.+/i', '', $this->form_action) . '" id="deleteForm" target="submitExec" method="post" style="display: inline;">' . '<input type="hidden" name="itemID" value="' . $this->record_id . '" /><input type="hidden" name="itemAction" value="true" /></form>';
     }
     // for debugging purpose only
     // $_buffer .= '<iframe name="submitExec" style="visibility: visible; width: 100%; height: 500px;"></iframe>';
     // hidden iframe for form executing
     $_buffer .= '<iframe name="submitExec" class="noBlock" style="visibility: hidden; width: 100%; height: 0;"></iframe>';
     return $_buffer;
 }
开发者ID:indonesia,项目名称:slims5_meranti,代码行数:83,代码来源:simbio_form_table_AJAX.inc.php

示例8: COUNT

    LEFT JOIN item AS i ON l.item_code=i.item_code
    LEFT JOIN biblio AS b ON i.biblio_id=b.biblio_id
    GROUP BY l.item_code ORDER BY COUNT(l.loan_id) DESC LIMIT 10');
$stat_data = '<ul>';
while ($data = $stat_query->fetch_row()) {
    $stat_data .= '<li>' . $data[0] . '</li>';
}
$stat_data .= '</ul>';
$collection_stat[__('10 Most Popular Titles')] = $stat_data;
// table header
$table->setHeader(array(__('Collection Statistic Summary')));
$table->table_header_attr = 'class="dataListHeader" colspan="3"';
// initial row count
$row = 1;
foreach ($collection_stat as $headings => $stat_data) {
    $table->appendTableRow(array($headings, ':', $stat_data));
    // set cell attribute
    $table->setCellAttr($row, 0, 'class="alterCell" valign="top" style="width: 170px;"');
    $table->setCellAttr($row, 1, 'class="alterCell" valign="top" style="width: 1%;"');
    $table->setCellAttr($row, 2, 'class="alterCell2" valign="top" style="width: auto;"');
    // add row count
    $row++;
}
// if we are in print mode
if (isset($_GET['print'])) {
    // html strings
    $html_str = '<html><head><title>' . $sysconf['library_name'] . ' Membership General Statistic Report</title>';
    $html_str .= '<style type="text/css">' . "\n";
    $html_str .= 'body {padding: 0.2cm}' . "\n";
    $html_str .= 'body * {color: black; font-size: 11pt;}' . "\n";
    $html_str .= 'table {border: 1px solid #000000;}' . "\n";
开发者ID:jgoegelein,项目名称:s3st13,代码行数:31,代码来源:index.php

示例9: strtoupper

<div class="menuBoxInner barcodeIcon">
    <?php 
echo strtoupper(lang_sys_barcodes) . ' <hr />' . lang_sys_barcodes_description . ' "' . lang_sys_conf_barcode_button_print . '".';
?>
</div>
</fieldset>
<?php 
// create table object
$table = new simbio_table();
$table->table_attr = 'align="center" class="border fullWidth" cellpadding="5" cellspacing="0"';
// initial row count
$row = 1;
$row_num = 6;
// submit button
$table->appendTableRow(array(lang_sys_conf_barcode_field_size . ' : <select name="size"><option value="1">' . lang_sys_conf_barcode_field_option_1 . '</option>
    <option value="2" selected>' . lang_sys_conf_barcode_field_option_2 . '</option>
    <option value="3">' . lang_sys_conf_barcode_field_option_3 . '</option></select>'));
// set cell attribute
$table->setCellAttr($row, 0, 'colspan="3" class="alterCell"');
$row++;
// barcode text fields
while ($row <= $row_num) {
    $table->appendTableRow(array('<input type="text" name="barcode[]" style="width: 100%;" />', '<input type="text" name="barcode[]" style="width: 100%;" />', '<input type="text" name="barcode[]" style="width: 100%;" />'));
    $row++;
}
// submit button
$table->appendTableRow(array('<input type="submit" name="saveData" value="' . lang_sys_conf_barcode_button_print . '" />'));
// set cell attribute
$table->setCellAttr($row_num + 1, 0, 'colspan="3" class="alterCell"');
echo '<form name="barcodeForm" id="barcodeForm" target="submitExec" method="post" action="' . $_SERVER['PHP_SELF'] . '">';
echo $table->printTable();
开发者ID:purwoko,项目名称:SENAYAN-3-Stable,代码行数:31,代码来源:barcode_generator.php

示例10: foreach

    echo '<form name="hiddenActionForm" method="post" action="' . $_SERVER['PHP_SELF'] . '"><input type="hidden" name="bid" value="0" /><input type="hidden" name="remove" value="0" /></form>';
} else {
    if ($_SESSION['biblioToBiblio']) {
        $table = new simbio_table();
        $table->table_attr = 'align="center" style="width: 100%;" cellpadding="2" cellspacing="0"';
        $row = 1;
        $row_class = 'alterCell2';
        foreach ($_SESSION['biblioToBiblio'] as $biblio_session) {
            // remove link
            $remove_link = '<a class="notAJAX btn button btn-danger btn-delete" href="iframe_biblio_rel.php?removesess=' . $biblio_session[0] . '">' . __('Remove') . '</a>';
            if ($biblio_session) {
                $title_q = $dbs->query("SELECT title, publish_year, edition FROM biblio\n              WHERE biblio_id=" . $biblio_session[0]);
                $title_d = $title_q->fetch_row();
                $title = $title_d[0];
                $publish_year = $title_d[1];
                $edition = $title_d[2];
            }
            $table->appendTableRow(array($remove_link, $title, $publish_year, $edition));
            $table->setCellAttr($row, 0, 'valign="top" class="' . $row_class . '" style="font-weight: bold; background-color: #ffc466; width: 10%;"');
            $table->setCellAttr($row, 1, 'valign="top" class="' . $row_class . '" style="background-color: #ffc466; width: 50%;"');
            $table->setCellAttr($row, 2, 'valign="top" class="' . $row_class . '" style="background-color: #ffc466; width: 20%;"');
            $table->setCellAttr($row, 3, 'valign="top" class="' . $row_class . '" style="background-color: #ffc466; width: 20%;"');
            $row++;
        }
        echo $table->printTable();
    }
}
/* main content end */
$content = ob_get_clean();
// include the page template
require SB . '/admin/' . $sysconf['admin_template']['dir'] . '/notemplate_page_tpl.php';
开发者ID:slims,项目名称:slims8_akasia,代码行数:31,代码来源:iframe_biblio_rel.php

示例11: printOut

 /**
  * Method to print out form table
  *
  * @return  string
  */
 public function printOut()
 {
     // create table object
     $_table = new simbio_table();
     // set the table attr
     $_table->table_attr = $this->table_attr;
     $_buffer = '';
     // check if form tag is included
     if ($this->with_form_tag) {
         $_buffer .= $this->startForm() . "\n";
     }
     // loop the form element
     $_row_num = 0;
     foreach ($this->elements as $row) {
         $_form_element = $row['element']->out();
         if ($_form_element_info = trim($row['info'])) {
             $_form_element .= '<div class="formElementInfo">' . $_form_element_info . '</div>';
         }
         // append row
         $_table->appendTableRow(array($row['label'], ':', $_form_element));
         // set the column header attr
         $_table->setCellAttr($_row_num + 1, 0, 'width="20%" valign="top"' . $this->table_header_attr);
         $_table->setCellAttr($_row_num + 1, 1, 'width="1%" valign="top"' . $this->table_header_attr);
         // set the form element column attr
         $_table->setCellAttr($_row_num + 1, 2, 'width="79%" ' . $this->table_content_attr);
         $_row_num++;
     }
     // link and buttons
     $_edit_link = '';
     $_delete_button = '';
     $_back_button = '';
     if (defined('lang_sys_common_form_delete')) {
         $_del_value = lang_sys_common_form_delete;
     } else {
         $_del_value = 'Delete Record';
     }
     if (defined('lang_sys_common_form_cancel')) {
         $_cancel_value = lang_sys_common_form_cancel;
     } else {
         $_cancel_value = 'Cancel';
     }
     // check if we are on edit form mode
     if ($this->edit_mode) {
         $_edit_link .= '<a href="#" onclick="enableForm(\'' . $this->form_name . '\'); enableForm(\'deleteForm\');" style="font-weight: bold;" class="editFormLink">EDIT</a>';
         // delete button exists if the record_id exists
         if ($this->record_id && $this->delete_button) {
             $_delete_button = '<input type="button" value="' . $_del_value . '" class="button" onclick="confSubmit(\'deleteForm\', \'Are you sure to delete ' . addslashes($this->record_title) . '?\\nOnce Deleted it cant be restored again\')" style="color: red; font-weight: bold;" />';
         }
         // back button
         if ($this->back_button) {
             $_back_button = '<input type="button" class="cancelButton button" value="' . $_cancel_value . '" onclick="javascript: self.history.back();" />';
         }
     }
     $_buttons = '';
     if ($this->with_form_tag) {
         $_buttons = '<table cellspacing="0" cellpadding="3" style="width: 100%; background-color: #dcdcdc;">' . '<tr><td><input type="submit" ' . $this->submit_button_attr . ' /> ' . $_delete_button . ' ' . $_back_button . '</td><td align="right">' . $_edit_link . '</td>' . '</tr></table>' . "\n";
     }
     // get the table result
     $_buffer .= $_buttons;
     $_buffer .= $_table->printTable();
     $_buffer .= $_buttons;
     // extract all hidden elements here
     foreach ($this->hidden_elements as $_hidden) {
         $_buffer .= $_hidden->out();
     }
     // update ID hidden elements
     if ($this->edit_mode and $this->record_id) {
         // add hidden form element flag for detail editing purpose
         $_buffer .= '<input type="hidden" name="updateRecordID" value="' . $this->record_id . '" />';
     }
     // check if form tag is included
     if ($this->with_form_tag) {
         $_buffer .= $this->endForm() . "\n";
     }
     if ($this->edit_mode) {
         // hidden form for deleting records
         $_buffer .= '<form action="' . $this->form_action . '" id="deleteForm" method="post" style="display: inline;"><input type="hidden" name="itemID" value="' . $this->record_id . '" /><input type="hidden" name="itemAction" value="true" /></form>';
         // disabling form
         $_buffer .= '<script type="text/javascript">disableForm(\'' . $this->form_name . '\');disableForm(\'deleteForm\');</script>';
     }
     // output
     return $_buffer;
 }
开发者ID:purwoko,项目名称:SENAYAN-3-Stable,代码行数:88,代码来源:simbio_form_table.inc.php

示例12: array

         LEFT JOIN member AS m ON r.member_id=m.member_id
         WHERE item_code=\'' . $loan_d['item_code'] . '\' ORDER BY reserve_date DESC');
     $reserve_d = $reserve_q->fetch_row();
     $member = $reserve_d[1] . ' (' . $reserve_d[0] . ')';
     $reserve_msg = str_replace(array('{itemCode}', '{member}'), array($loan_d['item_code'], $member), lang_mod_circ_reserve_alert_after_return);
     $loan_d['title'] .= '<div>' . $reserve_msg . '</div>';
 }
 // write log
 utility::writeLogs($dbs, 'member', $loan_d['member_id'], 'circulation', $_SESSION['realname'] . ' return item (' . $_POST['quickReturnID'] . ') with title (' . $loan_d['title'] . ') with Quick Return method');
 // show loan information
 include SIMBIO_BASE_DIR . 'simbio_GUI/table/simbio_table.inc.php';
 // create table object
 $table = new simbio_table();
 $table->table_attr = 'class="border" style="width: 100%; margin-bottom: 5px;" cellpadding="5" cellspacing="0"';
 // append data to table row
 $table->appendTableRow(array('Item ' . $_POST['quickReturnID'] . lang_mod_circ_common_item_return_ok . $return_date));
 $table->appendTableRow(array(lang_mod_circ_tblheader_title, $loan_d['title']));
 $table->appendTableRow(array(lang_mod_circ_field_member_name, $loan_d['member_name'], lang_mod_circ_field_member_id, $loan_d['member_id']));
 $table->appendTableRow(array(lang_mod_circ_tblheader_loan_date, $loan_d['loan_date'], lang_mod_circ_tblheader_due_date, $loan_d['due_date']));
 // set the cell attributes
 $table->setCellAttr(1, null, 'class="dataListHeader" style="color: #FFFFFF; font-weight: bold;" colspan="4"');
 $table->setCellAttr(2, 0, 'class="alterCell"');
 $table->setCellAttr(2, 1, 'class="alterCell2" colspan="3"');
 $table->setCellAttr(3, 0, 'class="alterCell" width="15%"');
 $table->setCellAttr(3, 1, 'class="alterCell2" width="35%"');
 $table->setCellAttr(3, 2, 'class="alterCell" width="15%"');
 $table->setCellAttr(3, 3, 'class="alterCell2" width="35%"');
 $table->setCellAttr(4, 0, 'class="alterCell" width="15%"');
 $table->setCellAttr(4, 1, 'class="alterCell2" width="35%"');
 $table->setCellAttr(4, 2, 'class="alterCell" width="15%"');
 $table->setCellAttr(4, 3, 'class="alterCell2" width="35%"');
开发者ID:purwoko,项目名称:SENAYAN-3-Stable,代码行数:31,代码来源:circulation_action.php

示例13: function

        $row_class = 'alterCell';
    } else {
        $row_class = 'alterCell2';
    }
    $read_checked = '';
    $write_checked = '';
    if (isset($priv_data[$module_data['module_id']]['r']) and $priv_data[$module_data['module_id']]['r'] == 1) {
        $read_checked = 'checked';
    }
    if (isset($priv_data[$module_data['module_id']]['w']) and $priv_data[$module_data['module_id']]['w'] == 1) {
        $read_checked = 'checked';
        $write_checked = 'checked';
    }
    $chbox_read = '<input type="checkbox" class="read" name="read[]" value="' . $module_data['module_id'] . '" ' . $read_checked . ' />';
    $chbox_write = '<input type="checkbox" class="write" name="write[]" value="' . $module_data['module_id'] . '" ' . $write_checked . ' />';
    $table->appendTableRow(array(__(ucwords(str_replace('_', ' ', $module_data['module_name']))), $chbox_read, $chbox_write));
    $table->setCellAttr($row, 0, 'valign="top" class="' . $row_class . '" style="font-weight: bold;"');
    $table->setCellAttr($row, 1, 'valign="top" class="' . $row_class . '" style="width: 5%;"');
    $table->setCellAttr($row, 2, 'valign="top" class="' . $row_class . '" style="width: 5%;"');
    $row++;
}
echo $table->printTable();
ob_start();
?>
<script type="text/javascript">
    $(document).ready(function() {
       $('#allRead').toggle(function(evt) {
            evt.preventDefault();
            $('input:checkbox.read').attr('checked', 'checked');
        }, function(evt) {
            evt.preventDefault();
开发者ID:slims,项目名称:s3st15_matoa,代码行数:31,代码来源:module_priv_form.inc.php

示例14: array

    $hol_dayname = array();
    if ($rec_q->num_rows > 0) {
        while ($rec_d = $rec_q->fetch_row()) {
            $hol_dayname[] = $rec_d[0];
        }
    }
    // small function to check the checkbox
    function isChecked($str_data)
    {
        global $hol_dayname;
        if (in_array($str_data, $hol_dayname)) {
            return 'checked';
        }
    }
    // create table object
    $table = new simbio_table();
    $table->table_attr = 'align="center" class="border fullWidth" cellpadding="5" cellspacing="0"';
    // dayname list
    $table->appendTableRow(array('<input type="checkbox" name="dayname[]" value="mon" ' . isChecked('mon') . ' /> ' . __('Monday'), '<input type="checkbox" name="dayname[]" value="tue" ' . isChecked('tue') . ' /> ' . __('Tuesday'), '<input type="checkbox" name="dayname[]" value="wed" ' . isChecked('wed') . ' /> ' . __('Wednesday')));
    $table->appendTableRow(array('<input type="checkbox" name="dayname[]" value="thu" ' . isChecked('thu') . ' /> ' . __('Thursday'), '<input type="checkbox" name="dayname[]" value="fri" ' . isChecked('fri') . ' /> ' . __('Friday'), '<input type="checkbox" name="dayname[]" value="sat" ' . isChecked('sat') . ' /> ' . __('Saturday')));
    $table->appendTableRow(array('<input type="checkbox" name="dayname[]" value="sun" ' . isChecked('sun') . ' /> ' . __('Sunday')));
    // set cell attribute
    $table->setCellAttr(3, 0, 'colspan="3"');
    // submit button
    $table->appendTableRow(array('<input type="button" name="saveDaynameData" value="' . __('Save Settings') . '" onclick="$(\'#mainContent\').simbioAJAX(\'' . $_SERVER['PHP_SELF'] . '\', { method: \'POST\', addData: $(\'#holidayForm\').serialize() } )" />'));
    // set cell attribute
    $table->setCellAttr(4, 0, 'colspan="3" class="alterCell"');
    echo '<form name="holidayForm" id="holidayForm">';
    echo $table->printTable();
    echo '</form>';
}
开发者ID:banumelody,项目名称:slims7_cendana,代码行数:31,代码来源:holiday.php

示例15: __

<div class="menuBoxInner barcodeIcon">
    <?php 
echo __('Barcode Generator') . ' <hr />' . __('Type barcodes text to one or more text field below and click') . ' "' . __('Generate Barcodes') . '".';
?>
</div>
</fieldset>
<?php 
// create table object
$table = new simbio_table();
$table->table_attr = 'align="center" class="border fullWidth" cellpadding="5" cellspacing="0"';
// initial row count
$row = 1;
$row_num = 6;
// submit button
$table->appendTableRow(array(__('Barcode Size') . ' : <select name="size"><option value="1">' . __('Small') . '</option>
    <option value="2" selected>' . __('Medium') . '</option>
    <option value="3">' . __('Big') . '</option></select>'));
// set cell attribute
$table->setCellAttr($row, 0, 'colspan="3" class="alterCell"');
$row++;
// barcode text fields
while ($row <= $row_num) {
    $table->appendTableRow(array('<input type="text" name="barcode[]" style="width: 100%;" />', '<input type="text" name="barcode[]" style="width: 100%;" />', '<input type="text" name="barcode[]" style="width: 100%;" />'));
    $row++;
}
// submit button
$table->appendTableRow(array('<input type="submit" name="saveData" value="' . __('Generate Barcodes') . '" />'));
// set cell attribute
$table->setCellAttr($row_num + 1, 0, 'colspan="3" class="alterCell"');
echo '<form name="barcodeForm" id="barcodeForm" target="submitExec" method="post" action="' . $_SERVER['PHP_SELF'] . '">';
echo $table->printTable();
开发者ID:slims,项目名称:s3st14,代码行数:31,代码来源:barcode_generator.php


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