• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

PHP form_str函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中form_str函数的典型用法代码示例。如果您正苦于以下问题:PHP form_str函数的具体用法?PHP form_str怎么用?PHP form_str使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



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

示例1: elseif

     } elseif (!empty(${'u_ccids' . $coid})) {
         $ccids = ${'u_ccids' . $coid};
     }
     if (!empty($ccids)) {
         if ($cnsql = cnsql($coid, $ccids, 'a.')) {
             $wheresql .= " AND {$cnsql}";
         }
     } elseif (!empty(${"ccid{$coid}"}) || !empty(${'u_ccids' . $coid})) {
         $no_list = true;
     }
     ${"ccid{$coid}"} && ($filterstr .= "&ccid{$coid}=" . ${"ccid{$coid}"});
 }
 $wheresql = "WHERE " . (empty($no_list) ? $wheresql : '1=0');
 if (!submitcheck('barcsedit')) {
     if (empty($u_tplname)) {
         echo form_str($actionid . 'arcsedit', "?entry=archives&action={$action}&page={$page}{$param_suffix}");
         //搜索区块
         tabheader_e();
         echo "<tr><td colspan=\"2\" class=\"txt txtleft\">";
         //关键词固定显示
         echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" size=\"8\" style=\"vertical-align: middle;\">&nbsp; ";
         //模型搜索
         if (empty($u_filters) || in_array('channel', $u_filters)) {
             $chidsarr = array('0' => lang('all_channel')) + chidsarr();
             echo "<select style=\"vertical-align: middle;\" name=\"chid\">" . makeoption($chidsarr, $chid) . "</select>&nbsp; ";
         }
         $statusarr = array('-1' => lang('nolimit'), '0' => lang('update_need'), '1' => lang('checkneed'), '2' => lang('overupdate'));
         echo "<select style=\"vertical-align: middle;\" name=\"status\">" . makeoption($statusarr, $status) . "</select>&nbsp; ";
         echo "<input class=\"btn\" type=\"submit\" name=\"bfilter\" id=\"bfilter\" value=\"" . lang('filter0') . "\">" . viewcheck('viewdetail', $viewdetail, $actionid . 'tbodyfilter');
         echo "</td></tr>";
         //某些固定页面参数
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:archives.inc.php


示例2: foreach

 foreach (array('keyword', 'viewdetail', 'caid', 'mainline', 'cnlevel', 'inconfig') as $k) {
     $filterstr .= "&{$k}=" . urlencode(${$k});
 }
 foreach ($cotypes as $coid => $cotype) {
     if ($cotype['sortable']) {
         ${"ccid{$coid}"} = isset(${"ccid{$coid}"}) ? ${"ccid{$coid}"} : 0;
         if (!empty(${"ccid{$coid}"})) {
             $filterstr .= "&ccid{$coid}=" . ${"ccid{$coid}"};
             $wheresql .= " AND ename REGEXP 'ccid{$coid}=" . ${"ccid{$coid}"} . "(&|\$)'";
         }
     }
 }
 $wheresql = $wheresql ? "WHERE " . $wheresql : "";
 if (!submitcheck('bcnodescommon')) {
     url_nav(lang('cnodeadmin'), $urlsarr, 'cnodescommon');
     echo form_str('cnodescommon', "?entry={$entry}&action={$action}{$param_suffix}&page={$page}");
     tabheader_e();
     echo "<tr><td colspan=\"2\" class=\"txt txtleft\">";
     //关键词固定显示
     echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" size=\"8\" style=\"vertical-align: middle;\">&nbsp; ";
     echo "<select name=\"caid\">" . makeoption(array('0' => lang('catalog_attr')) + caidsarr($catalogs), $caid) . "</select>&nbsp; ";
     echo "<select name=\"cnlevel\">" . makeoption(array('0' => lang('cnodelevelnum'), '1' => lang('acrossleve1'), '2' => lang('acrossleve2'), '3' => lang('acrossleve3'), '4' => lang('acrossleve4')), $cnlevel) . "</select>&nbsp; ";
     echo strbutton('bfilter', 'filter0') . viewcheck('viewdetail', $viewdetail, 'tbodyfilter');
     echo "</td></tr>";
     echo "<tbody id=\"tbodyfilter\" style=\"display: " . (empty($viewdetail) ? 'none' : '') . "\">";
     $mainlinearr = array('-1' => lang('nolimit'), '0' => lang('catalog'));
     foreach ($cotypes as $k => $v) {
         if ($v['sortable']) {
             $mainlinearr[$k] = $v['cname'];
         }
     }
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:cnodes.inc.php


示例3: rawurlencode

     ${$k} && ($filterstr .= "&{$k}=" . rawurlencode(stripslashes(${$k})));
 }
 foreach (array('checked', 'valid') as $k) {
     ${$k} != -1 && ($filterstr .= "&{$k}=" . ${$k});
 }
 //处理ucotype的筛选
 foreach ($ucotypes as $k => $v) {
     if (!empty(${'uccid' . $k}) && $v['cclass'] == 'offer') {
         $filterstr .= "&uccid{$k}=" . ${'uccid' . $k};
         $wheresql .= " AND cu.uccid{$k}='" . ${'uccid' . $k} . "'";
     }
 }
 $wheresql = "WHERE " . (empty($no_list) ? $wheresql : '1=0');
 if (!submitcheck('barcsedit')) {
     if (empty($u_tplname)) {
         echo form_str($action . 'archivesedit', "?action=offers&nmuid={$nmuid}&page={$page}");
         tabheader_e();
         echo "<tr><td class=\"item2\">";
         echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" size=\"8\" style=\"vertical-align: middle;\">&nbsp; ";
         //审核状态
         if (in_array('check', $u_filters)) {
             $checkedarr = array('-1' => lang('nolimit') . lang('check'), '0' => lang('nocheck'), '1' => lang('checked'));
             echo "<select style=\"vertical-align: middle;\" name=\"checked\">" . makeoption($checkedarr, $checked) . "</select>&nbsp; ";
         }
         //有效状态
         if (in_array('valid', $u_filters)) {
             $validarr = array('-1' => lang('nolimit') . lang('available'), '0' => lang('invalid'), '1' => lang('available'));
             echo "<select style=\"vertical-align: middle;\" name=\"valid\">" . makeoption($validarr, $valid) . "</select>&nbsp; ";
         }
         //栏目搜索
         if (in_array('catalog', $u_filters)) {
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:offers.inc.php


示例4: max

 if (empty($u_tplname) || !empty($u_onlyview)) {
     $page = !empty($page) ? max(1, intval($page)) : 1;
     submitcheck('bfilter') && ($page = 1);
     $keyword = empty($keyword) ? '' : $keyword;
     $wheresql = "a.aid='{$aid}'";
     $fromsql = "FROM {$tblprefix}reports cu LEFT JOIN {$tblprefix}archives a ON a.aid=cu.aid";
     //搜索关键词处理
     $keyword && ($wheresql .= " AND (cu.mname LIKE '%" . str_replace(array(' ', '*'), '%', addcslashes($keyword, '%_')) . "%' OR a.subject LIKE '%" . str_replace(array(' ', '*'), '%', addcslashes($keyword, '%_')) . "%')");
     $filterstr = '';
     foreach (array('niuid', 'keyword') as $k) {
         ${$k} && ($filterstr .= "&{$k}=" . rawurlencode(stripslashes(${$k})));
     }
     $wheresql = "WHERE " . (empty($no_list) ? $wheresql : '1=0');
     if (!submitcheck('barcsedit')) {
         if (empty($u_tplname)) {
             echo form_str($actionid . 'arcsedit', "?entry=inarchive&action=reports&aid={$aid}&page={$page}{$param_suffix}");
             //搜索区块
             tabheader_e();
             echo "<tr><td colspan=\"2\" class=\"txt txtleft\">";
             //关键词固定显示
             echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" size=\"8\" style=\"vertical-align: middle;\">&nbsp; ";
             echo "<input class=\"btn\" type=\"submit\" name=\"bfilter\" id=\"bfilter\" value=\"" . lang('filter0') . "\">";
             echo "</td></tr>";
             //某些固定页面参数
             trhidden('niuid', $niuid);
             tabfooter();
             //列表区
             tabheader($aedit->archive['subject'] . '&nbsp; ' . lang('report_list'), '', '', 9);
             $cy_arr = array("<input class=\"checkbox\" type=\"checkbox\" name=\"chkall\" onclick=\"checkall(this.form, 'selectid', 'chkall')\">", lang('title'));
             if (in_array('mname', $u_lists)) {
                 $cy_arr[] = lang('member');
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:inarchive.inc.php


示例5: rawurlencode

 //	$outdays && $wheresql .= ($wheresql ? ' AND ' : '')."regdate<'".($timestamp - 86400 * $outdays)."'";
 $filterstr = '';
 $keyword && ($filterstr .= "&keyword=" . rawurlencode(stripslashes($keyword)));
 //	foreach($grouptypes as $gtid => $grouptype){
 //		${"ugid$gtid"} = empty(${"ugid$gtid"}) ? 0 : ${"ugid$gtid"};
 //		if(${"ugid$gtid"}){
 //			$filterstr .= "&ugid$gtid=".${"ugid$gtid"};
 //			if(!empty(${"u_ugids$k"}) && !in_array(${"ugid$gtid"},${"u_ugids$k"})) $no_list = 1;
 //			$wheresql .= ($wheresql ? ' AND ' : '')."grouptype$gtid='".${"ugid$gtid"}."'";
 //		}elseif(!empty(${"u_ugids$k"})) $wheresql .= ($wheresql ? ' AND ' : '')."grouptype$gtid ".multi_str(${"ugid$gtid"});
 //	}
 $wheresql = empty($no_list) ? $wheresql ? "WHERE {$wheresql}" : '' : 'WHERE 1=0';
 //echo $wheresql;
 if (!submitcheck('barcsedit')) {
     if (empty($u_tplname)) {
         echo form_str($actionid . 'memberedit', "?entry={$entry}&action={$action}&page={$page}");
         //搜索区块
         tabheader_e();
         //			trhidden('mchid',$mchid);
         //			trhidden('nauid',$nauid);
         echo "<tr><td colspan=\"2\" class=\"txt txtleft\">";
         //关键词固定显示
         echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" size=\"8\" style=\"vertical-align: middle;\">&nbsp; ";
         //类系筛选
         //			foreach($grouptypes as $gtid => $grouptype){
         //				if(in_array("ugid$gtid",$u_filters)){
         //					$ugidsarr = array('0' => $grouptype['cname']) + ugidsarr($gtid);
         //					echo "<select style=\"vertical-align: middle;\" name=\"ugid$gtid\">".makeoption($ugidsarr,${"ugid$gtid"})."</select>&nbsp; ";
         //				}
         //			}
         echo "<input class=\"btn\" type=\"submit\" name=\"bfilter\" id=\"bfilter\" value=\"" . lang('filter0') . "\">";
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:mreports.inc.php


示例6: empty

     ${"ugid{$k}"} = empty(${"ugid{$k}"}) ? 0 : ${"ugid{$k}"};
     if (${"ugid{$k}"}) {
         $filterstr .= "&ugid{$k}=" . ${"ugid{$k}"};
         if (!empty(${"u_ugids{$k}"}) && !in_array(${"ugid{$k}"}, ${"u_ugids{$k}"})) {
             $no_list = 1;
         }
         $wheresql .= ($wheresql ? ' AND ' : '') . "grouptype{$k}='" . ${"ugid{$k}"} . "'";
     } elseif (!empty(${"u_ugids{$k}"})) {
         $wheresql .= ($wheresql ? ' AND ' : '') . "grouptype{$k} " . multi_str(${"u_ugids{$k}"});
     }
 }
 $wheresql = empty($no_list) ? $wheresql ? "WHERE {$wheresql}" : '' : 'WHERE 1=0';
 //echo $wheresql;
 if (!submitcheck('barcsedit')) {
     if (empty($u_tplname)) {
         echo form_str($actionid . 'memberedit', "?entry=members&action=membersedit&page={$page}");
         //搜索区块
         tabheader_e();
         trhidden('mchid', $mchid);
         trhidden('nauid', $nauid);
         echo "<tr><td colspan=\"2\" class=\"txt txtleft\">";
         //关键词固定显示
         echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" size=\"8\" style=\"vertical-align: middle;\">&nbsp; ";
         //审核状态
         if (empty($u_filters) || in_array('check', $u_filters)) {
             $checkedarr = array('-1' => lang('check_state'), '0' => lang('nocheck'), '1' => lang('checked'));
             echo "<select style=\"vertical-align: middle;\" name=\"checked\">" . makeoption($checkedarr, $checked) . "</select>&nbsp; ";
         }
         //类系筛选
         foreach ($grouptypes as $gtid => $grouptype) {
             if (in_array("ugid{$gtid}", $u_filters)) {
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:members.inc.php


示例7: elseif

 } elseif ($u_checked != -1) {
     $wheresql .= " AND cu.checked='{$u_checked}'";
 }
 //搜索关键词处理
 $keyword && ($wheresql .= " AND (cu.mname LIKE '%" . str_replace(array(' ', '*'), '%', addcslashes($keyword, '%_')) . "%' OR a.subject LIKE '%" . str_replace(array(' ', '*'), '%', addcslashes($keyword, '%_')) . "%')");
 $filterstr = '';
 foreach (array('nimuid', 'keyword') as $k) {
     ${$k} && ($filterstr .= "&{$k}=" . rawurlencode(stripslashes(${$k})));
 }
 foreach (array('checked') as $k) {
     ${$k} != -1 && ($filterstr .= "&{$k}=" . ${$k});
 }
 $wheresql = "WHERE " . (empty($no_list) ? $wheresql : '1=0');
 if (!submitcheck('barcsedit')) {
     if (empty($u_tplname)) {
         echo form_str($action . 'arcsedit', "?action=inreplys&aid={$aid}&page={$page}");
         tabheader_e();
         echo "<tr><td colspan=\"2\" class=\"txt txtleft\">";
         echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" size=\"8\" style=\"vertical-align: middle;\">&nbsp; ";
         if (empty($u_filters) || in_array('check', $u_filters)) {
             $checkedarr = array('-1' => lang('nolimit') . lang('check'), '0' => lang('nocheck'), '1' => lang('checked'));
             echo "<select style=\"vertical-align: middle;\" name=\"checked\">" . makeoption($checkedarr, $checked) . "</select>&nbsp; ";
         }
         echo strbutton('bfilter', 'filter0') . '</td></tr>';
         trhidden('nimuid', $nimuid);
         tabfooter();
         //列表区
         tabheader(empty($u_mtitle) ? lang('replylist') : $u_mtitle, '', '', 9);
         $cy_arr = array("<input class=\"checkbox\" type=\"checkbox\" name=\"chkall\" onclick=\"checkall(this.form, 'selectid', 'chkall')\">", array(lang('title'), 'item2'), lang('member'));
         foreach ($ucotypes as $k => $v) {
             if (in_array('uccid' . $k, $u_lists) && $v['cclass'] == 'reply') {
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:inreplys.inc.php


示例8: exit

!defined('M_COM') && exit('No Permission');
include_once M_ROOT . "./include/arcedit.cls.php";
load_cache('acatalogs,channels,currencys');
$catalogs =& $acatalogs;
$forward = empty($forward) ? M_REFERER : $forward;
$page = !empty($page) ? max(1, intval($page)) : 1;
submitcheck('bfilter') && ($page = 1);
$keyword = empty($keyword) ? '' : $keyword;
$filterstr = '';
foreach (array('keyword') as $k) {
    $filterstr .= "&{$k}=" . rawurlencode(${$k});
}
$wheresql = "WHERE f.mid='{$memberid}'";
$keyword && ($wheresql .= " AND a.subject LIKE '%" . str_replace(array(' ', '*'), '%', addcslashes($keyword, '%_')) . "%'");
if (!submitcheck('barcsedit')) {
    echo form_str($action . 'arcsedit', "?action=favorites");
    tabheader_e();
    echo "<tr><td class=\"item2\">";
    echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" style=\"vertical-align: middle;\">&nbsp; ";
    echo strbutton('bfilter', 'filter0') . '</td></tr>';
    tabfooter();
    $pagetmp = $page;
    do {
        $query = $db->query("SELECT f.*,a.* FROM {$tblprefix}favorites f LEFT JOIN {$tblprefix}archives a ON a.aid=f.aid {$wheresql} ORDER BY f.aid DESC LIMIT " . ($pagetmp - 1) * $mrowpp . ",{$mrowpp}");
        $pagetmp--;
    } while (!$db->num_rows($query) && $pagetmp);
    $itemstr = '';
    while ($item = $db->fetch_array($query)) {
        $aid = $item['aid'];
        $item['arcurl'] = view_arcurl($item);
        $castr = empty($catalogs[$item['caid']]) ? lang('nocata') : $catalogs[$item['caid']]['title'];
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:favorites.inc.php


示例9: array_filter

}
if (!empty($aids)) {
    $aidsarr = array_filter(explode(',', $aids));
    $wheresql .= " AND aid " . multi_str($aidsarr);
}
$table != -1 && ($wheresql .= ($wheresql ? " AND " : "") . "tid='{$table}'");
$filterstr = '';
foreach (array('aids', 'type', 'table') as $k) {
    $filterstr .= "&{$k}=" . urlencode(${$k});
}
if (!submitcheck('buserfilesedit')) {
    //同include/upload.cls.php中closure函数的$tids变量对应
    $tabsarr = array('-1' => lang('alltype'), 1 => lang('archive'), 2 => lang('freeinfo'), 3 => lang('member'), 4 => lang('marchive'), 16 => lang('comment'), 17 => lang('reply'), 18 => lang('offer'), 32 => lang('mcomment'), 33 => lang('mreply'), '0' => lang('other'));
    $linkarr = array(1 => 'archive&aid=', 2 => 'farchive&aid=', 3 => 'memberinfo&mid=', 4 => 'marchive&maid=', 16 => 'comment&cid=', 17 => 'reply&cid=', 18 => 'offer&cid=', 32 => 'mcomment&cid=', 33 => 'mreply&cid=');
    $typearr = array('0' => lang('alltype'), 'image' => lang('image'), 'flash' => lang('flash'), 'media' => lang('media'), 'file' => lang('other'));
    echo form_str($action . 'arcsedit', "?action=userfiles");
    tabheader_e();
    echo "<tr><td class=\"item2\">";
    echo lang('aidstxt') . "&nbsp; <input class=\"text\" name=\"aids\" type=\"text\" value=\"{$aids}\" style=\"vertical-align: middle;\">&nbsp; ";
    echo "<select style=\"vertical-align: middle;\" name=\"type\">" . makeoption($typearr, $type) . "</select>&nbsp; ";
    echo "<select style=\"vertical-align: middle;\" name=\"table\">" . makeoption($tabsarr, $table) . "</select>&nbsp; ";
    echo strbutton('bfilter', 'filter0') . '</td></tr>';
    tabfooter();
    $pagetmp = $page;
    do {
        $query = $db->query("SELECT * FROM {$tblprefix}userfiles {$wheresql} ORDER BY ufid DESC LIMIT " . ($pagetmp - 1) * $mrowpp . ",{$mrowpp}");
        $pagetmp--;
    } while (!$db->num_rows($query) && $pagetmp);
    $itemstr = '';
    while ($item = $db->fetch_array($query)) {
        $item['createdate'] = date("{$dateformat}", $item['createdate']);
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:userfiles.inc.php


示例10: tabheader

function tabheader($tname = '', $fname = '', $furl = '', $col = 2, $fupload = 0, $checksubmit = 0, $newwin = 0)
{
    $_mc = defined('M_MCENTER') ? 1 : 0;
    $tablestr = '';
    if ($fname) {
        $tablestr .= form_str($fname, $furl, $fupload, $checksubmit, $newwin);
    }
    if ($_mc) {
        $tablestr .= "<table border=\"0\" cellpadding=\"0\" cellspacing=\"1\" class=\"tabmain\">\n";
        $tablestr .= "<tr class=\"header\"><td colspan=\"{$col}\"><b>{$tname}</b></td></tr>\n";
    } else {
        $tablestr .= "<div class=\"conlist1\">{$tname}</div>";
        $tablestr .= "<table width=\"100%\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" class=\" tb tb2 bdbot\">\n";
    }
    echo $tablestr;
}
开发者ID:polarlight1989,项目名称:08cms,代码行数:16,代码来源:admin.fun.php


示例11: foreach

        $ucidsarr[$k] = $v['title'];
    }
}
if (empty($deal)) {
    $filterstr = '';
    foreach (array('keyword') as $k) {
        isset(${$k}) || (${$k} = '');
        $filterstr .= "&{$k}=" . urlencode(${$k});
    }
    $fromsql = "FROM {$tblprefix}mflinks";
    $wheresql = "WHERE mid='{$memberid}' AND checked='0'";
    if ($keyword) {
        $wheresql .= " AND fromname LIKE '%" . str_replace(array(' ', '*'), '%', addcslashes($keyword, '%_')) . "%'";
    }
    if (!submitcheck('bflinksedit')) {
        echo form_str($action . 'flinksedit', "?action={$action}&page={$page}");
        tabheader_e();
        echo "<tr><td class=\"item2\">";
        echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" style=\"vertical-align: middle;\">&nbsp; ";
        echo strbutton('bfilter', 'filter0') . '</td></tr>';
        tabfooter();
        $pagetmp = $page;
        do {
            $query = $db->query("SELECT * {$fromsql} {$wheresql} ORDER BY cid DESC LIMIT " . ($pagetmp - 1) * $mrowpp . ",{$mrowpp}");
            $pagetmp--;
        } while (!$db->num_rows($query) && $pagetmp);
        $itemstr = '';
        while ($item = $db->fetch_array($query)) {
            $createdatestr = date("{$dateformat}", $item['createdate']);
            $itemstr .= "<tr><td class=\"item\" width=\"30\"><input class=\"checkbox\" type=\"checkbox\" name=\"selectid[{$item['cid']}]\" value=\"{$item['cid']}\"></td>\n" . "<td class=\"item\" width=\"30\">{$item['mid']}</td>\n" . "<td class=\"item2\"><a href=\"{$mspaceurl}index.php?mid={$item['mid']}\" target=\"_blank\">{$item['mname']}</a></td>\n" . "<td class=\"item\" width=\"60\">{$createdatestr}</td>\n" . "<td class=\"item\" width=\"60\"><a href=\"?action=mflink&mid={$item['mid']}&cid={$item['cid']}\">" . lang('look') . "</a> <a href=\"?action={$action}&deal=delete&cid={$item['cid']}\">" . lang('delete') . "</a></td></tr>\n";
        }
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:amflinks.inc.php


示例12: elseif

 } elseif ($u_checked != -1) {
     $wheresql .= " AND cu.checked='{$u_checked}'";
 }
 //搜索关键词处理
 $keyword && ($wheresql .= " AND (cu.mname LIKE '%" . str_replace(array(' ', '*'), '%', addcslashes($keyword, '%_')) . "%' OR a.subject LIKE '%" . str_replace(array(' ', '*'), '%', addcslashes($keyword, '%_')) . "%')");
 $filterstr = '';
 foreach (array('nimuid', 'keyword') as $k) {
     ${$k} && ($filterstr .= "&{$k}=" . rawurlencode(stripslashes(${$k})));
 }
 foreach (array('checked') as $k) {
     ${$k} != -1 && ($filterstr .= "&{$k}=" . ${$k});
 }
 $wheresql = "WHERE " . (empty($no_list) ? $wheresql : '1=0');
 if (!submitcheck('barcsedit')) {
     if (empty($u_tplname)) {
         echo form_str($action . 'arcsedit', "?action=inanswers&aid={$aid}&page={$page}");
         tabheader_e();
         echo "<tr><td colspan=\"2\" class=\"txt txtleft\">";
         echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" size=\"8\" style=\"vertical-align: middle;\">&nbsp; ";
         if (empty($u_filters) || in_array('check', $u_filters)) {
             $checkedarr = array('-1' => lang('nolimit') . lang('adopt'), '0' => lang('noadopt'), '1' => lang('adopted'));
             echo "<select style=\"vertical-align: middle;\" name=\"checked\">" . makeoption($checkedarr, $checked) . "</select>&nbsp; ";
         }
         echo strbutton('bfilter', 'filter0') . '</td></tr>';
         trhidden('nimuid', $nimuid);
         tabfooter();
         //列表区
         tabheader((empty($u_mtitle) ? lang('answerlist') : $u_mtitle) . '&nbsp; -&nbsp; ' . lang('spare') . ':' . $aedit->archive['spare'] . $currencys[$aedit->archive['crid']]['cname'], '', '', 9);
         $cy_arr = array(array(lang('questiontitle'), 'item2'), lang('adopt'), lang('award'), lang('awarded'));
         if (in_array('mname', $u_lists)) {
             $cy_arr[] = lang('member');
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:inanswers.inc.php


示例13: max

 $page = !empty($page) ? max(1, intval($page)) : 1;
 submitcheck('bfilter') && ($page = 1);
 $keyword = empty($keyword) ? '' : $keyword;
 $mcnvar = empty($mcnvar) ? '' : $mcnvar;
 $wheresql = '';
 $fromsql = "FROM {$tblprefix}mcnodes";
 $mcnvar && ($wheresql .= ($wheresql ? ' AND ' : '') . "mcnvar='{$mcnvar}'");
 $keyword && ($wheresql .= ($wheresql ? ' AND ' : '') . "(ename LIKE '%" . str_replace(array(' ', '*'), '%', addcslashes($keyword, '%_')) . "%' OR alias LIKE '%" . str_replace(array(' ', '*'), '%', addcslashes($keyword, '%_')) . "%')");
 $wheresql = $wheresql ? "WHERE {$wheresql}" : '';
 $filterstr = '';
 foreach (array('mcnvar', 'keyword') as $k) {
     $filterstr .= "&{$k}=" . urlencode(${$k});
 }
 if (!submitcheck('bmcnodesedit')) {
     url_nav(lang('mcnodeadmin'), $urlsarr, 'mcnodesedit');
     echo form_str($actionid . 'mcnodesedit', "?entry={$entry}&action={$action}&page={$page}{$param_suffix}");
     tabheader_e();
     echo "<tr><td class=\"txt txtleft\">";
     echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" size=\"8\" style=\"vertical-align: middle;\">&nbsp; ";
     echo "<select style=\"vertical-align: middle;\" name=\"mcnvar\">" . makeoption(array('' => lang('all') . lang('nodetype')) + $mcnvars, $mcnvar) . "</select>&nbsp; ";
     echo strbutton('bfilter', 'filter0');
     echo "</td></tr>";
     tabfooter();
     $addstr = "&nbsp; &nbsp; <input class=\"checkbox\" type=\"checkbox\" name=\"select_all\" value=\"1\">&nbsp;" . lang('selectallpage');
     tabheader(lang('mcnode_list') . $addstr, '', '', 12);
     $cy_arr = array("<input class=\"checkbox\" type=\"checkbox\" name=\"chkall\" onclick=\"checkall(this.form, 'selectid', 'chkall')\">", array(lang('cnode_name'), 'txtL'), array(lang('nodetype') . '-ID', 'txtL'), array(lang('look'), 'txtL'));
     for ($i = 0; $i <= min($mcn_max_addno, 2); $i++) {
         $cy_arr[] = $i ? lang('addp') . $i . lang('template') : lang('index_tpl');
     }
     $cy_arr[] = lang('detail');
     trcategory($cy_arr);
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:mcnodes.inc.php


示例14: showlist

 function showlist()
 {
     global $db, $tblprefix, $curuser, $eid, $atpp, $page, $mid, $mname, $checked, $dmode, $date1, $date2;
     if ($eid) {
         return $this->isadmin ? $this->check() : ($eid == 'new' ? $this->addnew() : $this->show());
     }
     if (!submitcheck('bextedit')) {
         if (defined('M_MCENTER')) {
             $css = array('L' => 'item2', 'R' => 'item right', 'C' => 'item');
             $membercname = lang('membercname');
             $checkstate = lang('checkstate');
         } else {
             $css = array('L' => 'txtL', 'R' => 'txtR', 'C' => 'txtC');
             $membercname = lang('member_cname');
             $checkstate = lang('check_state');
         }
         $page = !empty($page) ? max(1, intval($page)) : 1;
         submitcheck('bfilter') && ($page = 1);
         if ($this->isadmin) {
             $wheresql = ' 1=1';
             $u_lists = array('mname', 'integral', 'total', 'rate', 'checkdate', 'createdate', 'view');
         } else {
             $wheresql = " mid={$curuser->info['mid']}";
             $u_lists = array('integral', 'total', 'rate', 'checkdate', 'createdate', 'view');
         }
         $mname && ($wheresql .= " AND mname LIKE '%" . str_replace(array(' ', '*'), '%', addcslashes($mname, '%_')) . "%'");
         isset($checked) || ($checked = '-1');
         $checked != '-1' && ($wheresql .= ' AND checkdate' . ($checked ? '!' : '') . '=0');
         $datefield = $dmode ? 'checkdate' : 'createdate';
         if ($date1 && preg_match("/\\s*(\\d{4})-(\\d{1,2})-(\\d{1,2})(?:\\s+(\\d{1,2}):(\\d{1,2}):(\\d{1,2}))?\\s*\$/", $date1, $match)) {
             $date = mktime(empty($match[4]) ? 0 : $match[4], empty($match[5]) ? 0 : $match[5], empty($match[6]) ? 0 : $match[6], $match[2], $match[3], $match[1]);
             $date && $date > 0 && ($wheresql .= " AND {$datefield}>='{$date}'");
         }
         if ($date2 && preg_match("/\\s*(\\d{4})-(\\d{1,2})-(\\d{1,2})(?:\\s+(\\d{1,2}):(\\d{1,2}):(\\d{1,2}))?\\s*\$/", $date2, $match)) {
             $date = mktime(empty($match[4]) ? 24 : $match[4], empty($match[5]) ? 59 : $match[5], empty($match[6]) ? 59 : $match[6], $match[2], $match[3], $match[1]);
             $date && $date > 0 && ($wheresql .= " AND {$datefield}<='{$date}'");
         }
         echo form_str('extract_list', "?{$_SERVER['QUERY_STRING']}");
         if ($this->isadmin) {
             //搜索区块
             tabheader_e();
             echo "<tr><td colspan=\"2\" class=\"txt txtleft\">";
             //关键词固定显示
             echo $membercname . "&nbsp; <input class=\"text\" name=\"mname\" type=\"text\" value=\"{$mname}\" size=\"8\" style=\"vertical-align: middle;\">&nbsp; ";
             $checkarr = array('-1' => lang('nolimit'), '0' => lang('nocheck'), '1' => lang('checked'));
             echo "<select style=\"vertical-align: middle;\" name=\"checked\">" . makeoption($checkarr, $checked) . "</select>&nbsp; ";
             $dmodearr = array('0' => lang('needtime'), '1' => lang('checkdate'));
             echo "<select style=\"vertical-align: middle;\" name=\"dmode\">" . makeoption($dmodearr, $dmode) . "</select>&nbsp; " . "<input class=\"text\" id=\"extract_date1\" name=\"date1\" type=\"text\" value=\"{$date1}\" onclick=\"ShowCalendar(this.id);\" style=\"vertical-align: middle;width:120px\">&nbsp; -&nbsp; " . "<input class=\"text\" id=\"extract_date2\" name=\"date2\" type=\"text\" value=\"{$date2}\" onclick=\"ShowCalendar(this.id);\" style=\"vertical-align: middle;width:120px\">&nbsp; " . "<input class=\"btn\" type=\"submit\" name=\"bfilter\" id=\"bfilter\" value=\"" . lang('filter0') . "\">&nbsp;" . "</td></tr>";
             tabfooter();
         }
         $pagetmp = $page;
         do {
             $query = $db->query("SELECT * FROM {$tblprefix}extracts WHERE {$wheresql} ORDER BY {$datefield} DESC LIMIT " . ($pagetmp - 1) * $atpp . ",{$atpp}");
             $pagetmp--;
         } while (!$db->num_rows($query) && $pagetmp);
         $count = $db->result_one("SELECT count(*) FROM {$tblprefix}extracts WHERE {$wheresql}");
         $view = lang('message');
         tabheader(lang('extract_list') . ($this->isadmin ? '' : "&nbsp;[<a href=\"?{$_SERVER['QUERY_STRING']}&eid=new\" onclick=\"return floatwin('open_extractview',this)\">" . lang('submit_extract') . '</a>]'), '', '', count($u_lists) + 1);
         $cy_arr = array();
         $this->isadmin && ($cy_arr[] = '<input class="checkbox" type="checkbox" name="chkall" onclick="checkall(this.form, \'selectid\', \'chkall\')">');
         in_array('mname', $u_lists) && ($cy_arr[] = array($membercname, $css['L']));
         in_array('integral', $u_lists) && ($cy_arr[] = lang('extract_count'));
         in_array('total', $u_lists) && ($cy_arr[] = lang('extract_getcount'));
         in_array('rate', $u_lists) && ($cy_arr[] = lang('extract_discount'));
         in_array('checkdate', $u_lists) && ($cy_arr[] = lang('checkdate'));
         in_array('createdate', $u_lists) && ($cy_arr[] = lang('needtime'));
         #			in_array('delstate',$u_lists) && $cy_arr[] = lang('delstate');
         in_array('view', $u_lists) && ($cy_arr[] = $view);
         trcategory($cy_arr);
         while ($item = $db->fetch_array($query)) {
             #				$checked = $item['checked'] ? 'Y' : '-';
             #				$delete = $item['delstate'] ? 'Y' : '-';
             $checkdate = $item['checkdate'] ? date('Y-m-d', $item['checkdate']) : '-';
             $createdate = date('Y-m-d', $item['createdate']);
             $itemstr = '<tr class="txt">';
             $this->isadmin && ($itemstr .= "<td class=\"{$css['C']} w40\" ><input class=\"checkbox\" type=\"checkbox\" name=\"selectid[{$item['eid']}]\" value=\"{$item['eid']}\"></td>\n");
             in_array('mname', $u_lists) && ($itemstr .= "<td class=\"{$css['L']}\">{$item['mname']}</td>\n");
             in_array('integral', $u_lists) && ($itemstr .= "<td class=\"{$css['C']}\">{$item['integral']}</td>\n");
             in_array('total', $u_lists) && ($itemstr .= "<td class=\"{$css['C']}\">{$item['total']}</td>\n");
             in_array('rate', $u_lists) && ($itemstr .= "<td class=\"{$css['C']}\">{$item['rate']}%</td>\n");
             in_array('checkdate', $u_lists) && ($itemstr .= "<td class=\"{$css['C']}\">{$checkdate}</td>\n");
             in_array('createdate', $u_lists) && ($itemstr .= "<td class=\"{$css['C']}\">{$createdate}</td>\n");
             #				in_array('delstate',$u_lists) && $itemstr .= "<td class=\"$css[C]\">$delete</td>\n";
             in_array('view', $u_lists) && ($itemstr .= "<td class=\"{$css['C']}\"><a href=\"?{$_SERVER['QUERY_STRING']}&eid={$item['eid']}\" onclick=\"return floatwin('open_extractview',this)\">{$view}</a></td>\n");
             $itemstr .= "</tr>\n";
             echo $itemstr;
         }
         tabfooter();
         echo multi($count, $atpp, $page, preg_replace("/[?&]page=\\d+\$|([?&])page=\\d+&/", '$1', "?{$_SERVER['QUERY_STRING']}"));
         if ($this->isadmin) {
             tabheader(lang('operate_item'));
             trbasic(lang('choose_item'), '', '<input class="checkbox" type="checkbox" name="extdeal[delete]" id="extdeal_delete" value="1"><label for="extdeal_delete" >' . lang('delete') . '</label>&nbsp;<input class="checkbox" type="checkbox" name="extdeal[check]" id="extdeal_check" value="1"><label for="extdeal_check" >' . lang('check') . '</label>&nbsp;', '');
             tabfooter('bextedit');
         }
     } elseif ($this->isadmin) {
         global $selectid, $extdeal, $timestamp;
         if (function_exists('mcmessage')) {
             $message = 'mcmessage';
             $empty_item = 'selectoperateitem';
         } else {
//.........这里部分代码省略.........
开发者ID:polarlight1989,项目名称:08cms,代码行数:101,代码来源:extract.cls.php


示例15: isset

 $pmode = isset($pmode) && strlen($pmode) ? $pmode : '*';
 $keyword = empty($keyword) ? '' : $keyword;
 $filterstr = '';
 foreach (array('state', 'pmode', 'keyword') as $k) {
     ${$k} && ($filterstr .= "&{$k}=" . rawurlencode(${$k}));
 }
 $wheresql = "tomid=0 AND delstate!=1";
 $state != '*' && ($wheresql .= " AND state='{$state}'");
 $pmode != '*' && ($wheresql .= " AND paymode='{$pmode}'");
 if ($keyword) {
     $keyword = str_replace(array(' ', '*'), '%', addcslashes($keyword, '%_'));
     $wheresql .= " AND (mname LIKE '%" . $keyword . "%' OR ordersn LIKE '%" . $keyword . "%')";
 }
 if (!submitcheck('barcsedit')) {
     url_nav(lang('goodsorder'), $urlsarr, 'order');
     echo form_str($action . 'arcsedit', "?entry=orders&action=ordersedit&page={$page}");
     tabheader_e();
     echo "<tr><td colspan=\"2\" class=\"txt txtleft\">";
     echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" style=\"vertical-align: middle;width:200px\">&nbsp; ";
     echo "<select style=\"vertical-align: middle;\" name=\"state\">" . makeoption($statearr, $state) . "</select>&nbsp; ";
     echo "<select style=\"vertical-align: middle;\" name=\"pmode\">" . makeoption($pmodearr, $pmode) . "</select>&nbsp; ";
     echo strbutton('bfilter', 'filter0') . '</td></tr>';
     tabfooter();
     $pagetmp = $page;
     do {
         $query = $db->query("SELECT * FROM {$tblprefix}orders WHERE {$wheresql} ORDER BY oid DESC LIMIT " . ($pagetmp - 1) * $atpp . ",{$atpp}");
         $pagetmp--;
     } while (!$db->num_rows($query) && $pagetmp);
     $strorder = '';
     while ($order = $db->fetch_array($query)) {
         $oid = $order['oid'];
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:orders.inc.php


示例16: rawurlencode

     ${$k} && ($filterstr .= "&{$k}=" . rawurlencode(stripslashes(${$k})));
 }
 foreach (array('checked') as $k) {
     ${$k} != -1 && ($filterstr .= "&{$k}=" . ${$k});
 }
 //处理ucotype的筛选
 foreach ($ucotypes as $k => $v) {
     if (!empty(${'uccid' . $k}) && $v['uclass'] == 'comment') {
         $filterstr .= "&uccid{$k}=" . ${'uccid' . $k};
         $wheresql .= " AND cu.uccid{$k}='" . ${'uccid' . $k} . "'";
     }
 }
 $wheresql = "WHERE " . (empty($no_list) ? $wheresql : '1=0');
 if (!submitcheck('barcsedit')) {
     if (empty($u_tplname)) {
         echo form_str($action . 'archivesedit', "?action=comments&nmuid={$nmuid}&page={$page}");
         tabheader_e();
         echo "<tr><td class=\"item2\">";
         echo lang('keyword') . "&nbsp; <input class=\"text\" name=\"keyword\" type=\"text\" value=\"{$keyword}\" size=\"8\" style=\"vertical-align: middle;\">&nbsp; ";
         //审核状态
         if (in_array('check', $u_filters)) {
             $checkedarr = array('-1' => lang('nolimit') . lang('check'), '0' => lang('nocheck'), '1' => lang('checked'));
             echo "<select style=\"vertical-align: middle;\" name=\"checked\">" . makeoption($checkedarr, $checked) . "</select>&nbsp; ";
         }
         //栏目搜索
         if (in_array('catalog', $u_filters)) {
             $caidsarr = array('0' => lang('catalog')) + caidsarr($catalogs);
             echo "<select style=\"vertical-align: middle;\" name=\"caid\">" . makeoption($caidsarr, $caid) . "</select>&nbsp; ";
         }
         foreach ($ucotypes as $k => $v) {
             //报价类系的搜索
开发者ID:polarlight1989,项目名称:08cms,代码行数:31,代码来源:comments.inc.php


示例17: isset

该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP form_submit函数代码示例发布时间:2022-05-15
下一篇:
PHP form_start函数代码示例发布时间:2022-05-15
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap