我想隐藏当放大器轮播的类型为“幻灯片”时显示的“上一个”和“下一个”控件。我还没有找到任何有关如何自定义“控件”属性的文档。
由于我们无法调用外部 css 或引导脚本,如何在 amp 页面中添加模式框?我尝试在 amp 页面中使用 bootstrap,但 amp 验证器失败,因为我们无法在 amp 页面中调用外部 css 脚本!
我的页面cssAMPed超过 50,000 字节。当我在寻找这个问题的解决方案时,我发现了这个页面cssminifier.com但结果并不令我满意(CSS 确实比以前小,网站工作正常,但仍远未达到允许的大小)。
有人知道这个问题还有其他解决方法吗?
我正在构建 amp 网站,并使用了 amp-carousel:
https : //ampbyexample.com/components/amp-carousel/
https://www.ampproject.org/es/docs/reference/components/amp-carousel
我正在使用带有“幻灯片”和“自动播放”选项的轮播作为主页的主要横幅,并且我试图在它推进幻灯片时更改动画速度。
有没有办法设置动画速度或者是否有功能要求?
例子:-
<amp-lightbox id="my-lightbox" layout="nodisplay">
<div class="lightbox" on="tap:my-lightbox.close" role="button" tabindex="0">
<amp-iframe width="350" height="300" layout="fixed" sandbox="allow-scripts allow-same-origin allow-popups" frameborder="0" src="https://ampbyexample.com/"></amp-iframe>
</div>
</amp-lightbox>
<button class="ampstart-btn caps m2" on="tap:my-lightbox" role="button" tabindex="0">Open Iframe in Lightbox</button>
Run Code Online (Sandbox Code Playgroud)
我还尝试从顶部操纵 iFrame 75% 或 600px 的位置,但它也不起作用。
AMP iFrame 包含 Jquery UI 日历,我们希望使用它来获取用户在我们的 AMP 页面中选择的交付日期。
是否可以在 AMP iFrame 中获取和传递值?
据我所知,无法将数据存储在 AMP Page 的本地存储中。
用户个性化设置识别的最佳解决方案是什么?
在使用服务器端解决方案时,例如 amp-list,是否意味着用户必须在某种程度上注册或登录?
是否有一些解决方案如何动态隐藏 div 容器?
这是我目前的实现:
<button class="button" on="tap:player.hide">hide me</button>
<button class=button" on="tap:player.show">show me</button>
<div id="player" class="show" [class]="show||hide">some content</div>
.hide {
display: none;
}
.show {
display: block;
}
Run Code Online (Sandbox Code Playgroud)
只要 div 类在初始调用中具有值“show”,它就可以工作。但我想要的是禁用容器视图,只要没有点击按钮......
我尝试安装和运行amp-paywall-demoAmpProject GitHub 存储库中提供的示例失败:https://github.com/ampproject/samples/tree/master/amp-paywall-demo \n我已经在那里提出了问题票,但没有收到任何回复到目前为止(https://github.com/ampproject/samples/issues/211)
我尝试遵循安装指南:我克隆了存储库(这按预期工作),但npm install不幸的是失败了。
我尝试自己调试该错误,但无法做到这一点。 \n我还用 google 搜索了该错误,并在 Git 存储库中的问题中搜索了类似的问题,但这也没有帮助。
\n\n我使用错误的输出以及 debug.log 文件创建了公共要点
\n\n\n\n调试:https://gist.github.com/rafaelmarques7/707f1932f63cd042cdf1e6952c1093ab
\n\n错误堆栈如下:
\n\n\xe2\x9e\x9c amp-paywall-demo git:(master) \xe2\x9c\x97 sudo npm i\n\n> grpc@0.14.1 install /home/rafael/proj/tuts/amp-publisher-sample/amp-paywall-demo/node_modules/gcl\noud/node_modules/grpc\n> node-pre-gyp install --fallback-to-build\n\nnode-pre-gyp info it worked if it ends with ok\nnode-pre-gyp verb cli [ \'/usr/bin/node\',\nnode-pre-gyp verb cli \'/home/rafael/proj/tuts/amp-publisher-sample/amp-paywall-demo/node_modules/\ngcloud/node_modules/grpc/node_modules/.bin/node-pre-gyp\',\nnode-pre-gyp verb cli \'install\',\nnode-pre-gyp verb cli \'--fallback-to-build\' ]\nnode-pre-gyp info using node-pre-gyp@0.6.28\nnode-pre-gyp info using node@10.15.1 | linux | …Run Code Online (Sandbox Code Playgroud) 我正在尝试使某些 AMP 页面无效。我阅读了文档和一些 GitHub 问题,我知道的越多,我理解的就越少。;)
我猜我的公钥从未被抓取过。
通过 https://developers.google.com/amp/cache/update-cache#update-rsa-keys
如果您想更新您的 RSA 密钥,您可以通过 AMP Cache 链接访问 RSA 密钥,Google 可能会在几个小时内抓取您的新 RSA 密钥。这是 AMP 缓存链接:
https://example-com .< cache.updateCacheApiDomainSuffix >/r/s/example.com/.well-known/amphtml/apikey.pub
所以根据这个我的 URL 是:https : //www-bronchicum-de.cdn.ampproject.org/r/s/www.bronchicum.de/.well-known/amphtml/apikey.pub 密钥位于:https://www.bronchicum.de/.well-known/amphtml/apikey.pub(通过纯文本/文本公开提供)
不幸的是,我只得到:
- 那是一个错误。
在此服务器上找不到请求的 URL /r/s/www.bronchicum.de/.well-known/amphtml/apikey.pub。我们知道的就这些。
当我尝试使缓存无效(使用digitalbrands/amp-cache)或自己编写的 bash 脚本时,我得到以下信息:
- 那是一个错误。
您的客户端无权从该服务器获取网址/update-cache/c/s/www.bronchicum.de/amp?amp_action=flush&_ts=1572261663&_url_signature=BxYM4-ky5wEVmeixpTqMZec3aDhUxcbkT32-kSXufPeO1fGFJ_p7I-xiPKih0oF5AOJy3XnLIvXy_btLXblOALb82BKvHj4UWtiWmtSgV3n-vH5_TVlrDU88UAa_EEZ4sDODwt2Auo1gREd4tZ_BDdXSbDBU5muCbld8KGiSO7mbQ62wWjWhZeXyo6AXqg7AmgCp5wdlwT1f00miYvALUB0gk7f9uDjTsEGIpEvGEwWQE0MllSiYXZ0XnwW2oGaJh8e3ofx0vx72omy9g5i6szgEgT_QR8hEPV_FTXN6V9n0E9A3drAOdyXGVKmFQHLP-knAI-sqfcrRMH2pNc856A。(客户端IP地址:xxxx)
由于摄取错误导致公钥无效:无效内容这就是我们所知道的。
Soooo...我的公钥有问题吗?
openssl dgst -sha256 -signature signature.bin -verify pulic-key.pem url.txt
Run Code Online (Sandbox Code Playgroud)
说“验证正常”。谁能帮帮我吗?:)
根据amp-video-iframe文档,该poster属性是必需的:https :
//amp.dev/documentation/components/amp-video-iframe/?format=websites
但在官方示例页面:https :
//github.com/ampproject/amphtml/blob/master/examples/amp-video-iframe.html
Google 开发人员使用 aplaceholder代替。检查标签验证源代码,似乎两个用例都是有效的:https :
//github.com/ampproject/amphtml/blob/master/extensions/amp-video-iframe/validator-amp-video-iframe.protoascii# L92
有谁知道占位符用例是允许的还是应该避免的?我找不到有关文档的其他信息