在我的项目中,我使用ckeditor5创建文章。我想在文章中添加Twitter,Instagram帖子,但不能添加。当我创建文章并插入时,例如https://twitter.com/ckeditor/status/1027571541989572612这篇文章,在创建模式下,它看起来是:
但是保存我的文章并单击以查看它后,帖子没有显示。在检查器中,我看到以下代码:
@Override
public boolean onCreateOptionsMenu(Menu menu) {
//inflate menu
getMenuInflater().inflate(R.menu.top_navigation_menu,menu);
MenuItem action_camera_menu_item = menu.findItem(R.id.action_camera);
MenuItem action_gallery = menu.findItem(R.id.action_gallery);
action_camera_menu_item.setVisible(conditionOK);
action_gallery.setVisible(conditionOK);
return true;
}
在文档中,我读到我应该使用Embedly或Iframely服务来显示帖子。我可以不使用这些服务而这样做吗?附言插入youtube视频后,我才能在config中配置此字段:
<figure class="media"><oembed url="https://twitter.com/ckeditor/status/1027571541989572612"></oembed></figure>