涉水轻舟的博客 - 网站前端设计集成, 网站营销策划,轻舟工作室博客 – QzStudio Blog

开源建站、网站重构与优化、UED, Open source, SEO, Marketing

激情、梦想、韧性、坚持

BigGace 语言添加方法

March 6th, 2010

BigGace 语言添加方法:
a、进入目录:\system\language
b、拷贝文件夹en,并重新命名为zh
c、拷贝配置文件en.ini,并重新命名为zh.ini
d、修改zh.ini配置文件:

1
2
3
4
5
6
7
8
9
10
11
    name        	= 简体中文
    translation 	= zh
    locale      	= zh
    full        	= zh_CN
    charset     	= UTF-8
    administration 	= true
 
    [translations]
    name_de     = "Chinesisch"
    name_zh     = "简体中文"
    name_en     = "Chinese"

Terry’s Wishes

February 26th, 2010

Meyerweb Reset 改进版

February 8th, 2010

我一直用着的Reset方法是Meyerweb的,不过最近一段时间在公司做项目的时候发现有部分Rules不怎么符合日常的项目习惯,总是要履写。这显得有些麻烦,所幸我就将它一并修改过来,重新发布:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/* meyerweb reset
  Updated by Robin L. 2010-02-08
-----------------------------------------*/
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, font, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td {
  margin: 0;
  padding: 0;
  border: 0;
  outline: 0;
  font-size: 100%;
  vertical-align: baseline;
  background: transparent;
}
ol, ul, li{
  list-style: none;
}
a, img{border:0 none;}
a:hover{text-decoration:undeline;}
input, select, img, button{vertical-align: middle;}
blockquote, q {
  quotes: none;
}
blockquote:before, blockquote:after,
q:before, q:after {
  content: '';
  content: none;
}
/* remember to define focus styles! */
:focus {
  outline: 0;
}
del {text-decoration: line-through;}
/* tables still need 'cellspacing="0"' in the markup */
table {
  border-collapse: collapse;
  border-spacing: 0;
}
.clearfix{clear:both; float:none; height:0; font-size:0; line-height:0;}

Lastest post in UseBB

February 8th, 2010
<?php
header('Content-type: text/html; charset=utf-8');
mysql_connect('localhost', 'root ', '1234 ');
mysql_select_db('usebb');
 
$result = mysql_query("SELECT t.id, t.topic_title, t.count_replies, t.count_views, t.status_locked FROM usebb_topics t WHERE t.forum_id = 1 AND t.status_sticky = 0 ORDER BY t.id DESC LIMIT 5");
 
echo '<ul>';
while ($news = mysql_fetch_array($result)) {
    echo '<li><a href="/UseBB/topic.php?id='.$news['id'].'">';
    echo htmlspecialchars($news['topic_title']).'</a></li>';
}
echo '</ul>';	
?>

Adding a link to the top menu for UseBB

February 8th, 2010

Adding a link to the top menu
- Open templates/default/global.tpl.php in your text editor. If you use another template, replace default with your template name.
- Look for

<div id="topmenu"><ul>

. This is an unordered list.
- Add an item to this list with this format:

<li><a href="{url}">{title}</a></li>

- Replace {url} and {title} with the link URL and title.
- Save the file and verify the changes on your forum.

Adding a forum link to the top menu
The top menu can be extended with a few additional inner links for member list, staff list, RSS feed and statistics.

To add a link, enter any of the following codes in the unordered list (see above).

<li><a href="{link_memberlist}">{l_MemberList}</a></li>
<li><a href="{link_stafflist}">{l_StaffList}</a></li>
<li><a href="{link_rss}">{l_RSSFeed}</a></li>
<li><a href="{link_stats}">{l_Statistics}</a></li>

Adding a link to the link bar below
- Open sources/page_head.php in your text editor.
- Look for $template->add_global_vars(array(.
- Before, add

$link_bar[] = '<a href="{url}">{title}</a>';

- Replace {url} and {title} with the link URL and title.
- Save the file and verify the changes on your forum.

Note
In all cases, content is enclosed in single quotes (‘). If you intend to use single quotes, you will need to escape them by adding a backlash (\’).

via: http://www.usebb.net/community/topic-1092.html

List of HTTP status codes,Http请求响应状态码

February 3rd, 2010

百度面试,被问及服务Http错误代码页,垭口想了下,觉得就404.shtml, 500shtml比较熟悉,其他就基本歇菜了。这个让我很无语。自己在这方面也太不小心了,看来需要总结下:
于是,继续Google了一下,全部知识都有了……

100 Continue
101 Switching Protocols
102 Processing (WebDAV) (RFC 2518)

200 OK
201 Created
202 Accepted
203 Non-Authoritative Information (since HTTP/1.1)
204 No Content
205 Reset Content
206 Partial Content
207 Multi-Status (WebDAV) (RFC 4918)
Read the rest of this entry »