gpt4 book ai didi

html - 在 html 中编码物理地址的最佳方法是什么?

转载 作者:搜寻专家 更新时间:2023-10-31 08:05:17 25 4
gpt4 key购买 nike

在 html 中编码物理地址的最佳方法是什么?以语义化、可访问性和SEO方式

最佳答案

使用微格式 vCard

<div class="vcard">
<span class="fn">Gregory Peck</span>
<a class="org url" href="http://www.commerce.net/">CommerceNet</a>
<div class="adr">
<span class="type">Work</span>:
<div class="street-address">169 University Avenue</div>
<span class="locality">Palo Alto</span>,
<abbr class="region" title="California">CA</abbr>
<span class="postal-code">94301</span>
<div class="country-name">USA</div>
</div>
<div class="tel">
<span class="type">Work</span> +1-650-289-4040
</div>
<div class="tel">
<span class="type">Fax</span> +1-650-289-4041
</div>
<div>Email:
<span class="email">info@commerce.net</span>
</div>
</div>

无障碍:√
语义:我猜..
搜索引擎优化:√ Google announces support for microformats

更多例子在 http://microformats.org/wiki/hcard-examples
另请查看 Oomph Microformats toolkit这有助于您显示和使用微格式。

关于html - 在 html 中编码物理地址的最佳方法是什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1886923/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com