本文整理汇总了PHP中conProjDB函数的典型用法代码示例。如果您正苦于以下问题:PHP conProjDB函数的具体用法?PHP conProjDB怎么用?PHP conProjDB使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了conProjDB函数的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: require_once
<?php
require_once("plib/head.php");
$cgi = getCGI();
$p_id = $cgi[p_id];
if($p_id == "") sys_exit("参数错误");
conProjDB($p_id);
$p_cname = $proj_data[p_cname];
$nav_str .= " > <a href=templist.php?p_id=$p_id >$p_cname</a> > 新建模板";
if($cgi[edit] != "" && $cgi[cname] != "")
{
if($cgi[grade] == "") $cgi[grade] = "3";
if($cgi[showorder] == "") $cgi[showorder] = "0";
$sqlstr = sprintf("insert into temp set cname='%s', grade=%s, showorder=%s, ttype='%s', createdt=now()", mysql_escape_string($cgi[cname]), $cgi[grade], $cgi[showorder], $cgi[ttype]);
$res = mysql_query($sqlstr, $proj_mysql) or sys_exit("系统忙, 请稍候再试。", $sqlstr . ":\n" . mysql_error());
$t_id=mysql_insert_id($proj_mysql);
if($cgi[t_name] == "")
{
$table_name = sprintf("sp_t%d", $t_id);
}
else
{
$table_name = $cgi[t_name];
}
示例2: header
<?php
require_once "plib/config_inc.php";
$html_charset = HTML_CHARSET;
header("Content-type: text/html; charset={$html_charset}");
require_once "plib/head.php";
$cgi = getCGI();
$p_id = $cgi[p_id];
$t_id = $cgi[t_id];
if ($p_id == "" || $t_id == "") {
sys_exit("参数错误");
}
conProjDB($p_id, $t_id);
$i = 0;
foreach ($tempdef_data as $kk => $row) {
if ($row[t_id] != $t_id) {
continue;
}
if ($row[if_into_db] != "y") {
continue;
}
$sel_list .= "<option value=\"{$row['cname']}\">{$row['cname']}</option>";
}
?>
<select name=cond_type>
<option value="and">并且
<option value="or">或者
</select>
示例3: mysql_query
$sqlstr = "select * from pub_queue order by p_id asc, t_id asc, id asc";
$res = mysql_query($sqlstr, $pub_mysql) or exit(mysql_error($pub_mysql) . "\n" . $sqlstr);
$pub_data = array();
while($row = mysql_fetch_array($res))
{
$pub_data[] = $row;
$sqlstr = "delete from pub_queue where id=$row[id]";
$res1 = mysql_query($sqlstr, $pub_mysql) or exit(mysql_error($pub_mysql) . "\n" . $sqlstr);
}
foreach($pub_data as $row)
{
if($p_id != $row[p_id] || $t_id != $row[t_id])
{
conProjDB($row[p_id], $row[t_id]);
}
$id = $row[id];
$p_id = $row[p_id];
$t_id = $row[t_id];
$d_id = $row[d_id];
print "\n\n\n\np_id:$p_id, t_id:$t_id, d_id:$d_id\n";
if($d_id == 0)
{
if( AddDoc($p_id, $t_id) < 0) printf("添加文档失败: %s<br>\n", $error_message);
}
else
{