当前位置: 首页>>代码示例>>PHP>>正文


PHP ListView::SetParameter方法代码示例

本文整理汇总了PHP中ListView::SetParameter方法的典型用法代码示例。如果您正苦于以下问题:PHP ListView::SetParameter方法的具体用法?PHP ListView::SetParameter怎么用?PHP ListView::SetParameter使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ListView的用法示例。


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

示例1: on

    $sql = "select a.* from sline_model_archive a left join sline_allorderlist b on(a.id=b.aid and b.typeid={$typeid} ) {$where} order by b.displayorder asc, a.modtime desc,a.addtime desc ";
}
$destinfo = TongYong::getDestSeoInfo($module_dest_table, $dest_id);
//目的地优化信息;
$seoinfo = TongYong::getSeoInfo($destinfo, $attrid, $typeid);
//组合搜索标题
//下级目的地
$destlist = Helper_Archive::getChildDest($dest_id, $typeid);
$pv = new ListView($typeid);
$pv->pagesize = 16;
//分页条数.
$pv->SetSql($sql);
//seo变量赋值
foreach ($destinfo as $k => $v) {
    $pv->Fields[$k] = $v;
}
foreach ($seoinfo as $k => $v) {
    $pv->Fields[$k] = $v;
}
$pv->Fields['typeid'] = $typeid;
$pv->Fields['modulename'] = $module_name;
$pv->Fields['modulepinyin'] = $module_pinyin;
$pv->SetParameter('destid', $dest_id);
$pv->SetParameter('attrid', $attrid);
$templet = Helper_Archive::getUseTemplet('line_list');
//获取使用模板
$templet = SLINETEMPLATE . "/" . $cfg_df_style . "/tongyong/tongyong_index.htm";
//默认模板
$pv->SetTemplet($templet);
$pv->Display();
exit;
开发者ID:lz1988,项目名称:stourwebcms,代码行数:31,代码来源:index.php

示例2: on

}
$sql = "select a.* from #@__visa a left join #@__allorderlist b on (a.id=b.aid and b.typeid={$typeid} and a.webid=b.webid) where a.ishidden=0 {$where} order by case when b.displayorder is null then 9999 end,b.displayorder asc,a.modtime desc,a.addtime desc";
$seoarr = array();
//seo信息数组
$seoarr['typename'] = GetTypeName($typeid);
$seoarr['pageno'] = !empty($pageno) ? '第' . $pageno . '页-' : "";
$seoarr['seotitle'] = $countryinfo['seotitle'] ? $countryinfo['seotitle'] : $countryinfo['kindname'];
$seoarr['seodescription'] = !empty($countryinfo['description']) ? "<meta name=\"description\" content=\"" . $countryinfo['description'] . "\"/>" : "";
$seoarr['seokeyword'] = !empty($countryinfo['keyword']) ? "<meta name=\"keywords\" content=\"" . $countryinfo['keyword'] . "\"/>" : "";
$seoarr['jieshao'] = $countryinfo['jieshao'];
$seoarr['litpic_guoqi'] = $countryinfo['countrypic'] ? $countryinfo['countrypic'] : getDefaultImage();
$seoarr['bigpic'] = $countryinfo['bigpic'] ? $countryinfo['bigpic'] : '/templets/smore/images/guojia_bg.jpg';
$seoarr['countryname'] = $countryinfo['kindname'];
$pv = new ListView($typeid);
$pv->pagesize = 8;
//分页条数.
$pv->SetSql($sql);
//seo变量赋值
foreach ($seoarr as $k => $v) {
    $pv->Fields[$k] = $v;
}
$pv->SetParameter('countrypy', $countrypy);
$pv->SetParameter('cityid', $cityid);
//模板选择
$templet = Helper_Archive::getUseTemplet('visa_list');
//获取使用模板
$templet = !empty($templet) ? $templet : SLINETEMPLATE . "/" . $cfg_df_style . "/" . "visa/list.htm";
//默认模板
$pv->SetTemplet($templet);
$pv->Display();
exit;
开发者ID:lz1988,项目名称:stourwebcms,代码行数:31,代码来源:country.php

示例3: ListView

$pv = new ListView($typeid);
$pv->pagesize = 40;
//分页条数.
$pv->Fields['tagword'] = $tagwords;
$pv->SetSql($sql);
//seo变量赋值
foreach ($destinfo as $k => $v) {
    $pv->Fields[$k] = $v;
}
foreach ($seoarr as $k => $v) {
    $pv->Fields[$k] = $v;
}
$pv->Fields['searchname'] = empty($pv->Fields['dest_name']) ? $keyword : $pv->Fields['dest_name'];
$pv->Fields['searchname'] = empty($pv->Fields['searchname']) ? '全部' : $pv->Fields['searchname'];
//分页搜索条件
$pv->SetParameter('dest_id', $dest_id);
$pv->SetParameter('priceid', $priceid);
$pv->SetParameter('sorttype', $sorttype);
$pv->SetParameter('keyword', $keyword);
$pv->SetParameter('attrid', $attrid);
//获取上级开启了导航的目的地
getTopNavDest($dest_id);
//模板选择
$templet = Helper_Archive::getUseTemplet('spot_list');
//获取使用模板
$templet = !empty($templet) ? $templet : SLINETEMPLATE . "/" . $cfg_df_style . "/" . "spots/" . "spot_search.htm";
//默认模板
$pv->SetTemplet($templet);
$pv->Display();
exit;
//本页面用到的函数
开发者ID:lz1988,项目名称:stourwebcms,代码行数:31,代码来源:search.php

示例4: getLitPicHtml

$whereor = trim(trim($whereor), 'or');
$wh = !empty($whereor) ? "({$where}) or ({$whereor})" : $where;
$leftnavinfo = getLeftNav($wh, $typeid);
$whereor = empty($whereor) ? $where : $whereor;
/*if($typeid)
{
    //  $wh.='('.$wh.')'." and typeid=$typeid";
    //  $whereor.=" and typeid=$typeid";
    // $where.=" and typeid=$typeid";
}*/
$sql = "select a.* from (select *,case when {$where} then 1 when {$whereor} then 2 end as neworder from #@__search where ({$wh})" . $w . ") a order by neworder";
$pv = new ListView(0);
$pv->pagesize = 25;
//分页条数.
$pv->SetSql($sql);
$pv->SetParameter('typeid', $typeid);
$pv->SetParameter('keyword', $keyword);
$templet = Helper_Archive::getUseTemplet('cloudsearch_index');
//获取首页使用模板
$templet = !empty($templet) ? $templet : SLINETEMPLATE . "/" . $cfg_df_style . "/" . "" . "cloudsearch.htm";
$pv->SetTemplet($templet);
$pv->Display();
exit;
//获取图片html
function getLitPicHtml($row)
{
    $litpic = $row['litpic'];
    $url = getSearchUrl($row);
    if (!empty($litpic)) {
        $litpic = getUploadFileUrl(str_replace('litpic', 'lit240', $litpic));
        $out = '<li class="li_img"><a href="' . $url . '" target="_blank"><img src="' . $litpic . '" width="118" height="90"  /></a></li>';
开发者ID:lz1988,项目名称:stourwebcms,代码行数:31,代码来源:cloudsearch.php

示例5: GetName

if (isset($pageno)) {
    $pageno = intval(preg_replace("/[^\\d]/", '', $pageno));
}
//当前页
if ($tid == '7') {
    $sql = "select * from #@__leave where reply is null and approval='1' order by addtime desc";
} else {
    if ($tid == '8') {
        $sql = "select * from #@__leave where reply is not null and approval='1' order by addtime desc";
    } else {
        $sql = "select * from #@__leave where typeid='{$tid}' and approval='1' order by addtime desc";
    }
}
$pv = new ListView($typeid);
$pv->listGetChannelKeywords($typeid);
//根据栏目类型获取关键词.介绍,栏目名称
$pv->Fields['name'] = GetName($tid);
$pv->pagesize = 30;
//分页条数.
$pv->SetSql($sql);
//注意以下这两句与伪静态规则有关系,不能写反了.
$pv->SetParameter('tid', $tid);
$pv->SetTemplet(SLINETEMPLATE . "/" . $cfg_df_style . "/" . "questions/" . "list.htm");
$pv->Display();
function GetName($typeid)
{
    global $dsql;
    $sql = "select shortname from #@__nav where webid='0' and isopen='1' and typeid='{$typeid}'";
    $row = $dsql->GetOne($sql);
    return $row['shortname'];
}
开发者ID:lz1988,项目名称:stourwebcms,代码行数:31,代码来源:list.php

示例6:

//其他栏目URL
if (empty($dest_id)) {
    $dest_url = $GLOBALS['cfg_basehost'] . '/destination/';
    $hotel_url = $GLOBALS['cfg_basehost'] . '/hotels/';
    $raider_url = $GLOBALS['cfg_basehost'] . '/raiders/';
    $photo_url = $GLOBALS['cfg_basehost'] . '/photos/';
} else {
    $pinyin = Helper_Archive::getDestPinyin($dest_id);
    $pinyin = !empty($pinyin) ? $pinyin : $dest_id;
    $dest_url = $GLOBALS['cfg_basehost'] . '/' . $pinyin . '/';
    $hotel_url = $GLOBALS['cfg_basehost'] . '/hotels/' . $pinyin . '/';
    $raider_url = $GLOBALS['cfg_basehost'] . '/raiders/' . $pinyin . '/';
    $photo_url = $GLOBALS['cfg_basehost'] . '/photos/' . $pinyin . '/';
}
//设置翻页参数(如果使用伪静态,则不能弄反了)
$pv->SetParameter('dest_id', $dest_id);
$pv->SetParameter('param1', 0);
$pv->SetParameter('param2', 0);
$pv->SetParameter('day', $day);
$pv->SetParameter('priceid', $priceid);
$pv->SetParameter('sorttype', $sorttype);
$pv->SetParameter('keyword', $keyword);
$pv->SetParameter('startcity', $startcity);
$pv->SetParameter('attrid', $attrid);
$templet = Helper_Archive::getUseTemplet('line_list');
//获取使用模板
$templet = !empty($templet) ? $templet : SLINETEMPLATE . "/" . $cfg_df_style . "/lines/line_search.htm";
//默认模板
$pv->SetTemplet($templet);
$pv->Display();
exit;
开发者ID:lz1988,项目名称:stourwebcms,代码行数:31,代码来源:search.php

示例7: getSearchUrl

}
$sql = "select a.* from #@__visa a left join #@__allorderlist b on (a.id=b.aid and b.typeid={$typeid} and a.webid=b.webid) where a.ishidden=0 {$where} order by case when b.displayorder is null then 9999 end,b.displayorder asc,a.modtime desc,a.addtime desc";
$seoarr = array();
//seo信息数组
$seoarr['navtitle'] = $seoarr['searchtitle'] = $navtitle . "列表";
$seoarr['typename'] = GetTypeName($typeid);
$seoarr['pageno'] = !empty($pageno) ? '第' . $pageno . '页-' : "";
$pv = new ListView($typeid);
$pv->pagesize = 10;
//分页条数.
$pv->SetSql($sql);
//seo变量赋值
foreach ($seoarr as $k => $v) {
    $pv->Fields[$k] = $v;
}
$pv->SetParameter('countryid', $countryid);
$pv->SetParameter('cityid', $cityid);
$pv->SetParameter('visatypeid', $visatypeid);
$pv->SetParameter('temppara', 0);
//模板选择
$templet = Helper_Archive::getUseTemplet('visa_list');
//获取使用模板
$templet = !empty($templet) ? $templet : SLINETEMPLATE . "/" . $cfg_df_style . "/" . "visa/visa_search.htm";
//默认模板
$pv->SetTemplet($templet);
$pv->Display();
exit;
//搜索Url
function getSearchUrl($val = null, $key = null, $exclude = null, $arr = array('countryid', 'cityid', 'visatypeid'), $url = "/visa/", $table = "")
{
    return Helper_Archive::getUrlStatic($val, $key, $exclude, $arr, $url, $table, 0);
开发者ID:lz1988,项目名称:stourwebcms,代码行数:31,代码来源:search.php

示例8: getDestInfo

}
$destinfo = getDestInfo($typeid, $dest_id);
//目的地优化信息;
$seoarr = Generateinfo();
$seoarr['channelname'] = $channelname;
//栏目名称
//当前页数->title里面使用
$seoarr['pageno'] = !empty($pageno) ? '第' . $pageno . '页-' : "";
//下级目的地
$destlist = Helper_Archive::getChildDest($dest_id, $typeid);
//seo变量赋值
foreach ($seoarr as $k => $v) {
    $pv->Fields[$k] = $v;
}
$jieshao = $destinfo['jieshao'];
$pv->SetParameter('jieshao', $jieshao);
$pv->SetParameter('dest_id', $dest_id);
$pv->SetParameter('startplaceid', $startplaceid);
$pv->SetParameter('carkindid', $carkindid);
$pv->SetParameter('displayorder', $displayorder);
$pv->SetParameter('attrid', $attrid);
getTopNavDest($dest_id);
//模板选择
$templet = Helper_Archive::getUseTemplet('car_list');
//获取使用模板
$templet = !empty($templet) ? $templet : SLINETEMPLATE . "/" . $cfg_df_style . "/" . "cars/" . "car_search.htm";
//默认模板
$pv->SetTemplet($templet);
$pv->Display();
/**
*  生成searchtitle,keyword,description等信息.
开发者ID:lz1988,项目名称:stourwebcms,代码行数:31,代码来源:search.php

示例9: explode

    $pv->Fields['seodescription'] = !empty($destinfo['description']) ? "<meta name=\"description\" content=\"" . $destinfo['description'] . "\"/>" : "";
    $pv->Fields['seotitle'] = !empty($destinfo['seotitle']) ? $destinfo['seotitle'] : $pv->Fields['seotitle'];
}
if (!empty($dest_id)) {
    $where .= " and find_in_set({$dest_id},a.kindlist)";
}
if (!empty($attrid)) {
    $attrid_arr = explode(',', $attrid);
    foreach ($attrid_arr as $k => $v) {
        $where .= " and find_in_set({$v},a.attrid)";
    }
}
$mianbao = getTuanMianBao($dest_id);
$destlist = getTuanChildDest($dest_id);
//获取上级开启了导航的目的地
getTopNavDest($dest_id);
$virtual_arr = $dsql->GetOne("select sum(ifnull(virtualnum,0)) as number from #@__tuan");
$booknum = Helper_Archive::getSellNum(0, 13) + $virtual_arr['number'];
$sql = "select a.* from #@__tuan a left join #@__allorderlist b on (a.id=b.aid and b.typeid={$typeid} and a.webid=b.webid) where {$where} order by ifnull(b.displayorder,9999) asc,a.addtime desc";
$pv->pagesize = 16;
//分页条数.
$pv->SetSql($sql);
$pv->SetParameter('dest_id', $dest_id);
$pv->SetParameter('status', $status);
$pv->SetParameter('attrid', $attrid);
$templet = Helper_Archive::getUseTemplet('tuan_index');
//获取首页使用模板
$templet = !empty($templet) ? $templet : SLINETEMPLATE . "/" . $cfg_df_style . "/" . "tuan/" . "tuan_index.htm";
$pv->SetTemplet($templet);
$pv->Display();
exit;
开发者ID:lz1988,项目名称:stourwebcms,代码行数:31,代码来源:index.php


注:本文中的ListView::SetParameter方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。