指向AMP文章中其他AMP页面的链接 [英] links to other AMP pages in an AMP article

查看:95
本文介绍了指向AMP文章中其他AMP页面的链接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在一个主题中有几个非AMP页面.我的非AMP页面在文章正文中将具有指向同一主题的其他非AMP页面的链接.页面的AMP版本应该链接到同一主题中的其他AMP页面,还是文章中的所有链接都指向页面的非AMP(规范)版本?

I have several non-AMP pages within a topic. My non-AMP pages will have links within the body of the article to other non-AMP pages in the same topic. Should the AMP versions of the pages link to the other AMP pages in the same topic or should all links in the articles point to the non-AMP (canonical) versions of the pages?

Using the following link formats for the example:  
Non-AMP version: /muffins/blueberry/  
AMP version: /muffins/blueberry/amp/

/muffins/blueberry/具有指向/muffins/strawberry/
的链接 /muffins/blueberry/amp/应该链接到/muffins/strawberry/amp/还是/muffins/strawberry/?

/muffins/blueberry/ has a link to /muffins/strawberry/
Should /muffins/blueberry/amp/ link to /muffins/strawberry/amp/ or to /muffins/strawberry/?

或者换句话说,如果访问者在AMP页面上访问您的网站,您是否继续向他们提供指向该页面其他AMP版本的链接,还是应该尽快将其切换到完整页面?/p>

Or said another way, if a visitor comes to your site on an AMP page, do you continue to offer them links to other AMP versions of your pages or should you switch them over to the full pages as soon as possible?

推荐答案

据我所知,您可以自行决定,因为在文档中没有哪个地方声明我们必须有指向另一个的链接.如果有帮助,我们决定将AMP页面中的所有链接都链接回到规范页面,并且我们的页面在轮播中的显示效果非常好.

As far as I know, it is up to you to decide since no where in the docs does it state that we must have links leading to one or the other. If it helps, we decided to have all links within the AMP page link back to the canonical page and our pages are appearing in the carousel perfectly fine.

如果您查看 AMP HTML规范,则仅说明该链接不能以javascript:开头.

If you look at the AMP HTML Specs, it only states that links cannot begin with javascript:.

这篇关于指向AMP文章中其他AMP页面的链接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆