语义化的HTML与搜索引擎优化(如何编写纯语义的HTML进行搜索引擎优化)(4)
作者:Joost.De.Valk 来源:W3CGroup 发布时间:2009-12-28 12:42:00
Emphasizing your meaning
强调你要表达的意思
Remember I said earlier that tags should be the emotion of your text? This is where the real emotion comes in: you can provide emphasis to certain words using em or strong. In the old days, people used b and i for that, but these tags are no longer encouraged, since they imply a specific styling, whereas HTML should only describe structure/meaning (all style should be created using CSS, of course.)
还记得我之前说过标签会让你的文字带有情感么?你可以这样:将要强调的字词放在em或strong标签内。在以前,人们常常使用b和i标签来做,但这些标签是不建议使用的,因为,这些标签仅仅是为了实现特别的样式,而HTML要的应该是结构描述和意义(所有的样式应该由CSS来完成。)
Search engines give more weight to any words marked up using any of these four tags. Overusing them can do more harm than good, and actually cause a loss of emphasis, but if treated with care, they can apply an extra dimension to your documents.
搜索引擎会给这四个标签内的文字更高的权重,不过,如果滥用,将弊大于利,而且,反而会影像要强调的内容,但是,如果妥善应用,这会为你的文档增色不少。
A few words on (i)frames
简单讲一下(i)frames
It's quite simple:don't use them.Search engines don't get them,and screenreaders have quite a hard time using them as well.
很简单:别用它们。搜索引擎根本不去抓取它们,而且,屏幕阅读器在读取它们时非常费劲。
Conflicts of interest
利与弊
All of the above rules can be bent a little of course, which is a good thing, as sometimes it's necessary to keep everyone at your organization happy. Say your boss wants a page to have a zappy marketing title you'd rather not have, because it doesn't exactly describe what's on the page, and pushes your most important keyword to the second heading. If you're in a competitive area, it might be wise to make the page look like that for your boss, yet use an h2 for the first heading, and an h1 for the second.
以上这些规则多少会感觉有些别扭,然而,好的东西有时候对维持你们单位成员的幸福非常有必要。比如,你老板希望一个页面能有个吸引人的销售标题,而你宁可不要,因为,它不能完全地描述这个页面上的内容,而且这会将你认为最重要的关键词要放在第二个标题内。但是,如果你们行业竞争激烈,你老板那样做是很明智的,页面上还要用一个h2标签放第一个标题,一个h1标签放第二个。
The same goes for iframes and images. If someone really wants you to put a certain block of content on a specific well-ranking page, but you don't want to risk losing focus, you could of course put that content into an iframe or image, and choose not to provide an alternative.
这种矛盾同样适用于iframes和images.如果有人一定要你在一个排名特别好的页面上插入一些打断的内容而你又不想冒降级的风险,你可以选择将这些内容放在一个iframe里或者一张图片里。
These decisions are up to you in the end - normal semantics should be the basis of your design, and the conflicts should only arise when you're really optimizing your pages.
最终的决定在你,正常的语义学应该基于你的设计,而真正的利益冲突会在你真正对自己的页面进行优化时才出现。
Not so simple semantic HTML - Microformats
不那么简单的语义化HTML - 微格式
Microformats are also semantic HTML, but they are not exactly simple! At the moment, search engines are hardly using microformats in their algorithms, but that might change. The hCard especially (the HTML version of the vCard) has some very easy and obvious uses for search engines, and I suspect that they will start using those within the next couple of years. You can apply intelligent extra semantics within Microformats using the basic set of HTML elements - for example, a good way of marking up your address hCard is by using the address tag as a container!
微格式也是语义化的HTML,但是它们却不那么容易。现在,搜索引擎算法还很难理解微格式,但是,这可能会得到改变。hCard(vCard版本的HTML)有很多简单易用的东西针对搜索引擎,我想它们将在随后的数年里使用它们。你可以使用额外的可增强理解的语义化微格式HTML元素,比如,一种好的标识你的地址的hCard会使用address标签来包含。
Conclusion
总结
By using semantic HTML to mark up your pages, you can create pages that are more accessible, both to people with disabilities, as well as to search engines. Good semantic markup helps search engines to determine what the topic of a page is, and if used together with a good site structure, allows you pushy up your web site rankings!
在你的页面上使用语义化HTML,你可以使得它们更易访问,对那些视力障碍的人们和搜索引擎都有好处。好的语义化HTML可以帮助搜索引擎确定页面的主题,如果你同时有一个好的站点结构,这将使得你的网站排名得到提高。
This article is licensed under a Creative Commons Attribution, Non Commercial - Share Alike 2.5 license.
本文采用的授权是创作共用的“署名-非商业性使用-相同方式共享 2.5 通用许可”。


猜你喜欢
- 密码强度是一个很普遍的功能,比较简单,主要是怎么制定这个强度规则。现在需要升级密码强度的验证,以前的验证比较简单,现在已经不能满足需求了,现
- 上篇更新到pygame实现俄罗斯方块游戏(AI篇2) ,原本应该继续做优化,不过考虑到完成游戏完整性,这张就先把对战做好。一、对战的方块管理
- 本文实例讲述了python中__call__方法的用法,分享给大家供大家参考。具体方法分析如下:Python中的__call__允许程序员创
- 列表降维(python:3.x)之前遇到需要使用列表降维的情况,如:原列表 : [[12,34],[57,86,1],[43,22,7],[
- 门限回归模型(Threshold Regressive Model,简称TR模型或TRM)的基本思想是通过门限变量的控制作用,当给出预报因子
- 今天第一次玩SQL Server 2005,需要配置远程连接。我废话少说,直入主题,总结下我从新手立场在win2003 server环境下去
- 本文实例讲述了Python实现的根据文件名查找数据文件功能。分享给大家供大家参考,具体如下:#-*- coding: UTF-8 -*-im
- 前言本文介绍的是将django项目部署到centos的遇到的一些问题,关于将Django项目部署到CentOs服务器中的步骤可以参考这篇文章
- eval(“1+2”),-> 3 动态判断源代码中的字符串是一种很强大的语
- 前言大家应该经常在朋友圈看到有人发九宫格图片,其实质就是将一张图片切成九份,然后在微信中一起发这九张图即可。说到切图,Python 就可以实
- 方式一import matplotlib.pyplot as pltimport numpy as npfrom scipy.stats i
- 如果您在试图打开一个.MDF数据库文件时,却发现自己没有安装SQL Server数据库,该怎么办呢?这时候,如果恰巧您的机子上装有Visua
- 数据准备student 表CREATE TABLE `student` ( `student_id` varchar(50) N
- SELECT语句具有种类繁多的各类选项,这些选项可以用来控制数据返回的方式。这些选项以子句、关键词和函数的形式存在。 子句是一种修改结果的语
- 要处理文本数据,需要比数字类型的数据更多的清理步骤。为了从文本数据中提取有用和信息,通常需要执行几个预处理和过滤步骤。Pandas 库有许多
- JSON 格式字段是 Mysql 5.7 新加的属性,不够它本质上以字符串性质保存在库中的,刚接触时我只了解 $.xx 查询字段的方法,因为
- @property有什么用呢?表面看来,就是将一个方法用属性的方式来访问.上代码,代码最清晰了.class Circle(object):
- Cookie是一种发送到客户浏览器的文本串句柄,并保存在客户机硬盘上,可以用来在某个Web站点会话之间持久地保持数据。Request和Res
- 思路:利用栈实现代数式中括号有效行的的检验:代码:class mychain(object): #利用链表建立栈,链表为父类 length=