Пример #1
0
    $myText = new HAW_text($arrGWeb['name'] . '欢迎您!');
    $objHaw->add_text($myText);
    include_once 'include/foot.php';
    exit;
}
if (!empty($_GET['mod'])) {
    $strModuleID = strval($_GET['mod']);
    include_once '../' . $strModuleID . '/config/var.inc.php';
    $objWebInit->setDBG($arrGPdoDB);
    $objWebInit->db();
    $arrLink[] = 'mod=' . $strModuleID;
    $_SESSION['wapmod'] = $strModuleID;
}
$strWhere = implode(' AND ', $arrWhere);
$strWhere = 'where ' . $strWhere;
$arrInfoList = $objWebInit->getInfoList($strWhere, '  ORDER BY topflag DESC,submit_date DESC', ($intPage - 1) * $objWebInit->arrGPage['page_size'], $objWebInit->arrGPage['page_size'], 'id,title,clicktimes');
$intRows = $arrInfoList['COUNT_ROWS'];
unset($arrInfoList['COUNT_ROWS']);
//翻页跳转
if (!empty($arrLink)) {
    $strLink = implode('&', $arrLink);
}
$arrListPage = $objWebInit->makeInfoListPage($intRows, $strLink, $link_type = 2);
//print_r($arrListPage);
include_once 'include/title.php';
include_once 'include/head.php';
$myForm = new HAW_form("search.php", HAW_METHOD_POST);
$myInput = new HAW_input('keywords', '', "关键字:");
$myForm->add_input($myInput);
$mySubmit = new HAW_submit("搜索");
$mySubmit->br = 0;
Пример #2
0
    include_once 'include/foot.php';
    exit;
} else {
    $strModuleID = strval($_SESSION['wapmod']);
    include_once '../' . $strModuleID . '/config/var.inc.php';
    $objWebInit->setDBG($arrGPdoDB);
    $objWebInit->db();
    $arrLink[] = 'mod=' . $strModuleID;
}
if ($_SERVER["REQUEST_METHOD"] == "POST") {
    $_SESSION['keywords'] = strval($_POST['keywords']);
}
$arrWhere[] = " title like '%" . $_SESSION['keywords'] . "%'";
$strWhere = implode(' AND ', $arrWhere);
$strWhere = 'where ' . $strWhere;
$arrInfoList = $objWebInit->getInfoList($strWhere, '  ORDER BY topflag DESC,submit_date DESC', ($intPage - 1) * $arrGPage['page_size'], $arrGPage['page_size']);
$intRows = $arrInfoList['COUNT_ROWS'];
unset($arrInfoList['COUNT_ROWS']);
//翻页跳转
if (!empty($arrLink)) {
    $strLink = implode('&', $arrLink);
}
$arrListPage = $objWebInit->makeInfoListPage($intRows, $strLink, $link_type = 2);
//print_r($arrListPage);
include_once 'include/title.php';
include_once 'include/head.php';
$intRowNum = ($intPage - 1) * $arrGPage['page_size'] + 1;
foreach ($arrInfoList as $k => $v) {
    $v['title'] = check::csubstr($v['title'], 0, $arrMHaw['list_charnum']);
    $myText = new HAW_text($intRowNum . ":");
    $myText->br = 0;