本文整理汇总了PHP中GetIndexKey函数的典型用法代码示例。如果您正苦于以下问题:PHP GetIndexKey函数的具体用法?PHP GetIndexKey怎么用?PHP GetIndexKey使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了GetIndexKey函数的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: GetFieldValueA
}
${$vs[0]} = GetFieldValueA(${$vs[0]}, $vs[1], $arcID);
}
}
$inadd_f .= ',' . $vs[0];
$inadd_v .= " ,'" . ${$vs[0]} . "' ";
}
}
}
//处理图片文档的自定义属性
if ($litpic != '') {
$flag = 'p';
}
$body = HtmlReplace($body, -1);
//生成文档ID
$arcID = GetIndexKey($arcrank, $typeid, $sortrank, $channelid, $senddate, $mid);
if (empty($arcID)) {
ShowMsg("无法获得主键,因此无法进行后续操作!", "-1");
exit;
}
//保存到主表
$inQuery = "INSERT INTO `#@__archives`(id,typeid,sortrank,flag,ismake,channel,arcrank,click,money,title,shorttitle,\r\ncolor,writer,source,litpic,pubdate,senddate,mid,description,keywords)\r\nVALUES ('{$arcID}','{$typeid}','{$sortrank}','{$flag}','{$ismake}','{$channelid}','{$arcrank}','0','{$money}','{$title}','{$shorttitle}',\r\n'{$color}','{$writer}','{$source}','{$litpic}','{$pubdate}','{$senddate}','{$mid}','{$description}','{$keywords}'); ";
if (!$dsql->ExecuteNoneQuery($inQuery)) {
$gerr = $dsql->GetError();
$dsql->ExecuteNoneQuery("Delete From `#@__arctiny` where id='{$arcID}' ");
ShowMsg("把数据保存到数据库主表 `#@__archives` 时出错,请联系管理员。", "javascript:;");
exit;
}
//软件链接列表
$softurl1 = stripslashes($softurl1);
$urls = '';
示例2: cn_substr
$color = cn_substr($color,10);
$writer = cn_substr($writer,30);
$source = cn_substr($source,50);
$description = cn_substr($description,250);
if($keywords!="") $keywords = trim(cn_substr($keywords,60))." ";
//处理上传的缩略图
if(empty($ddisremote)) $ddisremote = 0;
$litpic = GetDDImage('litpic',$picname,$ddisremote);
$adminID = $cuserLogin->getUserID();
$dsql = new DedeSql(false);
$cts = GetChannelTable($dsql,$channelid);
$arcID = GetIndexKey($dsql,$typeid,$channelid);
//加入主档案表
//----------------------------------
$inQuery = "INSERT INTO `{$cts['maintable']}`(
ID,typeid,typeid2,sortrank,iscommend,ismake,channel,
arcrank,click,title,shorttitle,color,writer,source,litpic,
pubdate,senddate,arcatt,adminID,memberID,description,keywords,templet)
VALUES ('$arcID','$typeid','$typeid2','$sortrank','$iscommend','$ismake','$channelid',
'$arcrank','0','$title','$shorttitle','$color','$writer','$source','$litpic',
'$pubdate','$senddate','$arcatt','$adminID','0','$description','$keywords','$templet');";
if(!$dsql->ExecuteNoneQuery($inQuery)){
$gerr = $dsql->GetError();
$dsql->Close();
示例3: time
}
$senddate = time();
$title = cn_substrR($title, $cfg_title_maxlen);
$isremote = empty($isremote) ? 0 : $isremote;
$serviterm = empty($serviterm) ? "" : $serviterm;
if (!TestPurview('a_Check,a_AccCheck,a_MyCheck')) {
$arcrank = -1;
}
$adminid = $cuserLogin->getUserID();
$userip = GetIP();
if (empty($ddisremote)) {
$ddisremote = 0;
}
$litpic = GetDDImage('none', $picname, $ddisremote);
//生成文档ID
$arcID = GetIndexKey($arcrank, $typeid, $senddate, $channelid, $senddate, $adminid);
if (empty($arcID)) {
ShowMsg("无法获得主键,因此无法进行后续操作!", "-1");
exit;
}
//分析处理附加表数据
$inadd_f = '';
$inadd_v = '';
if (!empty($dede_addonfields)) {
$addonfields = explode(';', $dede_addonfields);
$inadd_f = '';
$inadd_v = '';
if (is_array($addonfields)) {
foreach ($addonfields as $v) {
if ($v == '') {
continue;