How to embed Facebook posts in AMP page – WordPress




We can embed Facebook posts in AMP in two ways:

1. Using AMP plugin for WordPress

This plugin is developed by ‘Automattic‘, the corporation behind WordPress.com. It provides an easy way to embed Social media posts to WordPress blog that is compatible with both web and AMP version.


To embed a Facebook post in your WordPress article, simply add the URL of the Facebook post in WordPress editor in a new line:
eg:- https://www.facebook.com/ParksCanada/posts/1712989015384373

After publishing the article, you can see that it appears perfect for the web as well as the AMP version.


So many of you are coming to visit for #Canada150! Visit our #HiddenGems to avoid the crowds http://ow.ly/y89d30b3VkB #NationalTourismDay

Posted by Parks Canada on Sunday, May 7, 2017

You can view the AMP version of this article by clicking this link on a mobile device.

2. Without using the plugin

If we are not using the AMP plugin for WordPress, we need to use the amp-facebook component.

1. Include the amp-facebook component: Place this script in the above the closing of the <head> tag.

2. Now we can embed the twitter post by adding the below code to our template file.

 

How to embed Youtube video in AMP page – WordPress




We can embed Youtube video in AMP in two ways:

1. Using AMP plugin for WordPress

This plugin is developed by ‘Automattic‘, the corporation behind WordPress.com. It provides an easy way to embed Social media posts to WordPress blog that is compatible with both web and AMP version.


To embed a Youtube video in your WordPress article, simply add the URL of the Youtube video in WordPress editor in a new line:
eg:- https://www.youtube.com/watch?v=mGENRKrdoGY

After publishing the article, you can see that it appears perfect for the web as well as the AMP version.


You can view the AMP version of this article by clicking this link on a mobile device.

2. Without using the plugin

If we are not using the AMP plugin for WordPress, we need to use the amp-youtube component.

1. Include the amp-youtube component: Place this script in the above the closing of the <head> tag.

2. Now we can embed the twitter post by adding the below code to our template file.

 

How to embed Instagram posts in AMP page – WordPress




We can embed Instagram posts in AMP in two ways:

1. Using AMP plugin for WordPress

This plugin is developed by ‘Automattic‘, the corporation behind WordPress.com. It provides an easy way to embed Social media posts to WordPress blog that is compatible with both web and AMP version.


To embed an Instagram post in your WordPress article, simply add the URL of the Instagram post in WordPress editor in a new line:
eg:- https://www.instagram.com/p/1totVhIFXl/

After publishing the article, you can see that it appears perfect for the web as well as the AMP version.


Schon nett dieses Cornwall.

A post shared by Sebastian Benz (@sebasbenz) on

You can view the AMP version of this article by clicking this link on a mobile device.

2. Without using the plugin

If we are not using the AMP plugin for WordPress, we need to use the amp-instagram component.

1. Include the amp-instagram component: Place this script in the above the closing of the <head> tag.

2. Now we can embed the instagram post by adding the below code to our template file.

 

How to embed Twitter posts in AMP page – WordPress




We can embed Twitter posts in AMP in two ways:

1. Using AMP plugin for WordPress

This plugin is developed by ‘Automattic‘, the corporation behind WordPress.com. It provides an easy way to embed Social media posts to WordPress blog that is compatible with both web and AMP version.


To embed a Twitter post in your WordPress article, simply add the URL of the Twitter post in WordPress editor in a new line:
eg:- https://twitter.com/AMPhtml/status/885634330868850689

After publishing the article, you can see that it appears perfect for the web as well as the AMP version.


You can view the AMP version of this article by clicking this link on a mobile device.

2. Without using the plugin

If we are not using the AMP plugin for WordPress, we need to use the amp-twitter component.

1. Include the amp-twitter component: Place this script in the above the closing of the <head> tag.

2. Now we can embed the twitter post by adding the below code to our template file.