<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
<channel>
<title><![CDATA[向东博客 专注WEB应用 构架之美 --- 构架之美，在于尽态极妍 | 应用之美，在于药到病除]]></title> 
<link>http://www.jackxiang.com/index.php</link> 
<description><![CDATA[赢在IT，Playin' with IT,Focus on Killer Application,Marketing Meets Technology.]]></description> 
<language>zh-cn</language> 
<copyright><![CDATA[向东博客 专注WEB应用 构架之美 --- 构架之美，在于尽态极妍 | 应用之美，在于药到病除]]></copyright>
<item>
<link>http://www.jackxiang.com/post//</link>
<title><![CDATA[[实践OK]PHP 获取前一天日期，php获取明天的时间，smarty中date_format函数用法]]></title> 
<author>jack &lt;xdy108@126.com&gt;</author>
<category><![CDATA[WEB2.0]]></category>
<pubDate>Fri, 06 Aug 2010 06:43:34 +0000</pubDate> 
<guid>http://www.jackxiang.com/post//</guid> 
<description>
<![CDATA[ 
	一、php获取前一天的时间<br/><textarea name="code" class="php" rows="15" cols="100">
$prevDay = date(&#039;Y-m-d&#039;, strtotime(&#039;-1 day&#039;));
echo $prevDay;
</textarea><br/>来自：http://www.maitanbang.com/blog/detal/?id=2500<br/><br/><br/>二、PHP返回明天的日期<br/><textarea name="code" class="php" rows="15" cols="100">
function get_tomorrow_date() &#123;
$tomorrow = mktime(0,0,0,date(&quot;m&quot;),date(&quot;d&quot;)+1,date(&quot;Y&quot;));

return date(&quot;Y-m-d&quot;, $tomorrow);

&#125;
</textarea><br/>获取明天的起始时间和结束时间：<br/><textarea name="code" class="php" rows="15" cols="100">
date(&quot;Y-m-d 0：0：0&quot;,strtotime(&quot;+1 day&quot;));
date(&quot;Y-m-d 23：59：59&quot;,strtotime(&quot;+1 day&quot;));
</textarea><br/>来自：https://www.codenong.com/cs106120430/<br/><br/>三、2010-08-06 12:00:55&nbsp;&nbsp; 用smarty只显示 2010-08-06 怎么控制呢？？<br/>在php中使用date函数来格式化时间戳，smarty中可以使用date_format来实现<br/>具体用法：<br/><div class="code">&#123;$timestamp&#124;date_fomat:”%Y-%m-%d %H:%M:%S”&#125;</div><br/>注意：&#124; 两边没有空格<br/>输出形式：2010-07-10 16:30:25<br/><br/>其他用法如下：<br/><br/><div class="code">&#123;$smarty.now&#124;date_format&#125;<br/>&#123;$smarty.now&#124;date_format:”%A, %B %e, %Y”&#125;<br/>&#123;$smarty.now&#124;date_format:”%H:%M:%S”&#125;<br/>&#123;$yesterday&#124;date_format&#125;<br/>&#123;$yesterday&#124;date_format:”%A, %B %e, %Y”&#125;<br/>&#123;$yesterday&#124;date_format:”%H:%M:%S”&#125;</div><br/><br/>链接来源：http://www.yaronspace.cn/blog/index.php/archives/717<br/><br/><br/>date_format[日期格式]<br/><br/>index.php:<br/><br/>$smarty = new Smarty;<br/>$smarty-&gt;assign(&#039;yesterday&#039;, strtotime(&#039;-1 day&#039;));<br/>$smarty-&gt;display(&#039;index.tpl&#039;);<br/><br/>index.tpl:<br/><br/>&#123;$smarty.now&#124;date_format&#125;<br/>&#123;$smarty.now&#124;date_format:&quot;%A, %B %e, %Y&quot;&#125;<br/>&#123;$smarty.now&#124;date_format:&quot;%H:%M:%S&quot;&#125;<br/>&#123;$yesterday&#124;date_format&#125;<br/>&#123;$yesterday&#124;date_format:&quot;%A, %B %e, %Y&quot;&#125;<br/>&#123;$yesterday&#124;date_format:&quot;%H:%M:%S&quot;&#125;<br/><br/>OUTPUT:<br/><br/>Feb 6, 2001<br/>Tuesday, February 6, 2001<br/>14:33:00<br/>Feb 5, 2001<br/>Monday, February 5, 2001<br/>14:33:00<br/><br/>来源：http://hi.baidu.com/cubeking/blog/item/d69cccb7b5916cc237d3ca56.html
]]>
</description>
</item><item>
<link>http://www.jackxiang.com/post//#blogcomment</link>
<title><![CDATA[[评论] [实践OK]PHP 获取前一天日期，php获取明天的时间，smarty中date_format函数用法]]></title> 
<author> &lt;user@domain.com&gt;</author>
<category><![CDATA[评论]]></category>
<pubDate>Thu, 01 Jan 1970 00:00:00 +0000</pubDate> 
<guid>http://www.jackxiang.com/post//#blogcomment</guid> 
<description>
<![CDATA[ 
	
]]>
</description>
</item>
</channel>
</rss>