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


PHP GetDateTimeMk函数代码示例

本文整理汇总了PHP中GetDateTimeMk函数的典型用法代码示例。如果您正苦于以下问题:PHP GetDateTimeMk函数的具体用法?PHP GetDateTimeMk怎么用?PHP GetDateTimeMk使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


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

示例1: GoSearchVir

function GoSearchVir($fdir){
	global $tcc,$scc,$ddfiles,$shortname,$minsize,$maxsize,$crday,$cfg_basedir;
	$dh = dir($fdir);
	while($filename = $dh->read()){
		if($filename=='.'||$filename=='..') continue;
		$truefile = $fdir."/".$filename;
		if(is_dir($truefile)) GoSearchVir($truefile);
		if(!is_file($truefile)) continue;
		$scc++;
		$ftime = filemtime($truefile);
		$fsize = filesize($truefile);
		$ntime = time() - ($crday * 24 * 3600);
		if(eregi("\.".$shortname,$filename) && $ftime > $ntime
		&& ($fsize<$minsize || $fsize>$maxsize))
		{
			$nfsize = number_format($fsize/1024,2).'K';
			if(in_array($filename,$ddfiles)) continue;
			if($fsize<$minsize){
				$fp = fopen($truefile,'r');
				$tstr = fread($fp,$fsize);
				fclose($fp);
				if(!eregi("eval|fopen|unlink|rename",$tstr)) continue;
			}
			$furl = str_replace($cfg_basedir,"",$truefile);
			echo "<li><input type='checkbox' name='vfiles[]' value='$furl' class='np'> <a href='$furl' target='_blank'><u>$furl</u></a> 创建日期:".GetDateTimeMk($ftime)." 大小:{$nfsize} </li>\r\n";
			$tcc++;
		}
	}
	$dh->close();
}
开发者ID:BGCX262,项目名称:zyyhong-svn-to-git,代码行数:30,代码来源:virus_search.php

示例2: ShowMsg

if ($needRank < 0 && $arc->Fields['mid'] != $cfg_ml->M_ID) {
    ShowMsg('文章尚未审核,非作者本人无权查看!', 'javascript:;');
    exit;
}
//设置了权限限制的文章
//arctitle msgtitle moremsg
if ($needMoney > 0 || $needRank > 1) {
    $arctitle = $arc->Fields['title'];
    /*
    $arclink = GetFileUrl($arc->ArcID,$arc->Fields["typeid"],$arc->Fields["senddate"],
                             $arc->Fields["title"],$arc->Fields["ismake"],$arc->Fields["arcrank"]);
    */
    $arclink = $cfg_phpurl . '/view.php?aid=' . $arc->ArcID;
    $arcLinktitle = "<a href=\"{$arclink}\"><u>" . $arctitle . "</u></a>";
    $description = $arc->Fields["description"];
    $pubdate = GetDateTimeMk($arc->Fields["pubdate"]);
    //会员级别不足
    if ($needRank > 1 && $cfg_ml->M_Rank < $needRank && $arc->Fields['mid'] != $cfg_ml->M_ID) {
        $dsql->Execute('me', "SELECT * FROM `#@__arcrank` ");
        while ($row = $dsql->GetObject('me')) {
            $memberTypes[$row->rank] = $row->membername;
        }
        $memberTypes[0] = "游客或没权限会员";
        $msgtitle = "你没有权限浏览文档:{$arctitle} !";
        $moremsg = "这篇文档需要 <font color='red'>" . $memberTypes[$needRank] . "</font> 才能访问,你目前是:<font color='red'>" . $memberTypes[$cfg_ml->M_Rank] . "</font> !";
        include_once DEDETEMPLATE . '/plus/view_msg.htm';
        exit;
    }
    //需要金币的情况
    if ($needMoney > 0 && $arc->Fields['mid'] != $cfg_ml->M_ID) {
        $sql = "SELECT aid,money FROM `#@__member_operation` WHERE buyid='ARCHIVE" . $aid . "' AND mid='" . $cfg_ml->M_ID . "'";
开发者ID:iabing,项目名称:mzzyc,代码行数:31,代码来源:view.php

示例3: DedeSql

	{
		if(!empty(${"voteitem".$i})){
			$j++;
			$voteitems .= "<v:note id=\\'$j\\' count=\\'0\\'>".${"voteitem".$i}."</v:note>\r\n";
		}
	}
	$dsql = new DedeSql(false);
	$inQuery = "
	insert into #@__vote(votename,starttime,endtime,totalcount,ismore,votenote) 
	Values('$votename','$starttime','$endtime','0','$ismore','$voteitems');
	";
	$dsql->SetQuery($inQuery);
	if(!$dsql->ExecuteNoneQuery())
	{
		$dsql->Close();
		ShowMsg("增加投票失败,请检查数据是否非法!","-1");
		exit();
	}
	$dsql->Close();
	ShowMsg("成功增加一组投票!","vote_main.php");
	exit();
}
$startDay = time();
$endDay = AddDay($startDay,30);
$startDay = GetDateTimeMk($startDay);
$endDay = GetDateTimeMk($endDay);

require_once(dirname(__FILE__)."/templets/vote_add.htm");

ClearAllLink();
?>
开发者ID:BGCX262,项目名称:zyyhong-svn-to-git,代码行数:31,代码来源:vote_add.php

示例4: GetFormItemValue

function GetFormItemValue($ctag, $fvalue)
{
    $fieldname = $ctag->GetName();
    $formitem = "\r\n\t\t<table width=\"800\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">\r\n       <tr>\r\n        <td width=\"80\">~name~</td>\r\n        <td width=\"720\">~form~</td>\r\n       </tr>\r\n    </table>\r\n";
    $innertext = trim($ctag->GetInnerText());
    if ($innertext != "") {
        if ($ctag->GetAtt("type") == 'select') {
            $myformItem = '';
            $items = explode(',', $innertext);
            $myformItem = "<select name='{$fieldname}' style='width:150px'>";
            foreach ($items as $v) {
                $v = trim($v);
                if ($v != '') {
                    if ($fvalue == $v) {
                        $myformItem .= "<option value='{$v}' selected>{$v}</option>\r\n";
                    } else {
                        $myformItem .= "<option value='{$v}'>{$v}</option>\r\n";
                    }
                }
            }
            $myformItem .= "</select>\r\n";
            $formitem = str_replace("~name~", $ctag->GetAtt('itemname'), $formitem);
            $formitem = str_replace("~form~", $myformItem, $formitem);
            return $formitem;
        } else {
            if ($ctag->GetAtt("type") == 'radio') {
                $myformItem = '';
                $items = explode(',', $innertext);
                foreach ($items as $v) {
                    $v = trim($v);
                    if ($v != '') {
                        if ($fvalue == $v) {
                            $myformItem .= "<input type='radio' name='{$fieldname}' class='np' value='{$v}' checked>{$v}\r\n";
                        } else {
                            $myformItem .= "<input type='radio' name='{$fieldname}' class='np' value='{$v}'>{$v}\r\n";
                        }
                    }
                }
                $formitem = str_replace("~name~", $ctag->GetAtt('itemname'), $formitem);
                $formitem = str_replace("~form~", $myformItem, $formitem);
                return $formitem;
            } else {
                $formitem = str_replace('~name~', $ctag->GetAtt('itemname'), $formitem);
                $formitem = str_replace('~form~', $innertext, $formitem);
                $formitem = str_replace('@value', $fvalue, $formitem);
                return $formitem;
            }
        }
    }
    //文本数据的特殊处理
    if ($ctag->GetAtt("type") == "textdata") {
        if (is_file($GLOBALS['cfg_basedir'] . $fvalue)) {
            $fp = fopen($GLOBALS['cfg_basedir'] . $fvalue, 'r');
            $okfvalue = "";
            while (!feof($fp)) {
                $okfvalue .= fgets($fp, 1024);
            }
            fclose($fp);
        } else {
            $okfvalue = "";
        }
        $formitem = "<table width=\"800\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td width=\"80\">" . $ctag->GetAtt('itemname') . "</td>\r\n";
        $formitem .= "<td>\r\n" . GetEditor($fieldname, $okfvalue, 350, 'Basic', 'string') . "</td>\r\n";
        $formitem .= "</tr></table>\r\n";
        $formitem .= "<input type='hidden' name='{$fieldname}_file' value='{$fvalue}'>\r\n";
        return $formitem;
    } else {
        if ($ctag->GetAtt("type") == "htmltext") {
            $formitem = "<table width=\"800\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td width=\"80\">" . $ctag->GetAtt('itemname') . "</td>\r\n";
            $formitem .= "<td>\r\n" . GetEditor($fieldname, $fvalue, 350, 'Basic', 'string') . "</td>\r\n";
            $formitem .= "</tr></table>\r\n";
            return $formitem;
        } else {
            if ($ctag->GetAtt("type") == "multitext") {
                $innertext = "<textarea name='{$fieldname}' id='{$fieldname}' style='width:100%;height:80'>{$fvalue}</textarea>\r\n";
                $formitem = str_replace("~name~", $ctag->GetAtt('itemname'), $formitem);
                $formitem = str_replace("~form~", $innertext, $formitem);
                return $formitem;
            } else {
                if ($ctag->GetAtt("type") == "datetime") {
                    $nowtime = GetDateTimeMk($fvalue);
                    $innertext = "<input name=\"{$fieldname}\" value=\"{$nowtime}\" type=\"text\" id=\"{$fieldname}\" style=\"width:200\">";
                    $innertext .= "<input name=\"selPubtime\" type=\"button\" id=\"selkeyword\" value=\"选择\" onClick=\"showCalendar('{$fieldname}', 'Y-m-d H:i:00', '24');\">";
                    $formitem = str_replace("~name~", $ctag->GetAtt('itemname'), $formitem);
                    $formitem = str_replace("~form~", $innertext, $formitem);
                    return $formitem;
                } else {
                    if ($ctag->GetAtt("type") == "img") {
                        $ndtp = new DedeTagParse();
                        $ndtp->LoadSource($fvalue);
                        if (!is_array($ndtp->CTags)) {
                            $ndtp->Clear();
                            $fvalue = "";
                        }
                        $ntag = $ndtp->GetTag("img");
                        $fvalue = trim($ntag->GetInnerText());
                        $innertext = "<input type='text' name='{$fieldname}' value='{$fvalue}' id='{$fieldname}' style='width:300'><input name='" . $fieldname . "_bt' type='button' value='浏览...' onClick=\"SelectImage('form1.{$fieldname}','big')\">\r\n";
                        $formitem = str_replace("~name~", $ctag->GetAtt('itemname'), $formitem);
                        $formitem = str_replace("~form~", $innertext, $formitem);
                        return $formitem;
//.........这里部分代码省略.........
开发者ID:klr2003,项目名称:sourceread,代码行数:101,代码来源:inc_archives_all.php

示例5: GetOneArchive

 // 读取文档信息,判断权限
 //-------------------------
 $arcRow = GetOneArchive($id);
 if ($arcRow['aid'] == '') {
     ShowMsg('无法获取未知文档的信息!', '-1');
     exit;
 }
 extract($arcRow, EXTR_SKIP);
 //处理需要下载权限的软件
 if ($needRank > 0 || $needMoney > 0) {
     require_once DEDEINC . '/memberlogin.class.php';
     $cfg_ml = new MemberLogin();
     $arclink = $arcurl;
     $arctitle = $title;
     $arcLinktitle = "<a href=\"{$arcurl}\"><u>" . $arctitle . "</u></a>";
     $pubdate = GetDateTimeMk($pubdate);
     //会员级别不足
     if ($needRank > 1 && $cfg_ml->M_Rank < $needRank && $mid != $cfg_ml->M_ID) {
         $dsql->Execute('me', "SELECT * FROM `#@__arcrank` ");
         while ($row = $dsql->GetObject('me')) {
             $memberTypes[$row->rank] = $row->membername;
         }
         $memberTypes[0] = "游客 <a href='/member/'  style='color:#50a010;text-decoration:underline'>登录</a>";
         $msgtitle = "你没有权限下载软件:{$arctitle}!";
         $moremsg = "这个软件需要 <font style='color:#F00'>" . $memberTypes[$needRank] . "</font> 才能下载,你目前是:<font style='color:#F00'>" . $memberTypes[$cfg_ml->M_Rank] . "</font> !";
         include_once DEDETEMPLATE . '/plus/view_msg.htm';
         exit;
     }
     //以下为正常情况,自动扣点数
     //如果文章需要金币,检查用户是否浏览过本文档
     if ($needMoney > 0 && $mid != $cfg_ml->M_ID) {
开发者ID:hensonvip,项目名称:ymroad,代码行数:31,代码来源:download.php

示例6: GetDateTimeMk

$s_addr = "深圳";
$s_postcode = 518000;
$s_tel = "0755-83791960";
$r_name = "陈大康";
$r_addr = "深圳";
$r_postcode = 100080;
$r_tel = "010-81234567";
$r_eml = "service@nps.cn";
$m_status = 0;
$m_ocurrency = 1;
$m_id = $cfg_merchant;
$m_orderid = $buyid;
$m_oamount = $price;
$m_url = $cfg_basehost . "/paycenter/nps/pay_back_nps.php";
$m_ocomment = $cfg_ml->M_ID;
$modate = GetDateTimeMk($mtime);
//组织订单信息
$m_info = $m_id . "|" . $m_orderid . "|" . $m_oamount . "|" . $m_ocurrency . "|" . $m_url . "|" . $m_language;
$s_info = $s_name . "|" . $s_addr . "|" . $s_postcode . "|" . $s_tel . "|" . $s_eml;
$r_info = $r_name . "|" . $r_addr . "|" . $r_postcode . "|" . $r_tel . "|" . $r_eml . "|" . $m_ocomment . "|" . $m_status . "|" . $modate;
$OrderInfo = $m_info . "|" . $s_info . "|" . $r_info;
//订单信息先转换成HEX,然后再加密
$OrderInfo = StrToHex($OrderInfo);
$digest = strtoupper(md5($OrderInfo . $cfg_merpassword));
$strRequestUrl = $payment_url . '?OrderMessage=' . $OrderInfo . '&digest=' . $digest . '&M_ID=' . $cfg_merchant;
echo '<html>
<head>
	<title>转到NPS支付页面</title>
</head>
<body onload="document.nps.submit();">
	<form name="nps" action="' . $strRequestUrl . '" method="post">
开发者ID:iabing,项目名称:mzzyc,代码行数:31,代码来源:config_pay_nps.php

示例7: Dedesql

if ($pid == '') {
    //初始状态
    if ($action == 'normal') {
        $csql->SetQuery("select * from #@__saleback where rdh='{$did}'");
    } else {
        $csql->SetQuery("select * from #@__saleback where id<0");
    }
} else {
    if ($action == '' && $did != '') {
        //写入产品记录
        $wsql = new Dedesql(false);
        $writesql = "select * from #@__basic where cp_number='{$pid}'";
        $wsql->Setquery($writesql);
        $wsql->Execute();
        $wrs = $wsql->GetOne();
        $wsql->ExecuteNoneQuery("insert into #@__saleback(productid,number,rdh,dtime,r_text) values('" . $pid . "','" . $num . "','" . $did . "','" . GetDateTimeMk(time()) . "','" . $r_text . "')");
        $wsql->close();
    }
    $csql->SetQuery("select * from #@__saleback where rdh='{$did}'");
}
$csql->Execute();
$rowcount = $csql->GetTotalRow();
if ($rowcount == 0) {
    echo "<tr><td>&nbsp;</td></tr>";
} else {
    echo "<tr class='row_color_head'><td>货号</td><td>名称</td><td>规格</td><td>分类</td><td>单位</td><td>售价</td><td>退回原因<td>退回数量</td><td>删除</tr>";
    while ($row = $csql->GetArray()) {
        $nsql = new dedesql(false);
        $query1 = "select * from #@__basic where cp_number='" . $row['productid'] . "'";
        $nsql->setquery($query1);
        $nsql->execute();
开发者ID:BGCX261,项目名称:zlskytakeorder-svn-to-git,代码行数:31,代码来源:order_sale_back.php

示例8: GetFormItemValue


//.........这里部分代码省略.........
                        }
                        $myformItem .= $fvalue == $v ? "<input type='radio' name='{$fieldname}' class='np' value='{$v}' checked='checked' />{$v}\r\n" : "<input type='radio' name='{$fieldname}' class='np' value='{$v}' />{$v}\r\n";
                    }
                }
                $innertext = $myformItem;
            } else {
                if ($ftype == 'checkbox') {
                    $myformItem = '';
                    $fvalues = explode(',', $fvalue);
                    if (is_array($items)) {
                        foreach ($items as $v) {
                            $v = trim($v);
                            if ($v == '') {
                                continue;
                            }
                            if (in_array($v, $fvalues)) {
                                $myformItem .= "<input type='checkbox' name='{$fieldname}[]' class='np' value='{$v}' checked='checked' />{$v}\r\n";
                            } else {
                                $myformItem .= "<input type='checkbox' name='{$fieldname}[]' class='np' value='{$v}' />{$v}\r\n";
                            }
                        }
                    }
                    $innertext = $myformItem;
                } else {
                    if ($ftype == "textdata") {
                        if (is_file($cfg_basedir . $fvalue)) {
                            $fp = fopen($cfg_basedir . $fvalue, 'r');
                            $okfvalue = '';
                            while (!feof($fp)) {
                                $okfvalue .= fgets($fp, 1024);
                            }
                            fclose($fp);
                        } else {
                            $okfvalue = '';
                        }
                        if ($admintype == 'admin') {
                            $myformItem = GetEditor($fieldname, $okfvalue, 350, 'Basic', 'string') . "\r\n <input type='hidden' name='{$fieldname}_file' value='{$fvalue}' />\r\n ";
                        } else {
                            $myformItem = GetEditor($fieldname, $okfvalue, 350, 'Member', 'string') . "\r\n <input type='hidden' name='{$fieldname}_file' value='{$fvalue}' />\r\n ";
                        }
                        $innertext = $myformItem;
                    } else {
                        if ($ftype == "htmltext") {
                            if ($admintype == 'admin') {
                                $myformItem = GetEditor($fieldname, $fvalue, 350, 'Basic', 'string') . "\r\n ";
                            } else {
                                $myformItem = GetEditor($fieldname, $fvalue, 350, 'Member', 'string') . "\r\n ";
                            }
                            $innertext = $myformItem;
                        } else {
                            if ($ftype == "multitext") {
                                $innertext = "<textarea name='{$fieldname}' id='{$fieldname}' style='width:90%;height:80px'>{$fvalue}</textarea>\r\n";
                            } else {
                                if ($ftype == "datetime") {
                                    $nowtime = GetDateTimeMk($fvalue);
                                    $innertext = "<input name=\"{$fieldname}\" value=\"{$nowtime}\" type=\"text\" id=\"{$fieldname}\" style=\"width:250px\" class=\"intxt\" />";
                                    $innertext .= "   <script language=\"javascript\" type=\"text/javascript\">\r\n                    Calendar.setup({\r\n                        inputField     :    \"{$fieldname}\",\r\n                        ifFormat       :    \"%Y-%m-%d %H:%M\",\r\n                        showsTime      :    true,\r\n                        timeFormat     :    \"24\"\r\n                    });\r\n                 </script>";
                                } else {
                                    if ($ftype == "img") {
                                        $ndtp = new DedeTagParse();
                                        $ndtp->LoadSource($fvalue);
                                        if (!is_array($ndtp->CTags)) {
                                            $ndtp->Clear();
                                            $fvalue = "";
                                        } else {
                                            $ntag = $ndtp->GetTag("img");
                                            $fvalue = trim($ntag->GetInnerText());
                                        }
                                        $innertext = "<input type='text' name='{$fieldname}' value='{$fvalue}' id='{$fieldname}' style='width:300px'  class='text' /> <input name='" . $fieldname . "_bt' class='inputbut' type='button' value='浏览...' onClick=\"SelectImage('form1.{$fieldname}','big')\" />\r\n";
                                    } else {
                                        if ($ftype == "imgfile") {
                                            $innertext = "<input type='text' name='{$fieldname}' value='{$fvalue}' id='{$fieldname}' style='width:300px'  class='text' /> <input name='" . $fieldname . "_bt' class='inputbut' type='button' value='浏览...' onClick=\"SelectImage('form1.{$fieldname}','big')\" />\r\n";
                                        } else {
                                            if ($ftype == "media") {
                                                $innertext = "<input type='text' name='{$fieldname}' value='{$fvalue}' id='{$fieldname}' style='width:300px'  class='text' /> <input name='" . $fieldname . "_bt' class='inputbut' type='button' value='浏览...' onClick=\"SelectMedia('form1.{$fieldname}')\" />\r\n";
                                            } else {
                                                if ($ftype == "addon") {
                                                    $innertext = "<input type='text' name='{$fieldname}' id='{$fieldname}' value='{$fvalue}' style='width:300px'  class='text' /> <input name='" . $fieldname . "_bt' class='inputbut' type='button' value='浏览...' onClick=\"SelectSoft('form1.{$fieldname}')\" />\r\n";
                                                } else {
                                                    if ($ftype == "int" || $ftype == "float") {
                                                        $innertext = "<input type='text' name='{$fieldname}' id='{$fieldname}' style='width:100px'  class='intxt' value='{$fvalue}' /> (填写数值)\r\n";
                                                    } else {
                                                        $innertext = "<input type='text' name='{$fieldname}' id='{$fieldname}' style='width:250px'  class='intxt' value='{$fvalue}' />\r\n";
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
    $formitem = str_replace('~name~', $ctag->GetAtt('itemname'), $formitem);
    $formitem = str_replace('~form~', $innertext, $formitem);
    return $formitem;
}
开发者ID:iabing,项目名称:mzzyc,代码行数:101,代码来源:customfields.func.php

示例9: GetFormItemValue


//.........这里部分代码省略.........
	
  //文本数据的特殊处理
  if($ftype=="textdata")
  {
  	if(is_file($cfg_basedir.$fvalue)){
  	   $fp = fopen($cfg_basedir.$fvalue,'r');
		   $okfvalue = "";
		   while(!feof($fp)){ $okfvalue .= fgets($fp,1024); }
		   fclose($fp);
	  }else{
	  	$okfvalue = '';
	  }
		
		if($admintype=='admin')  $myformItem = GetEditor($fieldname,$okfvalue,350,'Basic','string')."\r\n <input type='hidden' name='{$fieldname}_file' value='{$fvalue}'>\r\n ";
		else $myformItem = GetEditor($fieldname,$okfvalue,350,'Member','string')."\r\n <input type='hidden' name='{$fieldname}_file' value='{$fvalue}'>\r\n ";
		
		$formitem = str_replace("~name~",$ctag->GetAtt('itemname'),$formitem);
		$formitem = str_replace("~form~",$myformItem,$formitem);
		
		return $formitem;
  }  
	else if($ftype=="htmltext")
	{
		if($admintype=='admin')  $myformItem = GetEditor($fieldname,$fvalue,350,'Basic','string')."\r\n ";
		else $myformItem = GetEditor($fieldname,$fvalue,350,'Member','string')."\r\n ";
		
		$formitem = str_replace("~name~",$ctag->GetAtt('itemname'),$formitem);
		$formitem = str_replace("~form~",$myformItem,$formitem);
		
		return $formitem;
	}
	else if($ftype=="multitext")
	{
		$innertext = "<textarea name='$fieldname' id='$fieldname' style='width:100%;height:80px'>$fvalue</textarea>\r\n";
		$formitem = str_replace("~name~",$ctag->GetAtt('itemname'),$formitem);
		$formitem = str_replace("~form~",$innertext,$formitem);
		return $formitem;
	}
	else if($ftype=="datetime")
	{
		$nowtime = GetDateTimeMk($fvalue);
		$innertext = "<input name=\"$fieldname\" value=\"$nowtime\" type=\"text\" id=\"$fieldname\" style=\"width:250px\">";
		$formitem = str_replace("~name~",$ctag->GetAtt('itemname'),$formitem);
		$formitem = str_replace("~form~",$innertext,$formitem);
		return $formitem;
	}
	else if($ftype=="img")
	{
		$ndtp = new DedeTagParse();
    $ndtp->LoadSource($fvalue);
    if(!is_array($ndtp->CTags)){
    	$ndtp->Clear();
    	$fvalue =  "";
    }else
    {
      $ntag = $ndtp->GetTag("img");
      //$fvalue = trim($ntag->GetInnerText());
	  $fvalue = trim($ndtp->InnerText);
    }
		$innertext = "<input type='text' name='$fieldname' value='$fvalue' id='$fieldname' style='width:300px'> <input name='".$fieldname."_bt' class='inputbut' type='button' value='浏览...' onClick=\"SelectImage('form1.$fieldname','big')\">\r\n";
		$formitem = str_replace("~name~",$ctag->GetAtt('itemname'),$formitem);
		$formitem = str_replace("~form~",$innertext,$formitem);
		return $formitem;
	}
	else if($ftype=="imgfile")
	{
		$innertext = "<input type='text' name='$fieldname' value='$fvalue' id='$fieldname' style='width:300px'> <input name='".$fieldname."_bt' class='inputbut' type='button' value='浏览...' onClick=\"SelectImage('form1.$fieldname','big')\">\r\n";
		$formitem = str_replace("~name~",$ctag->GetAtt('itemname'),$formitem);
		$formitem = str_replace("~form~",$innertext,$formitem);
		return $formitem;
	}
	else if($ftype=="media")
	{
		$innertext = "<input type='text' name='$fieldname' value='$fvalue' id='$fieldname' style='width:300px'> <input name='".$fieldname."_bt' class='inputbut' type='button' value='浏览...' onClick=\"SelectMedia('form1.$fieldname')\">\r\n";
		$formitem = str_replace("~name~",$ctag->GetAtt('itemname'),$formitem);
		$formitem = str_replace("~form~",$innertext,$formitem);
		return $formitem;
	}
	else if($ftype=="addon")
	{
		$innertext = "<input type='text' name='$fieldname' id='$fieldname' value='$fvalue' style='width:300px'> <input name='".$fieldname."_bt' class='inputbut' type='button' value='浏览...' onClick=\"SelectSoft('form1.$fieldname')\">\r\n";
		$formitem = str_replace("~name~",$ctag->GetAtt('itemname'),$formitem);
		$formitem = str_replace("~form~",$innertext,$formitem);
		return $formitem;
	}
	else if($ftype=="int"||$ftype=="float")
	{
		$innertext = "<input type='text' name='$fieldname' id='$fieldname' style='width:100px' value='$fvalue'> (填写数值)\r\n";
		$formitem = str_replace("~name~",$ctag->GetAtt('itemname'),$formitem);
		$formitem = str_replace("~form~",$innertext,$formitem);
		return $formitem;
	}
	else
	{
		$innertext = "<input type='text' name='$fieldname' id='$fieldname' style='width:250px' value='$fvalue'>\r\n";
		$formitem = str_replace("~name~",$ctag->GetAtt('itemname'),$formitem);
		$formitem = str_replace("~form~",$innertext,$formitem);
		return $formitem;
	}
}
开发者ID:BGCX262,项目名称:zyyhong-svn-to-git,代码行数:101,代码来源:inc_custom_fields.php

示例10: Dedesql

if ($pid == '') {
    //初始状态
    if ($action == 'normal') {
        $csql->SetQuery("select * from #@__kc where rdh='{$did}'");
    } else {
        $csql->SetQuery("select * from #@__kc where id<0");
    }
} else {
    if ($action == '' && $did != '') {
        //写入产品记录
        $wsql = new Dedesql(false);
        $writesql = "select * from #@__basic where cp_number='{$pid}'";
        $wsql->Setquery($writesql);
        $wsql->Execute();
        $wrs = $wsql->GetOne();
        $wsql->ExecuteNoneQuery("insert into #@__kc(productid,number,labid,rdh,dtime) values('" . $pid . "','" . $num . "','" . $lid . "','" . $did . "','" . GetDateTimeMk(time()) . "')");
        $wsql->close();
    }
    $csql->SetQuery("select * from #@__kc where rdh='{$did}'");
}
$csql->Execute();
$rowcount = $csql->GetTotalRow();
if ($rowcount == 0) {
    echo "<tr><td>&nbsp;</td></tr>";
} else {
    echo "<tr class='row_color_head'><td>货号</td><td>名称</td><td>规格</td><td>分类</td><td>单位</td><td>进价</td><td>供应商<td>入库数量</td><td>删除</tr>";
    while ($row = $csql->GetArray()) {
        $nsql = new dedesql(false);
        $query1 = "select * from #@__basic where cp_number='" . $row['productid'] . "'";
        $nsql->setquery($query1);
        $nsql->execute();
开发者ID:BGCX261,项目名称:zlskytakeorder-svn-to-git,代码行数:31,代码来源:current_order.php

示例11: trim

****************************************************/
if (empty($client)) {
    $client = 'dede';
}
if (empty($clientpwd)) {
    $clientpwd = '';
}
$cfg_task_pwd = trim($cfg_task_pwd);
//验证客户端工具密码
if (!empty($cfg_task_pwd) && $clientpwd != $cfg_task_pwd) {
    echo $client == 'js' ? '' : 'notask';
    exit;
}
//取得当时间的各个值
$ntime = time();
$nformattime = GetDateTimeMk($ntime);
list($ndate, $ntime) = explode(' ', $nformattime);
list($y, $m, $d) = explode('-', $ndate);
list($hh, $mm, $ss) = explode(':', $ntime);
$daylimit = 24 * 3600;
$dsql->Execute('me', 'Select * From `#@__sys_task` where islock=0 order by id asc ');
while ($arr = $dsql->GetArray()) {
    $starttime = $arr['starttime'];
    $endtime = $arr['endtime'];
    //跳过一次性运行,并且已经运行的任务
    if ($arr['lastrun'] > $starttime && $arr['runtype'] == 1) {
        continue;
    }
    //超过了设定的任务结束时间
    if ($endtime != 0 && $endtime < $ntime) {
        continue;
开发者ID:klr2003,项目名称:sourceread,代码行数:31,代码来源:task.php

示例12: str_replace

     <tr>
      <td><strong><strong>&nbsp;销售管理</strong>&nbsp;&nbsp;- <a href="sale.php">新单</a> - <a href="sale.php?action=seek">销售单查询</a></td>
     </tr><form action="sale.php?action=save" method="post" name="form1">
     <tr>
      <td bgcolor="#FFFFFF">
       <table width="100%" border="0" cellspacing="0" cellpadding="0" id="table_border">
    <tr height="30">
    <td class="cellcolor">销售单号:</td>
    <td class="cellcolor">&nbsp;<input type="text" name="r_dh" value="<?php 
        echo $cdh;
        ?>
" readonly class="rtext" size="10">&nbsp;(销售人员:<input type="text" name="r_people" value="<?php 
        echo str_replace($cfg_cookie_encode, '', $_COOKIE['VioomaUserID']);
        ?>
" readonly class="rtext" size="8">创建时间:<input type="text" name="r_date" value="<?php 
        echo GetDateTimeMk(time());
        ?>
"  readonly class="rtext">)</td>
  </tr>
  <tr>
    <td class="cellcolor" width="30%">产品检索信息:<br></td>
    <td>&nbsp;<input type="text" name="seek_text" value="单击选择产品信息" onclick="getinfo()">&nbsp;(快速检索产品信息)
	<input type="hidden" name="seek_number" value=""/>
	</td>
  </tr>
  <tr>
    <td class="cellcolor" width="30%">数量:<br></td>
    <td>&nbsp;<input type="text" name="rk_number" size="5"><input type="text" class="rtext" name="showdw" readonly size="5">
	</td>
  </tr>
  <tr>
开发者ID:BGCX261,项目名称:zlskytakeorder-svn-to-git,代码行数:31,代码来源:sale.php

示例13: require_once

<?php
require_once(dirname(__FILE__)."/config.php");
CheckPurview('member_List');

require_once(dirname(__FILE__)."/../include/pub_datalist_dm.php");

$query = "select * from #@__score2money_logs order by dateline desc";

$dlist = new DataList();
$dlist->Init();
$dlist->pageSize = 20;
$dlist->SetSource($query);
$log = $dlist->GetDataList();
$logs = array();
while($row = $log->GetArray('dm')) {
	$row['dbdateline'] = GetDateTimeMk($row['dateline']);
	$row['dbtype'] = $row['type'] == 'score2money' ? '积分 → 金币' : '金币 → 积分';

	$logs[] = $row;
}
$page = $dlist->GetPageList(7);
require_once(dirname(__FILE__)."/templets/money2score.htm");
ClearAllLink();
?>
开发者ID:BGCX262,项目名称:zyyhong-svn-to-git,代码行数:24,代码来源:money2scores.php

示例14: ParseDMFields

 	function ParseDMFields($pageNo,$ismake=1)
 	{
 		$this->NowPage = $pageNo;
 		$this->Fields['nowpage'] = $this->NowPage;
 		if($this->SplitPageField!="" &&
 		  isset($this->Fields[$this->SplitPageField]))
 		{
 			$this->Fields[$this->SplitPageField] = $this->SplitFields[$pageNo - 1];
 		}
 		//-------------------------
 	  //解析模板
 		//-------------------------
 		if(is_array($this->dtp->CTags))
 		{
 			foreach($this->dtp->CTags as $tagid=>$ctag){
 				 $tagname = $ctag->GetName();
 				 if($tagname=="field")
 				 {
 					  $this->dtp->Assign($tagid,$this->GetField($ctag->GetAtt("name")));
 				 }
 				 else if($tagname=="pagebreak")
 				 {
 			      if($ismake==0)
 			      { $this->dtp->Assign($tagid,$this->GetPagebreakDM($this->TotalPage,$this->NowPage,$this->ArcID)); }
 			      else
 			      { $this->dtp->Assign($tagid,$this->GetPagebreak($this->TotalPage,$this->NowPage,$this->ArcID)); }
 		     }
 		     else if($tagname=='prenext')
 		     {
 		     	  $this->dtp->Assign($tagid,$this->GetPreNext($ctag->GetAtt("get")));
 		     }
 		     else if($ctag->GetName()=="pagetitle")
 		     {
 			      if($ismake==0)
 			      { $this->dtp->Assign($tagid,$this->GetPageTitlesDM($ctag->GetAtt("style"),$pageNo)); }
 			      else
 			      { $this->dtp->Assign($tagid,$this->GetPageTitlesST($ctag->GetAtt("style"),$pageNo)); }
 		     }
 		     else if($ctag->GetName()=="memberinfo")
 		     {
 		     	 $this->dtp->Assign($tagid,$this->GetMemberInfo());
 		     }
 		     else if($ctag->GetName()=="fieldlist")
 		     {
 		     	 $tagidnnertext = trim($ctag->GetInnerText());
 		     	 if($tagidnnertext=="") $tagidnnertext = GetSysTemplets("tag_fieldlist.htm");
 		     	 $dtp2 = new DedeTagParse();
	         $dtp2->SetNameSpace("field","[","]");
 		     	 $dtp2->LoadSource($tagidnnertext);
           $oldSource = $dtp2->SourceString;
           $oldCtags = $dtp2->CTags;
           $res = "";
 		     	 if(is_array($this->ChannelUnit->ChannelFields) && is_array($dtp2->CTags))
 		     	 {
 		     	   foreach($this->ChannelUnit->ChannelFields as $k=>$v)
 		     	   {
 		     	 	   $dtp2->SourceString = $oldSource;
               $dtp2->CTags = $oldCtags;
               $fname = $v['itemname'];
               if($v['type']=="datetime"){
               	 @$this->Fields[$k] = GetDateTimeMk($this->Fields[$k]);
               }
               foreach($dtp2->CTags as $tid=>$ctag){
               	 if($ctag->GetName()=='name') $dtp2->Assign($tid,$fname);
               	 else if($ctag->GetName()=='value') @$dtp2->Assign($tid,$this->Fields[$k]);
               }
               $res .= $dtp2->GetResult();
 		     	   }
 		     	 }
 		     	 $this->dtp->Assign($tagid,$res);

 		     }//end if
 			}//结束模板循环
 		}
 	}
开发者ID:BGCX262,项目名称:zyyhong-svn-to-git,代码行数:75,代码来源:inc_archives_view.php


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