本博客立志于收集各类儿童教育资料及技术信息,便于本人和广大网友及家长查询检索,无论公司或个人认为本站存在侵权内容均可与本站联系,任何此类反馈信息一经查明属实后,将立即删除!

如何为F2Blog的个性标题添加小日历的方法

1.打开 include/content.inc.php 文件,找到79行左右内容,这段代码
<div class="ContentRight"></div>

在下面加入
<div class="CateIconSP">
<div class="DateYM"><?php echo substr(format_time($settingInfo['currFormatDate'],$fa['postTime']),2,5)?></div>
<div class="DateDay"><?php echo substr(format_time($settingInfo['currFormatDate'],$fa['postTime']),8,2)?>
</div></div>


2.在下面大概4,5行处找到
代码:
<?php echo $strAuthor.":".$author." ".$strLogDate.":".format_time($settingInfo['currFormatDate'],$fa['postTime'])?>

替换为
代码:
<?php echo $strAuthor.":".$author." ".$strLogTime.":".substr(format_time($settingInfo['currFormatDate'],$fa['postTime']),11,5)?>


3.这个$strLogTime 需要打开 /include/language/home/zh_cn.php 添加条目
代码:
$strLogTime = "时间";
再打开 /include/language/home/zh_tw.php 添加条目
代码:
$strLogTime = "時間";
再打开 /include/language/home/en.php 添加条目
代码:
$strLogTime = "PubTime";
三项分别对应简体,繁体,英文。
一个偷懒的方法,可以在上面替换中直接把 $strLogTime 改为 "时间" 或者 "時間"(注意带上两个双引号)

4.打开自己正在使用的skins目录里面的 typography.css 文件,在最后添加
代码:
.CateIconSP {background:url('date-bg.gif'); float:left; width:43px; height:45px; margin:0px 82px -4px 0px;}
.DateYM {text-align:center;font-size:11px;color:#fff; font-family:"Courier New", Courier;}
.DateDay {text-align:center;font-size:16px;color:#999;line-height:30px;font-family:Verdana; font-weight:bold;}


5.另存以下图片为date-bg.gif 到正在使用的skins目录中,这个小日历标题图片你可以自己用photoshop设计,以适合你的blog风格。
attachments/9825189287.gif

评论: 0 | 引用: 0 | 阅读: 333