测试一下高亮显示代码插件

function current_time($type, $gmt = 0) {
switch ($type) {
case 'mysql':
if ( $gmt ) $d = gmdate('Y-m-d H:i:s');
else $d = gmdate('Y-m-d H:i:s', (time() + (get_option('gmt_offset') * 3600)));
return $d;
break;
case 'timestamp':
if ( $gmt ) $d = time();
else $d = time() + (get_option('gmt_offset') * 3600);
return $d;
break;
}
}
再来一个
再来一个
再来一个
再来一个
再来一个
再来一个
再来一个
function current_time($type, $gmt = 0) {
switch ($type) {
case 'mysql':
if ( $gmt ) $d = gmdate('Y-m-d H:i:s');
else $d = gmdate('Y-m-d H:i:s', (time() + (get_option('gmt_offset') * 3600)));
return $d;
break;
case 'timestamp':
if ( $gmt ) $d = time();
else $d = time() + (get_option('gmt_offset') * 3600);
return $d;
break;
}
}

随机日志

发表评论

3 Comments.

  1. 嗯.做的不错..

  2. 不错.谢谢了

Leave a Reply



[ Ctrl + Enter ]

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word

CNXCT小组的博客 is Stephen Fry proof thanks to caching by WP Super Cache