乌秋博客
梦想在左,生活在右。   

让 TT blog 支持大话表情
今天一起来就有让自己的blog支持的大话表情的想法,于是就动手做起来:

首先修改 inc_function.php 文件,添加如下两个函数:


修改 index.php,找到这行:
1, $body, $s_root_path, $r_root_path, $attach_path.$image_file_path1.$image_file_path2
改为:
1, set_face($body), $s_root_path, $r_root_path, $attach_path.$image_file_path1.$image_file_path2
主页显示

修改 artical_edit.php 找到这行:
set_moreless(nl2brc(set_keyword(attach_image(1, $body, $s_root_path, $r_root_path, $attach_path.$image_file_path1.$image_file_path2), $is_sync)), $no)
改为:
set_moreless(nl2brc(set_keyword(attach_image(1, set_face($body), $s_root_path, $r_root_path, $attach_path.$image_file_path1.$image_file_path2), $is_sync)), $no)
编辑文章预览显示

在网站根目录下建立face文件夹,在下面放置大话的表情图像,命名规则为 1.gif 2.gif ... 分别对应 # 01 # 02 (#号和数字间没有空格,我只是为了过滤表情#25)。

还有回复表情暂时不做,反正也没有人回复#14

(注:# 39 因为和系统的字符有冲突,改为# 69)
posted at 06/10/04 12:13 | 开发手记 - MyTT | 浏览(14) | 引用 | 评论(2)

 Track this back : http://www.koven.org/rserver.php?mode=tb&sl=168
Commented by koven at 06/10/04 16:21 x
测试回复表情#78 // 219.137.160.209

Commented by 111111 at 06/10/11 16:14 x
我是小光!做表情阿!
!!!!!!! // 121.55.9.51

  name   password   homepage
隐藏评论(只有管理员可见)    


      << prev    1  ...  138  139  140  141  142  143  144  145  146  ...  336    next >>