本文整理汇总了PHP中getDbArray函数的典型用法代码示例。如果您正苦于以下问题:PHP getDbArray函数的具体用法?PHP getDbArray怎么用?PHP getDbArray使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了getDbArray函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getMenu
function getMenu()
{
$queryresult = getDbArray("SELECT * FROM `meal`");
$newresult = array();
//gruppieren des Arrays nach caterer
foreach ($queryresult as $result) {
$caterer_id = $result["caterer_id"];
$index_caterer = FALSE;
for ($i = 0; $i < count($newresult); $i++) {
if ($newresult[$i][0] == $caterer_id) {
$index_caterer = $i;
break;
}
}
if ($index_caterer === FALSE) {
$newresult[] = array($caterer_id);
$index_caterer = count($newresult) - 1;
}
$newresult[$index_caterer][] = array($result["meal_name"], $result["meal_price"], $result["idmeal"]);
}
//kodieren in UTF8
$newresult = utf8($newresult);
return $newresult;
}
示例2: array
<?php
$_sort = array(array('hit', 'desc'), array('comment', 'desc'));
?>
[RESULT:
<ul>
<?php
$_date = date('YmdHis', mktime(0, 0, 0, substr($date['today'], 4, 2), substr($date['today'], 6, 2) - 30, $date['year']));
$_RCD = getDbArray($table['bbsdata'], 'site=' . $s . ' and display=1 and d_regis > ' . $_date, '*', $_sort[$type - 1][0], $_sort[$type - 1][1], $num, 1);
$_i = 0;
while ($_R = db_fetch_array($_RCD)) {
$_i++;
?>
<li><i<?php
if ($_i < 4) {
?>
class="emp"<?php
}
?>
><?php
echo $_i;
?>
</i><a href="<?php
echo getPostLink($_R);
?>
"><?php
echo $_R['subject'];
?>
示例3: while
while (false !== ($files = readdir($dirh))) {
if (substr($files, -4) != '.php') {
continue;
}
$incs[] = str_replace('.php', '', $files);
}
closedir($dirh);
return $incs;
}
include $g['path_module'] . $module . '/var/var.search.php';
include $g['path_module'] . $module . '/var/var.order.php';
$MODULE_LIST = getDbArray($table['s_module'], '', '*', 'gid', 'asc', 0, $p);
$_names = array();
$PAGESET = array();
$TMPST = array();
$SITES = getDbArray($table['s_site'], '', '*', 'gid', 'asc', 0, $p);
$SITEN = db_num_rows($SITES);
?>
<div class="row" id="search-body">
<div class="col-sm-4 col-lg-3 rb-aside">
<div class="panel-group" id="accordion">
<div class="panel panel-default">
<div class="panel-heading rb-icon">
<div class="icon">
<i class="fa fa-search fa-2x"></i>
</div>
<h4 class="panel-title">
<a class="accordion-toggle collapsed" data-parent="#accordion" data-toggle="collapse" href="#collapseOne">
<?php
echo _LANG('a1001', 'search');
示例4: getUidData
if ($_HH['usemobile'] == 1) {
$_HS = getUidData($table['s_site'], $_HH['startsite']);
} else {
if ($_HH['usemobile'] == 2) {
if ($g['url_root'] . '/' != $_HH['startdomain']) {
getLink($_HH['startdomain'], '', '', '');
}
}
}
}
if (!$_HS['uid']) {
$_HD = getDbData($table['s_domain'], "name='" . str_replace('www.', '', $_SERVER['HTTP_HOST']) . "'", '*');
if ($_HD['site']) {
$_HS = getUidData($table['s_site'], $_HD['site']);
} else {
$_HS = db_fetch_array(getDbArray($table['s_site'], '', '*', 'gid', 'asc', 1, 1));
}
}
$s = $_HS['uid'];
$r = $_HS['id'];
} else {
$_HS = getUidData($table['s_site'], $s);
}
if (!$_HS['lang']) {
$_HS['lang'] = $g['sys_lang'];
}
require $g['path_var'] . 'language/' . $_HS['lang'] . '/_sys.lang.php';
$_CA = array();
$date = getVDate($_HS['timecal']);
$g['s'] = str_replace('/index.php', '', $_SERVER['SCRIPT_NAME']);
$g['r'] = $_HS['rewrite'] ? $g['s'] . ($_HS['usescode'] ? '/' . $r : '') : '.';
示例5: cmentDel
" onclick="return cmentDel('<?php
echo $R['id'];
?>
',event);"><img src="<?php
echo $g['img_module_skin'];
?>
/btn_delete.gif" alt="삭제" title="삭제" /></a> <a href="javascript:;" onclick="doReply('<?php
echo $R['uid'];
?>
')"><img src="<?php
echo $g['img_module_skin'];
?>
/btn_modify.gif" alt="답변" title="답변" /></a></td>
</tr>
<?php
$TCD = getDbArray($table['s_oneline'], 'parent=' . $R['uid'], '*', 'uid', $d['comment']['orderby2'], 0, 0);
?>
<?php
while ($O = db_fetch_array($TCD)) {
?>
<?php
// echo $TPG . " = " . $p;// echo "<pre>"; print_r( $O ); echo "</pre>";
?>
<tr class="reply">
<td>┗ <div class="icon inline"><?php
echo $O['nic'];
?>
</div></td>
<td class="sbj"><?php
echo $O['content'];
?>
示例6: getDbArray
}
?>
<?php
if (!db_num_rows($SITES)) {
?>
<option value="">등록된 사이트가 없습니다.</option>
<?php
}
?>
</select>
<select name="bid" onchange="this.form.submit();">
<option value=""> + 전체게시판</option>
<option value="">---------------------------</option>
<?php
$_BBSLIST = getDbArray($table[$module . 'list'], '', '*', 'gid', 'asc', 0, 1);
?>
<?php
while ($_B = db_fetch_array($_BBSLIST)) {
?>
<option value="<?php
echo $_B['uid'];
?>
"<?php
if ($_B['uid'] == $bid) {
?>
selected="selected"<?php
}
?>
>ㆍ<?php
echo $_B['name'];
示例7: getLink
}
include_once $g['path_module'] . $m . '/var/var.php';
if ($cync) {
$_SESSION[$m . 'cync'] = $cync;
}
if (!$_SESSION[$m . 'cync']) {
getLink(RW(0), '', '동기화코드가 지정되지 않았습니다.', '');
}
$cyncArr = getArrayString($_SESSION[$m . 'cync']);
$mod = 'main';
$sort = $sort ? $sort : 'uid';
$orderby = $orderby ? $orderby : 'asc';
$recnum = $recnum && $recnum < 200 ? $recnum : $d['trackback']['recnum'];
$cmentque = "parent='" . $cyncArr['data'][0] . $cyncArr['data'][1] . "' and type=1";
$RCD = array();
$TCD = getDbArray($table['s_trackback'], $cmentque, '*', $sort, $orderby, $recnum, $p);
$NUM = getDbRows($table['s_trackback'], $cmentque);
$TPG = getTotalPage($NUM, $recnum);
while ($_R = db_fetch_array($TCD)) {
$RCD[] = $_R;
}
if ($g['mobile'] && $_SESSION['pcmode'] != 'Y') {
$B['skin'] = $d['trackback']['skin_mobile'];
} else {
$B['skin'] = $skin ? $skin : $d['trackback']['skin_main'];
}
$g['track_reset'] = $c ? $g['s'] . '/?r=' . $r . '&c=' . $c : getLinkFilter($g['s'] . '/?r=' . $r . '&m=' . $m, array('skin', 'iframe'));
$g['track_list'] = $g['track_reset'] . getLinkFilter('', array('p', 'sort', 'orderby', 'recnum', 'where', 'keyword'));
$g['track_action'] = $g['track_list'] . '&a=';
$g['track_delete'] = $g['track_action'] . 'delete&uid=';
$g['dir_module_skin'] = $g['dir_module'] . 'theme/' . $B['skin'] . '/';
示例8: getDbArray
echo $g['s'];
?>
/" method="post" class="rb-form">
<input type="hidden" name="r" value="<?php
echo $r;
?>
">
<input type="hidden" name="m" value="<?php
echo $module;
?>
">
<input type="hidden" name="a" value="">
<div class="dd" id="nestable-menu">
<ol class="dd-list">
<?php
$ADMPAGE = getDbArray($table['s_admpage'], 'memberuid=' . $my['uid'], '*', 'gid', 'asc', 0, 1);
?>
<?php
$_i = 1;
while ($R = db_fetch_array($ADMPAGE)) {
?>
<li class="dd-item dd3-item" data-id="<?php
echo $_i;
?>
">
<div class="dd-handle dd3-handle"></div>
<div class="dd3-content"><a href="<?php
echo $R['url'];
?>
"><?php
echo $R['name'];
示例9: getCommentList
function getCommentList($theme, $parent, $_where, $recnum, $sort, $orderby1, $orderby2, $cp)
{
global $g, $table, $_HS, $m, $my;
include $theme . '_var.php';
// 설정파일 인클루드
$g['img_module_skin'] = $theme . 'image/';
$NCD = array();
$RCD = array();
$cp = $cp ? $cp : 1;
$sort = $sort ? $sort : 'uid';
$orderby1 = $orderby1 ? $orderby1 : $d['comment']['orderby1'];
$orderby2 = $orderby2 ? $orderby2 : $d['comment']['orderby2'];
$recnum = $recnum ? $recnum : $d['comment']['recnum'];
$cmentque = " and parent='" . str_replace('-', '', $parent) . "'";
if ($_where) {
$cmentque .= " and " . $_where;
}
$PCD = getDbArray($table['s_comment'], 'notice=1' . $cmentque, '*', $sort, $orderby1, 0, 0);
$TCD = getDbArray($table['s_comment'], 'notice=0' . $cmentque, '*', $sort, $orderby2, $recnum, $cp);
$NUM = getDbRows($table['s_comment'], 'notice=0' . $cmentque);
$TPG = getTotalPage($NUM, $recnum);
while ($_R = db_fetch_array($PCD)) {
$NCD[] = $_R;
}
while ($_R = db_fetch_array($TCD)) {
$RCD[] = $_R;
}
//echo $cmentque;
$RCD = $NCD + $RCD;
$i = 1;
$namegi = $NUM - $cp * $recnum;
if ($namegi > 0) {
$namegi_ment = '총 <span class="text-danger namegi">' . $namegi . '</span> 개의 댓글이 더 있습니다.';
$btn_more = 'btn-more';
$is_namegi = 1;
} else {
$namegi_ment = '더이상 댓글이 없습니다.';
$btn_more = 'disabled';
$is_namegi = 0;
}
// 한줄의견 쓰는(현재 로그인한) 사용자 아바타 사진 url 세팅
if ($my['photo']) {
$avatar_img = $g['url_root'] . '/_var/avatar/' . $my['photo'];
} else {
$avatar_img = $g['url_root'] . '/_var/avatar/0.gif';
}
foreach ($RCD as $C) {
$C['mobile'] = isMobileConnect($C['agent']);
if ($C['mbruid']) {
$M = getDbData($table['s_mbrdata'], 'memberuid=' . $C['mbruid'], '*');
} else {
$M = array();
}
$isSECRETCHECK = true;
$JN_time = getJNTime($C['d_regis']);
// 지난시간 얻기 함수 호출
// 댓글 작성자 아바타 사진 url 세팅
if ($M['photo']) {
$avatar_img = $g['url_root'] . '/_var/avatar/' . $M['photo'];
} else {
$avatar_img = $g['url_root'] . '/_var/avatar/0.gif';
}
echo '
<section id="pinBoot" class="rb-pinterest-grid">
<article class="panel panel-default panel-google-plus comment-list" id="' . $C['uid'] . '-' . $C['score1'] . '-' . $C['oneline'] . '">
<div id="cuid-' . $C['uid'] . '">
<input type="hidden" name="is_namegi" value="' . $is_namegi . '"/>
<input type="hidden" name="TPG" value="' . $TPG . '"/>
<input type="hidden" name="theme" class="theme" value="' . $theme . '" />
<input type="hidden" name="parent" class="parent" value="' . $parent . '" />
<input type="hidden" name="c_content" class="c_content" value="' . htmlspecialchars(getContents($C['content'], $C['html'], $keyword)) . '" />
<div class="dropdown">
<span class="dropdown-toggle" type="button" data-toggle="dropdown">
<span class="[ glyphicon glyphicon-chevron-down ]"></span>
</span>
<ul class="dropdown-menu" role="menu">
<li role="presentation"><a role="menuitem" tabindex="-1" href="#">Action</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="#">Another action</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="#">Something else here</a></li>
<li role="presentation" class="divider"></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="#">Separated link</a></li>
</ul>
</div>
<div class="panel-google-plus-tags">
<ul>
<li>#자동차</li>
<li>#귀성길</li>
</ul>
</div>
<div class="panel-heading">
<img class="img-circle pull-left" src="/_core/opensrc/thumb/image.php?width=46&height:46&cropratio=1:1&image=' . $avatar_img . '" alt="' . $M[$_HS['nametype']] . ' 아바타 " />
<h3>소비자와 함께</h3>
<h5><span>제한적으로 공유함</span> - <span>' . getDateFormat($C['d_regis'], 'Y. m. d') . '</span> </h5>
</div>
<div class="panel-body">
<p>' . getContents($C['content'], $C['html'], $keyword) . '</p>
</div>
<div class="panel-footer">
<button type="button" class="btn btn-default">+1</button>
<button type="button" class="btn btn-default">
//.........这里部分代码省略.........
示例10: getDbArray
<?php
$sort = $sort ? $sort : 'gid';
$orderby = $orderby ? $orderby : 'asc';
$recnum = $recnum && $recnum < 91 ? $recnum : 30;
$RCD = getDbArray($table['s_module'], '', '*', $sort, $orderby, $recnum, $p);
$NUM = getDbRows($table['s_module'], '');
$TPG = getTotalPage($NUM, $recnum);
if (!$id) {
$id = 'home';
}
$R = getDbData($table['s_module'], "id='" . $id . "'", '*');
?>
<div id="catebody">
<div id="category">
<form name="mform1" action="<?php
echo $g['s'];
?>
/" method="post" target="_action_frame_<?php
echo $m;
?>
">
<input type="hidden" name="r" value="<?php
echo $r;
?>
" />
<input type="hidden" name="m" value="<?php
echo $module;
?>
" />
示例11: getDbArray
}
?>
/>이 레이아웃에서 제공하는 메인화면(게시판 생성 필요)</label><br />
<label><input type="checkbox" name="mainType_rb" value="1"<?php
if ($d['layout']['mainType_rb']) {
?>
checked="checked"<?php
}
?>
/>킴스큐 자체에서 꾸미는 메인화면(직접꾸미기,위젯꾸미기,모듈콘텐츠 연결)</label><br />
</div>
</td>
</tr>
<?php
if ($d['layout']['mainType_layout']) {
$BBSLIST = getDbArray($table['bbslist'], '', '*', 'gid', 'asc', 0, 1);
$_RCD = array();
while ($_B = db_fetch_array($BBSLIST)) {
$_RCD[] = $_B;
}
?>
<tr>
<td class="t1">상단출력 대상물</td>
<td class="t2">:</td>
<td class="t3">
<select name="bbs1" class="select1">
<option value="0"<?php
if ($d['layout']['bbs1'] == '0') {
?>
selected="selected"<?php
}
示例12: ftp_pasv
}
if ($d['upload']['ftp_pasv']) {
ftp_pasv($FTP_CONNECT, true);
}
$FILES = getDbArray($table['s_upload'], "tmpcode='" . $sescode . "'", '*', 'uid', 'asc', 0, 0);
while ($R = db_fetch_array($FILES)) {
getDbDelete($table['s_upload'], 'uid=' . $R['uid']);
getDbUpdate($table['s_numinfo'], 'upload=upload-1', "date='" . substr($R['d_regis'], 0, 8) . "' and site=" . $R['site']);
ftp_delete($FTP_CONNECT, $d['upload']['ftp_folder'] . $R['folder'] . '/' . $R['tmpname']);
if ($R['type'] == 2) {
ftp_delete($FTP_CONNECT, $d['upload']['ftp_folder'] . $R['folder'] . '/' . $R['thumbname']);
}
}
ftp_close($FTP_CONNECT);
} else {
$FILES = getDbArray($table['s_upload'], "tmpcode='" . $sescode . "'", '*', 'uid', 'asc', 0, 0);
while ($R = db_fetch_array($FILES)) {
getDbDelete($table['s_upload'], 'uid=' . $R['uid']);
getDbUpdate($table['s_numinfo'], 'upload=upload-1', "date='" . substr($R['d_regis'], 0, 8) . "' and site=" . $R['site']);
unlink($g['path_file'] . $R['folder'] . '/' . $R['tmpname']);
if ($R['type'] == 2) {
unlink($g['path_file'] . $R['folder'] . '/' . $R['thumbname']);
}
}
}
}
if ($close == 'Y') {
$_SESSION['upsescode'] = '';
getLink('', '', '', 'close');
} else {
getLink('reload', 'parent.', '', '');
示例13: array
$_QUE = 'site=' . $s . ' and hidden=0';
if ($mbruid) {
$_QUE .= ' and mbruid=' . $mbruid;
}
if ($B['uid']) {
$_QUE .= ' and bbs=' . $B['uid'];
}
$RCD = array();
if ($mbruid) {
$M = getDbData($table['s_mbrdata'], 'memberuid=' . $mbruid, '*');
$TCD = getDbArray($table[$m . 'data'], $_QUE, '*', $sort, $orderby, $recnum, $p);
while ($_R = db_fetch_array($TCD)) {
$RCD[] = $_R;
}
} else {
$TCD = getDbArray($table[$m . 'data'], $_QUE, 'gid', $sort, $orderby, $recnum, $p);
while ($_R = db_fetch_array($TCD)) {
$RCD[] = getDbData($table[$m . 'data'], 'gid=' . $_R['gid'], '*');
}
}
Header("Content-type: text/xml");
header("Cache-Control: no-cache, must-revalidate");
header("Pragma: no-cache");
echo "<?xml version='1.0' encoding='utf-8'?>\r\n\r\n";
if ($type == 'rss1') {
?>
<rss version='2.0' xmlns:dc='http://purl.org/dc/elements/1.1/'>
<channel>
<title><?php
echo $mbruid ? $M[$_HS['nametype']] . '님의 포스트' : htmlspecialchars($B['name'] ? $B['name'] : $_HS['name']);
示例14: getDbArray
echo $infoNotice_element[uid];
?>
"><?php
echo $infoNotice_element[subject];
?>
</a></li>
<?php
}
?>
</ul>
</li>
<li class="noMargin">
<h1><a href="http://www.trevia.co.kr/?r=mexico&m=bbs&bid=epilogue"><img src="/pages/image/trevia_main_travelstory.gif" alt="여행후기 안내" /></a></h1>
<ul class="latestArticle">
<?php
$infoNotice = getDbArray($table['bbsdata'], "site = 7 AND bbs = 6 AND (bbsid='epilogue' OR bbsid='epilogue') AND notice = 0", "uid, subject,site", "gid", "asc", "5", "1");
?>
<?php
for ($i = 0; $infoNotice_element = db_fetch_array($infoNotice); $i++) {
?>
<li><a href="./?r=dubai&m=bbs&uid=<?php
echo $infoNotice_element[uid];
?>
"><?php
echo $infoNotice_element[subject];
?>
</a></li>
<?php
}
?>
</ul>
示例15: getDbArray
echo $wdgvar['title'];
?>
</a></h6>
<?php
} else {
?>
<h6><?php
echo $wdgvar['title'];
?>
</h6>
<?php
}
?>
<ul>
<?php
$_RCD = getDbArray($table['bbsdata'], ($wdgvar['bid'] ? 'bbs=' . $wdgvar['bid'] . ' and ' : '') . 'display=1 and site=' . $_HS['uid'], '*', 'gid', 'asc', $wdgvar['limit'], 1);
?>
<?php
$k = 0;
while ($_R = db_fetch_array($_RCD)) {
$k++;
?>
<?php
$_thumbimg = getUploadImage($_R['upload'], $_R['d_regis'], $_R['content'], 'jpg|jpeg');
?>
<?php
$_thumbimg = $_thumbimg ? $_thumbimg : $g['img_core'] . '/blank.gif';
?>
<?php
$_link = getPostLink($_R);
?>