本文整理汇总了PHP中DataList::SetSource方法的典型用法代码示例。如果您正苦于以下问题:PHP DataList::SetSource方法的具体用法?PHP DataList::SetSource怎么用?PHP DataList::SetSource使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DataList
的用法示例。
在下文中一共展示了DataList::SetSource方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: trim
}
$wheresql .= " and typeid2=$sectorid2";
}
if($comname != ''){
$wheresql .= " and comname LIKE '%".$comname."%'";
}
$wheresql = trim($wheresql);
if(eregi("^and", $wheresql)) {
$wheresql = substr($wheresql,3);
}
if($wheresql != ''){
$wheresql = 'where '.trim($wheresql);
}
$companys = array();
$query = "select id, comname, regyear, areaid, areaid2, service, typeid1, typeid2, comaddr, website, postid
from #@__member_cominfo $wheresql";
$dlist = new DataList();
$dlist->pageSize = 10;
$dlist->SetParameter("sectorid",$sectorid);
$dlist->SetParameter("sectorid2",$sectorid2);
$dlist->SetParameter("areaid",$areaid);
$dlist->SetParameter("comname",$comname);
$dlist->SetParameter("areaid2",$areaid2);
$dlist->SetSource($query);
include(dirname(__FILE__)."/template/default/search_list.htm");
?>
示例2: DataList
<?php
require_once(dirname(__FILE__)."/config.php");
CheckPurview('co_NewRule');
require_once(dirname(__FILE__)."/../include/pub_datalist.php");
require_once(dirname(__FILE__)."/../include/inc_functions.php");
setcookie("ENV_GOBACK_URL",$dedeNowurl,time()+3600,"/");
$sql = "
Select
aid,rulename,etype,dtime
From #@__co_exrule
order by aid desc
";
$dlist = new DataList();
$dlist->Init();
$dlist->SetSource($sql);
$dlist->SetTemplet(dirname(__FILE__)."/templets/co_export_rule.htm");
$dlist->display();
$dlist->Close();
ClearAllLink();
?>
示例3: IsCheck
<?php
require_once(dirname(__FILE__)."/config.php");
require_once(dirname(__FILE__)."/../include/pub_datalist_dm.php");
setcookie("ENV_GOBACK_URL",$dedeNowurl,time()+3600,"/");
$bgcolor = "";
if(!isset($keyword)) $keyword="";
if(!isset($typeid)) $typeid="0";
function IsCheck($st)
{
if($st==1) return "[已审核]";
else return "<font color='red'>[未审核]</font>";
}
$querystring = "select * from #@__feedback where CONCAT(#@__feedback.msg,#@__feedback.arctitle) like '%$keyword%' order by dtime desc";
$dlist = new DataList();
$dlist->pageSize = 10;
$dlist->Init();
$dlist->SetParameter("typeid",$typeid);
$dlist->SetParameter("keyword",$keyword);
$dlist->SetSource($querystring);
include(dirname(__FILE__)."/templets/feedback_main.htm");
$dlist->Close();
ClearAllLink();
?>