本文整理汇总了PHP中xtable::row_click方法的典型用法代码示例。如果您正苦于以下问题:PHP xtable::row_click方法的具体用法?PHP xtable::row_click怎么用?PHP xtable::row_click使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类xtable
的用法示例。
在下文中一共展示了xtable::row_click方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: xtable
<?php
require_once MODDIR . 'xtable/xtable.php';
require_once MODDIR . 'control.php';
$fmod = 'peminjaman_tabelcari';
$xtable = new xtable($fmod);
$keyword = gpost('keyword');
if ($keyword != '') {
// Query
$sql = "SELECT sar_barang.*,sar_katalog.nama FROM sar_barang LEFT JOIN sar_katalog ON sar_katalog.replid=sar_barang.katalog WHERE sar_barang.kode='{$keyword}' OR sar_katalog.nama LIKE '%{$keyword}%'";
$t = mysql_query($sql);
$xtable->ndata = mysql_num_rows($t);
if ($xtable->ndata > 0) {
// Table head
$xtable->head('kode');
while ($r = mysql_fetch_array($t)) {
$xtable->row_click($r['replid'], 'v');
$xtable->row_begin();
$n = mysql_num_rows(mysql_query("SELECT replid FROM sar_barang WHERE katalog='" . $r['replid'] . "'"));
$xtable->td($r['kode'], 80);
$xtable->opt($r['replid']);
$xtable->row_end();
}
$xtable->foot();
} else {
$xtable->nodata_cust('Tidak ditemukan data barang dengan kode atau nama <b>' . $keyword . '</b>.');
}
}
示例2: fRp
?>
<div class="tbltopmbar" style="float:left;margin-top:10px">
<table class="stable" cellspacing="0" cellpadding="0" width="100%">
<tr height="24px"><td width="100px">Total aset:</td><td><?php
echo fRp(lokasi_aset($lok));
?>
</td></tr>
</table>
</div>
<?php
if ($xtable->ndata > 0) {
// Table head
$xtable->head('@kode', '@nama Grup barang', 'Jumlah unit~C', 'Unit tersedia~C', 'Unit dipinjam~C', 'Total aset~R', 'Keterangan');
$nom = 1;
while ($r = mysql_fetch_array($t)) {
$xtable->row_click($r['replid'], 'v', $r['nama']);
$xtable->row_begin();
$n = mysql_num_rows(mysql_query("SELECT replid FROM sar_barang WHERE grup='" . $r['replid'] . "'"));
$xtable->td($r['kode'], 100);
$xtable->td($r['nama'], 200);
$xtable->td($n, 100, 'c');
$xtable->td(0, 100, 'c');
$xtable->td(0, 100, 'c');
$xtable->td(fRp(grup_aset($r['replid'])), 120, 'r');
$xtable->td(nl2br($r['keterangan']));
$xtable->opt($r['replid'], 'v', 'u', 'd');
$xtable->row_end();
}
$xtable->foot();
} else {
$xtable->nodata();