September 30th, 2008
网页设计,让人最头疼的莫过于让页面兼容各大浏览器,准确些是兼容它们“默认”的CSS样式表。这样,“抹掉”这些默认样式表成了首要问题,也就有了CSS样式表重置一说,目前用的最多的,也是自己现在正在用的方法是,添加以下代码:
第一种方式
1
| * {margin:0px; padding:0px;} |
现在众多的设计师发现,这行代码虽然简单,但却让网页解析太慢,呵呵,当然了,自己是业余的,不用太在意。
于是出现了几种CSS重置方法:
第二种方式
NETTUTS上的 Jeffrey Way写了篇文章Weekend Quick Tip: Create Your Own Simple Reset.css File
释出自己用来重置CSS样式表的方法
1
2
3
4
5
6
7
8
9
10
11
| body, html, div, blockquote, img, label, p, h1, h2, h3, h4, h5, h6, pre, ul, ol,
li, dl, dt, dd, form, a, fieldset, input, th, td
{margin: 0; padding: 0; border: 0; outline: none;}
body{line-height: 1;font-size: 88% /* Decide for yourself if you want to include this. */;}
h1, h2, h3, h4, h5, h6{font-size: 100%;padding: .6em 0;margin: 0 15px;}
ul, ol{list-style: none;}
a{color: black;text-decoration: none;}
a:hover
{text-decoration: underline;}
.floatLeft{float: left;padding: .5em .5em .5em 0;}
.floatRight{float: right;padding: .5em 0 .5em .5em;} |
这个方法适用于大多数的网页设计。
Read the rest of this entry »
September 30th, 2008
由于流量猛增,俺又不知道哪里出问题,所以修改了此文件防止盗链:
修改内容:
18
19
20
21
22
23
24
25
26
27
28
29
30
31
| RewriteCond %{HTTP_REFERER} !^http://(.*\.)?pagemod.cn(/.*)?$ [NC]
RewriteCond %{HTTP_REFERER} !^http://(.*\.)?google.com(/.*)?$ [NC]
RewriteCond %{HTTP_REFERER} !^http://(.*\.)?yahoo.com(/.*)?$ [NC]
RewriteCond %{HTTP_REFERER} !^http://(.*\.)?baidu.com(/.*)?$ [NC]
RewriteCond %{HTTP_REFERER} !^http://(.*\.)?feedsky.com(/.*)?$ [NC]
RewriteCond %{HTTP_REFERER} !^http://(.*\.)?zhuaxia.com(/.*)?$ [NC]
RewriteCond %{HTTP_REFERER} !^http://(.*\.)?bloglines.com(/.*)?$
[NC]
RewriteCond %{HTTP_REFERER} !^http://(.*\.)?xianguo.com(/.*)?$ [NC]
RewriteCond %{HTTP_REFERER} !^http://(.*\.)?youdao.com(/.*)?$ [NC]
RewriteCond %{HTTP_REFERER} !^http://(.*\.)?feedburner.com(/.*)?$
[NC]
RewriteRule \.(jpg|gif|png|bmp|jpeg)$ http://name/uploads/
wailian.gif [R=301,L,NC] |
允许本站、google 、baidu、yahoo、feedsky、feedburner、xianguo、zhuaxia
盗链转移到一个外链图片,不知道这个防止盗链的方法如何。。。。
September 28th, 2008

wheat三栏版本

三种风格轻松切换
Tested in
- Firefox 3- Internet Explorer 7- Opera 9.5- Chrome
Validation
- XHTML
- CSS2.1
Widgets ready
The CSS, XHTML and design is released under GPL
这款主题就是Wheat-lite的三栏版,根据天涯行客同学提供的意见修改的。
增加的修改是:
所谓的以上修改,也算是学习的结果,制作模板其实就是乐在其中,虽然zEUS同学一直说这是难看的泥巴颜色,呵呵。