Exemplo n.º 1
0
';
$sql = 'select * from ve123_stat_visitor ';
$result = $db->query($sql);
$total = $db->num_rows($result);
$pagesize = 30;
$totalpage = ceil($total / $pagesize);
$page = intval($_GET['page']);
if ($page <= 0) {
    $page = 1;
}
$offset = ($page - 1) * $pagesize;
$result = $db->query($sql . " order by v_id desc limit {$offset},{$pagesize}");
while ($row = $db->fetch_array($result)) {
    echo '  <tr>
    <td>&nbsp;</td>
    <td>';
    echo $row['v_ip'];
    echo '</td>
    <td>';
    echo $row['v_time'];
    echo '</td>
    <td>';
    echo $row['http_referer'];
    echo '</td>
  </tr>
    ';
}
echo '</table>
';
echo pageshow($page, $totalpage, $total, '?');
Exemplo n.º 2
0
    ?>
">详细选项</a>
	--  <a href="?action=del&site_id=<?php 
    echo $row["site_id"];
    ?>
" onclick="if(!confirm('确认删除码?')) return false;"><span class="RED">删除</span></a>
	</td>
  </tr>
  <?php 
}
?>
</table>
 <table width="98%" border="1" align="center" cellpadding="5" cellspacing="0" bordercolordark="#FFFFFF" bordercolor="888888">
 <tr><td>
<?php 
echo pageshow($page, $totalpage, $total, "?");
?>
</td></tr></table>
<?php 
function addform($do_action)
{
    global $db;
    if ($do_action == "modify") {
        $site_id = intval($_GET["site_id"]);
        $sql = "select * from ve123_sites where site_id='{$site_id}'";
        $row = $db->get_one($sql);
        $url = $row["url"];
        $qp = $row["qp"];
        $fpr = $row["fpr"];
        $spider_depth = $row["spider_depth"];
        $pagestart = $row["pagestart"];
Exemplo n.º 3
0
    echo '" onclick="if(!confirm(\'确认删除吗?\')) return false;">删除</a>	</td>
  </tr>
  ';
}
echo '
  <tr>
    <th colspan="7">
<div align="center"> 
                全选<input name="chkall" type="checkbox" id="chkall" onclick="CheckAll(this.form,\'kid[]\')" value="checkbox">&nbsp;&nbsp;<strong>操作</strong><input name="do_action" type="radio" value="del" checked="checked">删除&nbsp;&nbsp; 
                <input type="button" name="Submit" value=" 执 行 " onclick="getCheckedvalue(this.form)">
        </div>	</th>
    </tr></form>

</table>
';
echo pageshow($page, $totalpage, $total, '?action=' . $action . '&kw=' . $kw . '&');
echo '';
function addform($do_action)
{
    global $db;
    if ($do_action == 'modify') {
        $kid = $_GET['kid'];
        $sql = "select * from ve123_search_keyword where kid='{$kid}'";
        $rs = $db->get_one($sql);
        $keyword = $rs['keyword'];
        $ip = $rs['ip'];
        $btn_txt = '确定修改';
    } else {
        $btn_txt = '确定提交';
    }
    echo '<table width="100%" border="0" cellpadding="3" cellspacing="1" class="tablebg">
Exemplo n.º 4
0
}
?>
  <tr>
    <th colspan="7">
<div align="center"> 
                <input name="chkall" type="checkbox" id="chkall" onclick=CheckAll(this.form,'link_id[]') value="checkbox">
                选中本页显示的信息 <strong>操作:</strong> 
                
				<input name="do_action" type="radio" value="del" checked="checked">
                删除&nbsp;&nbsp;&nbsp;&nbsp; 
                <input type="submit" name="Submit" value=" 执 行 ">
        </div>	</th>
    </tr></form>
</table>
<?php 
echo pageshow($page, $totalpage, $total, "?title=" . $title . "&url=" . $url . "&action=" . $action . "&");
function addform($do_action)
{
    global $db;
    if ($do_action == "modify") {
        $link_id = intval($_GET["link_id"]);
        $row = $db->get_one("select * from ve123_links where link_id='{$link_id}'");
        $title = $row["title"];
        $url = $row["url"];
        $qp = $row["qp"];
        $bt_txt = "确定修改";
    } else {
        $bt_txt = "确定添加";
    }
    ?>
<table width="98%" border="1" align="center" cellpadding="5" cellspacing="0" bordercolordark="#FFFFFF" bordercolor="888888">
Exemplo n.º 5
0
  ';
}
echo '  <tr>
    <th colspan="6">
<div align="center"> 
                <input name="chkall" type="checkbox" id="chkall" onclick=CheckAll(this.form,\'link_id[]\') value="checkbox">
                选中本页显示的信息 <strong>操作:</strong> 
                
				<input name="do_action" type="radio" value="del" checked="checked">
                删除&nbsp;&nbsp;&nbsp;&nbsp; 
                <input type="submit" name="Submit" value=" 执 行 ">
        </div>	</th>
    </tr></form>
</table>
';
echo pageshow($page, $totalpage, $total, '?title=' . $title . '&url=' . $url . '&action=' . $action . '&');
echo '';
function addform($do_action)
{
    global $db;
    if ($do_action == 'modify') {
        $link_id = intval($_GET['link_id']);
        $row = $db->get_one("select * from ve123_links where link_id='{$link_id}'");
        $title = $row['title'];
        $url = $row['url'];
        $tuiguang = $row['tuiguang'];
        $bt_txt = '确定修改';
    } else {
        $bt_txt = '确定添加';
    }
    echo '<table width="100%" border="0" cellpadding="3" cellspacing="1" class="tablebg">
Exemplo n.º 6
0
        } else {
            $from = $array3[$xn_d_from][$key];
        }
        $valarr = array($id, $name, $typename, $from, $time, $chk, $nameencode);
        for ($i = 0; $i < count($colarr); $i++) {
            $n = $colarr[$i];
            $v = $valarr[$i];
            $plt->set_var($n, $v);
        }
        $plt->parse('rows_' . $rn, 'list_' . $rn, true);
    }
    unset($array3);
    unset($colarr);
    unset($valarr);
    $pgurl = '?m=collect-list-pg-{pg}-xt-' . $xt . '-group-' . $group . '-flag-' . $flag . '-type-' . $type . '-wd-' . urlencode($wd) . '-apiurl-' . $apiurl;
    $pgs = '共' . $recordcount . '条数据&nbsp;当前:' . $pg . '/' . $pgcount . '页&nbsp;' . pageshow($pg, $pgcount, 5, $pgurl, 'pagego(\'' . $pgurl . '\',' . $pgcount . ')');
    $plt->set_var('pages', $pgs);
} elseif ($method == 'cj') {
    headAdmin2('数据采集');
    switch ($ac2) {
        case 'sel':
            $ids = be("arr", "ids");
            if (empty($ids)) {
                errMsg("采集提示", "请选择采集数据");
            }
            switch ($xt) {
                case '0':
                    $url = "?action=cjsel&ids=" . $ids;
                    break;
                case '1':
                    $url = "?ac=videolist&rid=" . $group . "&ids=" . $ids;
Exemplo n.º 7
0
 function pageshow($ps = '', $pl = '')
 {
     $labelRule = buildregx("{maccms:pages([\\s\\S]*?)}", "");
     preg_match_all($labelRule, $this->H, $matches1);
     for ($i = 0; $i < count($matches1[0]); $i++) {
         $markstr = $matches1[0][$i];
         $labelRule = buildregx("([a-z0-9]+)=([a-z0-9|,]+)", "");
         preg_match_all($labelRule, $markstr, $matches2);
         for ($j = 0; $j < count($matches2[0]); $j++) {
             switch ($matches2[1][$j]) {
                 case "len":
                     $pagenum = intval($matches2[2][$j]);
                     break;
                 case "linktype":
                     $this->P['pagetype'] = $matches2[2][$j];
                     break;
             }
         }
         unset($matches2);
     }
     unset($matches1);
     if ($this->P['pagesize'] == 0) {
         $this->P['pagesize'] = 1;
     }
     $this->P['pagecount'] = ceil($this->P['datacount'] / $this->P['pagesize']);
     if ($this->P['pagecount'] < 1) {
         $this->P['pagecount'] = 1;
     }
     if (!empty($pl)) {
         $pageurl = $pl;
     } else {
         if ($this->P['pagetype'] == 'list' || $this->P['pagetype'] == 'search' || $this->P['pagetype'] == 'index') {
             $pageurl = $this->getLink($this->P['pageflag'], $this->P['pagetype'], $this->T, array('pg' => '{pg}'), '{pg}');
         } else {
             $pageurl = $this->getLink($this->P['pageflag'], $this->P['pagetype'], $this->T, $this->D, '{pg}');
         }
     }
     $pages = '共' . $this->P['datacount'] . '条数据&nbsp;当前:' . $this->P['pg'] . '/' . $this->P['pagecount'] . '页&nbsp;';
     if (empty($ps)) {
         $pagego = 'pagego(\'' . $pageurl . '\',' . $this->P['pagecount'] . ')';
     } else {
         $tmpurl = str_replace('{url}', $pageurl, $ps);
         $pageurl = 'javascript:void(0)" onclick="' . $tmpurl . '';
         $pagego = $tmpurl;
     }
     $pages .= pageshow($this->P['pg'], $this->P['pagecount'], $pagenum, $pageurl, $pagego, $pl);
     $this->H = str_replace(array($markstr, '{page:now}', '{page:datacount}', '{page:size}', '{page:count}'), array($pages, $this->P['pg'], $this->P['datacount'], $this->P['pagesize'], $this->P['pagecount']), $this->H);
 }
Exemplo n.º 8
0
    <td>
	<a href="?action=modify&amp;kid=<?php 
    echo $rs["kid"];
    ?>
">修改</a>
	<a href="?action=del&kid=<?php 
    echo $rs["kid"];
    ?>
" onclick="if(!confirm('确认删除码?')) return false;">删除</a>	</td>
  </tr>
  <?php 
}
?>
</table>
<?php 
echo pageshow($page, $totalpage, $total, "?action=" . $action . "&kw=" . $kw . "&");
function addform($do_action)
{
    global $db;
    if ($do_action == "modify") {
        $kid = $_GET["kid"];
        $sql = "select * from ve123_search_keyword where kid='{$kid}'";
        $rs = $db->get_one($sql);
        $keyword = $rs["keyword"];
        $ip = $rs["ip"];
        $btn_txt = "确定修改";
    } else {
        $btn_txt = "确定提交";
    }
    ?>
<table width="100%" border="0" cellpadding="3" cellspacing="1" class="tablebg">
Exemplo n.º 9
0
Arquivo: art.php Projeto: klarclm/sgv
            $plt->set_var($n, $v);
        }
        $plt->parse('rows_' . $rn, 'list_' . $rn, true);
        if ($GLOBALS['MAC']['view']['artdetail'] == 2 && $row['a_maketime'] < $row['a_time']) {
            $plt->set_if('rows_' . $rn, 'ismake', true);
        } else {
            $plt->set_if('rows_' . $rn, 'ismake', false);
        }
    }
    unset($rs);
    unset($colarr);
    unset($valarr);
    unset($topicarr);
    unset($typearr);
    $pageurl = '?m=art-list-type-' . $type . '-topic-' . $topic . '-level-' . $level . '-hide-' . $hide . '-lock-' . $lock . '-by-' . $by . '-pg-{pg}-wd-' . urlencode($wd) . '-repeat-' . $repeat . '-repeatlen-' . $repeatlen;
    $pages = '共' . $nums . '条数据&nbsp;当前:' . $page . '/' . $pagecount . '页&nbsp;' . pageshow($page, $pagecount, 3, $pageurl, 'pagego(\'' . $pageurl . '\',' . $pagecount . ')');
    $plt->set_var('pages', $pages);
} elseif ($method == 'info') {
    $plt->set_file('main', $ac . '_' . $method . '.html');
    $id = $p['id'];
    $flag = empty($id) ? 'add' : 'edit';
    $backurl = getReferer();
    $colarr = $col_art;
    array_push($colarr, 'flag', 'backurl');
    if ($flag == 'edit') {
        $row = $db->getRow('select * from {pre}art where a_id=' . $id);
        if ($row) {
            $valarr = array();
            for ($i = 0; $i < count($colarr); $i++) {
                $n = $colarr[$i];
                $valarr[$n] = $row[$n];