AMP for WP – Accelerated Mobile Pages - Version 1.0.69

Version Description

(25th November 2020) = * Fixed: Wrong tooltip link in the infinite scroll #4823 * Fixed: Images are not showing in the AMP due to SG Optimizer lazy load #4815 * Fixed: Embeds not working in AMP Takeover mode #4819 * Fixed: AMPHTML appearing in archive page of Google web stories #4820 * Fixed: AMP option panel page is blank with ECPay Payment for WooCommerce plugin #4816 * Fixed: 404 errors on pagination urls #4373 * Fixed: Blank lines not appearing between paragraphs #4818 * Fixed: amp-story-player preload is being added when not using #4828

Download this release

Release Info

Developer mohammed_kaludi
Plugin Icon 128x128 AMP for WP – Accelerated Mobile Pages
Version 1.0.69
Comparing to
See all releases

Code changes from version 1.0.68.1 to 1.0.69

README.md CHANGED
@@ -3,8 +3,8 @@ Contributors: mohammed_kaludi, ahmedkaludi, ampforwp
3
  Tags: AMP, accelerated mobile pages, mobile, amp project, google amp, amp wp, google, plugin, SEO
4
  Donate link: https://www.paypal.me/Kaludi/25
5
  Requires at least: 3.0
6
- Tested up to: 5.5
7
- Stable tag: 1.0.68.1
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -193,6 +193,16 @@ Device testing done through [BrowserStack](https://www.browserstack.com)
193
 
194
  == Changelog ==
195
 
 
 
 
 
 
 
 
 
 
 
196
  = 1.0.68.1 (10th November 2020) =
197
  * Fixed: Missing amphtml on product pages #4822
198
  * Fixed: Debug warnings #4821
3
  Tags: AMP, accelerated mobile pages, mobile, amp project, google amp, amp wp, google, plugin, SEO
4
  Donate link: https://www.paypal.me/Kaludi/25
5
  Requires at least: 3.0
6
+ Tested up to: 5.6
7
+ Stable tag: 1.0.69
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
193
 
194
  == Changelog ==
195
 
196
+ = 1.0.69 (25th November 2020) =
197
+ * Fixed: Wrong tooltip link in the infinite scroll #4823
198
+ * Fixed: Images are not showing in the AMP due to SG Optimizer lazy load #4815
199
+ * Fixed: Embeds not working in AMP Takeover mode #4819
200
+ * Fixed: AMPHTML appearing in archive page of Google web stories #4820
201
+ * Fixed: AMP option panel page is blank with ECPay Payment for WooCommerce plugin #4816
202
+ * Fixed: 404 errors on pagination urls #4373
203
+ * Fixed: Blank lines not appearing between paragraphs #4818
204
+ * Fixed: amp-story-player preload is being added when not using #4828
205
+
206
  = 1.0.68.1 (10th November 2020) =
207
  * Fixed: Missing amphtml on product pages #4822
208
  * Fixed: Debug warnings #4821
accelerated-moblie-pages.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Accelerated Mobile Pages
4
  Plugin URI: https://wordpress.org/plugins/accelerated-mobile-pages/
5
  Description: AMP for WP - Accelerated Mobile Pages for WordPress
6
- Version: 1.0.68.1
7
  Author: Ahmed Kaludi, Mohammed Kaludi
8
  Author URI: https://ampforwp.com/
9
  Donate link: https://www.paypal.me/Kaludi/25
@@ -20,7 +20,7 @@ define('AMPFORWP_PLUGIN_DIR_URI', plugin_dir_url(__FILE__));
20
  define('AMPFORWP_DISQUS_URL',plugin_dir_url(__FILE__).'includes/disqus.html');
21
  define('AMPFORWP_IMAGE_DIR',plugin_dir_url(__FILE__).'images');
22
  define('AMPFORWP_MAIN_PLUGIN_DIR', plugin_dir_path( __DIR__ ) );
23
- define('AMPFORWP_VERSION','1.0.68.1');
24
  define('AMPFORWP_EXTENSION_DIR',plugin_dir_path(__FILE__).'includes/options/extensions');
25
  if(!defined('AMPFROWP_HOST_NAME')){
26
  $urlinfo = get_bloginfo('url');
@@ -301,6 +301,16 @@ function ampforwp_add_custom_rewrite_rules() {
301
  }
302
  }
303
  }
 
 
 
 
 
 
 
 
 
 
304
  }
305
  add_action( 'init', 'ampforwp_add_custom_rewrite_rules', 25 );
306
  // Delete category_base transient when it is updated #2924
@@ -1285,6 +1295,9 @@ function ampforwp_vendor_is_amp_endpoint(){
1285
  global $pagenow;
1286
  if ( ! function_exists('amp_activate') && ! function_exists('is_amp_endpoint' ) && 'plugins.php' !== $pagenow ) {
1287
  function is_amp_endpoint(){
 
 
 
1288
  return false !== get_query_var( AMP_QUERY_VAR, false );
1289
  }
1290
  }
3
  Plugin Name: Accelerated Mobile Pages
4
  Plugin URI: https://wordpress.org/plugins/accelerated-mobile-pages/
5
  Description: AMP for WP - Accelerated Mobile Pages for WordPress
6
+ Version: 1.0.69
7
  Author: Ahmed Kaludi, Mohammed Kaludi
8
  Author URI: https://ampforwp.com/
9
  Donate link: https://www.paypal.me/Kaludi/25
20
  define('AMPFORWP_DISQUS_URL',plugin_dir_url(__FILE__).'includes/disqus.html');
21
  define('AMPFORWP_IMAGE_DIR',plugin_dir_url(__FILE__).'images');
22
  define('AMPFORWP_MAIN_PLUGIN_DIR', plugin_dir_path( __DIR__ ) );
23
+ define('AMPFORWP_VERSION','1.0.69');
24
  define('AMPFORWP_EXTENSION_DIR',plugin_dir_path(__FILE__).'includes/options/extensions');
25
  if(!defined('AMPFROWP_HOST_NAME')){
26
  $urlinfo = get_bloginfo('url');
301
  }
302
  }
303
  }
304
+ add_rewrite_rule(
305
+ '(.+?)-[0-9]+\/([0-9]{1,})\/amp$',
306
+ 'index.php?amp=1&name=$matches[1]&paged=$matches[2]',
307
+ 'top'
308
+ );
309
+ add_rewrite_rule(
310
+ '(.+?)\/([0-9]{1,})\/amp$',
311
+ 'index.php?amp=1&name=$matches[1]&paged=$matches[2]',
312
+ 'top'
313
+ );
314
  }
315
  add_action( 'init', 'ampforwp_add_custom_rewrite_rules', 25 );
316
  // Delete category_base transient when it is updated #2924
1295
  global $pagenow;
1296
  if ( ! function_exists('amp_activate') && ! function_exists('is_amp_endpoint' ) && 'plugins.php' !== $pagenow ) {
1297
  function is_amp_endpoint(){
1298
+ if(true == ampforwp_get_setting('ampforwp-amp-takeover')){
1299
+ return true;
1300
+ }
1301
  return false !== get_query_var( AMP_QUERY_VAR, false );
1302
  }
1303
  }
changelog.txt CHANGED
@@ -1,5 +1,15 @@
1
  == Changelog ==
2
 
 
 
 
 
 
 
 
 
 
 
3
  = 1.0.68.1 (10th November 2020) =
4
  * Fixed: Missing amphtml on product pages #4822
5
  * Fixed: Debug warnings #4821
1
  == Changelog ==
2
 
3
+ = 1.0.69 (25th November 2020) =
4
+ * Fixed: Wrong tooltip link in the infinite scroll #4823
5
+ * Fixed: Images are not showing in the AMP due to SG Optimizer lazy load #4815
6
+ * Fixed: Embeds not working in AMP Takeover mode #4819
7
+ * Fixed: AMPHTML appearing in archive page of Google web stories #4820
8
+ * Fixed: AMP option panel page is blank with ECPay Payment for WooCommerce plugin #4816
9
+ * Fixed: 404 errors on pagination urls #4373
10
+ * Fixed: Blank lines not appearing between paragraphs #4818
11
+ * Fixed: amp-story-player preload is being added when not using #4828
12
+
13
  = 1.0.68.1 (10th November 2020) =
14
  * Fixed: Missing amphtml on product pages #4822
15
  * Fixed: Debug warnings #4821
images/bf-offer.png ADDED
Binary file
images/blackfriday.png ADDED
Binary file
images/last-chance.png ADDED
Binary file
includes/admin-script.js CHANGED
@@ -2592,6 +2592,18 @@ $("#subscribe-newsletter-form").on('submit',function(e){
2592
  var checkBoxes = $(this).children('input:radio')
2593
  checkBoxes.prop("checked", "true");
2594
  });
 
 
 
 
 
 
 
 
 
 
 
 
2595
  $("#ampforwp-close-notice").click(function(){
2596
  var data = {
2597
  action: 'ampforwp_feedback_remove_notice',
2592
  var checkBoxes = $(this).children('input:radio')
2593
  checkBoxes.prop("checked", "true");
2594
  });
2595
+ $("#amp-close").click(function(){
2596
+ $(".wrapper-discount").remove();
2597
+ });
2598
+ $("#amp-close").click(function(){
2599
+ url: ajaxurl;
2600
+ var data = {
2601
+ action: 'ampforwp_dismiss_discount_btn',
2602
+ };
2603
+ $.post(ajaxurl, data, function(response) {
2604
+ $(".wrapper-discount").remove();
2605
+ });
2606
+ });
2607
  $("#ampforwp-close-notice").click(function(){
2608
  var data = {
2609
  action: 'ampforwp_feedback_remove_notice',
includes/admin-style.css CHANGED
@@ -2097,4 +2097,70 @@ fieldset#redux_builder_amp-ampforwp-onesignal-positioning {
2097
  }
2098
  #amp-show-hide-tax .hide-show-amp-tax{
2099
  cursor: pointer;
2100
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2097
  }
2098
  #amp-show-hide-tax .hide-show-amp-tax{
2099
  cursor: pointer;
2100
+ }
2101
+ .wrapper-discount {
2102
+ position: sticky;
2103
+ bottom: 1rem;
2104
+ border: 0;
2105
+ left: 83%;
2106
+ background: linear-gradient(to right,#eb3349,#f14f35);
2107
+ padding: 15px;
2108
+ border-radius: 5px;
2109
+ text-align: right;
2110
+ display: inline-block;
2111
+ }
2112
+ .wrapper-discount:before {
2113
+ content: "";
2114
+ }
2115
+ .admin_discount_btn{
2116
+ font-weight: normal;
2117
+ font-size: 15px;
2118
+ color: #fff;
2119
+ text-decoration: none;
2120
+ }
2121
+ .admin_discount_btn:hover{
2122
+ color: #ddd;
2123
+ }
2124
+ .offer-img{
2125
+ position: absolute;
2126
+ top: -67px;
2127
+ left: -5px;
2128
+ width: 50%;
2129
+ }
2130
+ .offer-img-24 {
2131
+ position: absolute;
2132
+ top: -15px;
2133
+ left: -75px;
2134
+ width: 100px;
2135
+ }
2136
+ span.offer-text-top {
2137
+ font-size: 12px;
2138
+ text-transform: uppercase;
2139
+ letter-spacing: 1px;
2140
+ margin-bottom: 6px;
2141
+ display: inline-block;
2142
+ }
2143
+ span.offer-text-bm {
2144
+ font-size: 20px;
2145
+ font-weight: 600;
2146
+ }
2147
+ span.offer-text-bm-24 {
2148
+ font-size: 18px;
2149
+ font-weight: 600;
2150
+ padding-left: 30px;
2151
+ }
2152
+ span#amp-close {
2153
+ color: #ececec;
2154
+ background: #000000c7;
2155
+ border-radius: 50%;
2156
+ padding: 0px 7.5px;
2157
+ height: 22px;
2158
+ cursor: pointer;
2159
+ position: absolute;
2160
+ top: -13px;
2161
+ right: -7px;
2162
+ line-height: 18px;
2163
+ font-weight: normal;
2164
+ font-size: 16px;
2165
+ }
2166
+
includes/features/functions.php CHANGED
@@ -47,6 +47,9 @@ function ampforwp_add_admin_styling($hook_suffix){
47
  }
48
  remove_all_actions('admin_notices');
49
  remove_all_actions('all_admin_notices');
 
 
 
50
  add_action('admin_notices', 'ampforwp_dev_mode_notice');
51
  add_action('admin_notices', 'ampforwp_plugins_manager_notice');
52
  add_action('admin_notices', 'ampforwp_ampwptheme_notice');
47
  }
48
  remove_all_actions('admin_notices');
49
  remove_all_actions('all_admin_notices');
50
+ if(class_exists('WC_Ecpay_Apple_Pay')){
51
+ remove_all_actions('admin_footer');
52
+ }
53
  add_action('admin_notices', 'ampforwp_dev_mode_notice');
54
  add_action('admin_notices', 'ampforwp_plugins_manager_notice');
55
  add_action('admin_notices', 'ampforwp_ampwptheme_notice');
includes/features/performance/performance-functions.php CHANGED
@@ -55,7 +55,7 @@ function ampforwp_minify_html_output($content_buffer){
55
  else
56
  $mod = '/s';
57
  $buffer = str_replace(array (chr(13) . chr(10), chr(9)), array (chr(10), ' '), $buffer);
58
- $buffer = str_ireplace(array ('<script', '/script>', '<pre', '/pre>', '<textarea', '/textarea>', '<style', '/style>'), array ('M1N1FY-ST4RT<script', '/script>M1N1FY-3ND', 'M1N1FY-ST4RT<pre', '/pre>M1N1FY-3ND', 'M1N1FY-ST4RT<textarea', '/textarea>M1N1FY-3ND', 'M1N1FY-ST4RT<style', '/style>M1N1FY-3ND'), $buffer);
59
  $split = explode('M1N1FY-3ND', $buffer);
60
  $buffer = '';
61
  for ($i=0; $i<count($split); $i++) {
55
  else
56
  $mod = '/s';
57
  $buffer = str_replace(array (chr(13) . chr(10), chr(9)), array (chr(10), ' '), $buffer);
58
+ $buffer = str_ireplace(array ('<script', '/script>', '<pre', '/pre>', '<textarea', '/textarea>', '<style', '/style>','<p', '/p>'), array ('M1N1FY-ST4RT<script', '/script>M1N1FY-3ND', 'M1N1FY-ST4RT<pre', '/pre>M1N1FY-3ND', 'M1N1FY-ST4RT<textarea', '/textarea>M1N1FY-3ND', 'M1N1FY-ST4RT<style', '/style>M1N1FY-3ND','M1N1FY-ST4RT<p', '/p>M1N1FY-3ND'), $buffer);
59
  $split = explode('M1N1FY-3ND', $buffer);
60
  $buffer = '';
61
  for ($i=0; $i<count($split); $i++) {
includes/options/admin-config.php CHANGED
@@ -892,7 +892,8 @@ $freepro_listing = '
892
  <span class="ov"></span>
893
  </div>
894
  <div class="fp-cnt">
895
- <h1>Upgrade to Pro</h1>
 
896
  <p>Take your AMP to the next level with more beautiful themes, great extensions and more powerful features.</p>
897
  <a class="buy" href="#upgrade">BUY NOW</a>
898
  </div>
@@ -995,20 +996,6 @@ $freepro_listing = '
995
  </div>
996
  <p>Integrates with WPML, Polylang and WeGlot to provide localization.</p>
997
  </div>
998
- <div class="fe-2">
999
- <div class="fe-t">
1000
- <img src="'.AMPFORWP_IMAGE_DIR . '/tick.png" />
1001
- <h4>Structured Data</h4>
1002
- </div>
1003
- <p>Advanced Schema integration in AMP and WordPress.</p>
1004
- </div>
1005
- <div class="fe-2">
1006
- <div class="fe-t">
1007
- <img src="'.AMPFORWP_IMAGE_DIR . '/tick.png" />
1008
- <h4>Advanced Custom Field</h4>
1009
- </div>
1010
- <p>Built-in tools to help you impliment ACF easily in AMP.</p>
1011
- </div>
1012
  <div class="fe-2">
1013
  <div class="fe-t">
1014
  <img src="'.AMPFORWP_IMAGE_DIR . '/tick.png" />
@@ -1016,13 +1003,6 @@ $freepro_listing = '
1016
  </div>
1017
  <p>Easily add Rating to the posts. Supports 3 popular rating plugins.</p>
1018
  </div>
1019
- <div class="fe-2">
1020
- <div class="fe-t">
1021
- <img src="'.AMPFORWP_IMAGE_DIR . '/tick.png" />
1022
- <h4>Design Catalogue</h4>
1023
- </div>
1024
- <p>AMP Layouts has 6 pre-built designs, We are constantly adding every week.</p>
1025
- </div>
1026
  <div class="fe-2">
1027
  <div class="fe-t">
1028
  <img src="'.AMPFORWP_IMAGE_DIR . '/tick.png" />
@@ -1044,6 +1024,13 @@ $freepro_listing = '
1044
  </div>
1045
  <p>Be the first one to get the innovative features that we build in the future.</p>
1046
  </div>
 
 
 
 
 
 
 
1047
  </div><!-- /. fet -->
1048
  <div class="pr-btn">
1049
  <a href="#upgrade">Upgrade to Pro</a>
@@ -1059,11 +1046,11 @@ $freepro_listing = '
1059
  </div>
1060
  <div class="pri-lst">
1061
  <div class="pri-tb">
1062
- <a href="https://accounts.ampforwp.com/order?edd_action=add_to_cart&download_id=24570&edd_options[price_id]=1">
1063
  <h5>PERSONAL</h5>
1064
  <span class="d-amt"><sup>$</sup>149</span>
1065
- <span class="amt"><sup>$</sup>149</span>
1066
- <span class="s-amt">(Save $59)</span>
1067
  <span class="bil">Billed Annually</span>
1068
  <span class="s">1 Site License</span>
1069
  <span class="e">E-mail support</span>
@@ -1073,11 +1060,11 @@ $freepro_listing = '
1073
  </a>
1074
  </div>
1075
  <div class="pri-tb rec">
1076
- <a href="https://accounts.ampforwp.com/order?edd_action=add_to_cart&download_id=24570&edd_options[price_id]=2">
1077
  <h5>MULTIPLE</h5>
1078
  <span class="d-amt"><sup>$</sup>199</span>
1079
- <span class="amt"><sup>$</sup>199</span>
1080
- <span class="s-amt">(Save $79)</span>
1081
  <span class="bil">Billed Annually</span>
1082
  <span class="s">3 Site License</span>
1083
  <span class="e">E-mail support</span>
@@ -1088,11 +1075,11 @@ $freepro_listing = '
1088
  </a>
1089
  </div>
1090
  <div class="pri-tb">
1091
- <a href="https://accounts.ampforwp.com/order?edd_action=add_to_cart&download_id=24570&edd_options[price_id]=3">
1092
  <h5>WEBMASTER</h5>
1093
  <span class="d-amt"><sup>$</sup>249</span>
1094
- <span class="amt"><sup>$</sup>249</span>
1095
- <span class="s-amt">(Save $99)</span>
1096
  <span class="bil">Billed Annually</span>
1097
  <span class="s">10 Site License</span>
1098
  <span class="e">E-mail support</span>
@@ -1102,11 +1089,11 @@ $freepro_listing = '
1102
  </a>
1103
  </div>
1104
  <div class="pri-tb">
1105
- <a href="https://accounts.ampforwp.com/order?edd_action=add_to_cart&download_id=24570&edd_options[price_id]=4">
1106
  <h5>FREELANCER</h5>
1107
  <span class="d-amt"><sup>$</sup>299</span>
1108
- <span class="amt"><sup>$</sup>299</span>
1109
- <span class="s-amt">(Save $119)</span>
1110
  <span class="bil">Billed Annually</span>
1111
  <span class="s">25 Site License</span>
1112
  <span class="e">E-mail support</span>
@@ -1116,11 +1103,11 @@ $freepro_listing = '
1116
  </a>
1117
  </div>
1118
  <div class="pri-tb">
1119
- <a href="https://accounts.ampforwp.com/order?edd_action=add_to_cart&download_id=24570&edd_options[price_id]=5">
1120
  <h5>AGENCY</h5>
1121
  <span class="d-amt"><sup>$</sup>499</span>
1122
- <span class="amt"><sup>$</sup>499</span>
1123
- <span class="s-amt">(Save $199)</span>
1124
  <span class="bil">Billed Annually</span>
1125
  <span class="s">Unlimited</span>
1126
  <span class="e">E-mail support</span>
@@ -1410,7 +1397,10 @@ if(get_theme_support('amp-template-mode')){
1410
  $upg_to_pro_url = 'https://ampforwp.com/membership/#utm_source=options-panel&utm_medium=view_pro_features_btn&utm_campaign=AMP%20Plugin';
1411
  $upg_to_pro_target = 'target="_blank"';
1412
  }
1413
- $proDetailsProvide = '<a class="technical_support_btn_txt" href="https://ampforwp.com/support/" target="_blank">'.esc_html__('Technical Support','accelerated-mobile-pages').'</a> <a class="premium_features_btn" href="https://ampforwp.com/membership/#utm_source=options-panel&utm_medium=view_pro_features_btn&utm_campaign=AMP%20Plugin" target="_blank">Upgrade to PRO</a> ';
 
 
 
1414
  if($ampforwp_nameOfUser!=""){
1415
  $proDetailsProvide = "<span class='extension-menu-call'><span class='activated-plugins'>Hello, ".esc_html($ampforwp_nameOfUser)."</span> <a class='' href='".esc_url($amppro_settings_url)."'><i class='dashicons-before dashicons-admin-generic'></i></a></span>";
1416
  }elseif($ampforwp_is_productActivated){
@@ -4150,7 +4140,7 @@ Redux::setSection( $opt_name, array(
4150
  'id' => 'ampforwp-infinite-scroll',
4151
  'type' => 'switch',
4152
  'title' => esc_html__('Infinite Scroll (Experimental)', 'accelerated-mobile-pages'),
4153
- 'tooltip-subtitle' => sprintf('%s <a href="%s" target="_blank">%s</a>', esc_html__('Read more about it here:', 'accelerated-mobile-pages'), esc_url('https://www.ampproject.org/docs/reference/components/amp-next-page'), esc_html__('amp-next-page','accelerated-mobile-pages')),
4154
  'default' => false,
4155
  ),
4156
  $newspaper_theme_check,
@@ -5982,6 +5972,16 @@ $single_page_options = array(
5982
  'default' => '1',
5983
  'required' => array('amp-pagination' , '=' , '1'),
5984
  ),
 
 
 
 
 
 
 
 
 
 
5985
  array(
5986
  'id' => 'ampforwp-swift-recent-posts',
5987
  'type' => 'switch',
892
  <span class="ov"></span>
893
  </div>
894
  <div class="fp-cnt">
895
+ <h1>Black Friday & Cyber Monday Deal</h1>
896
+ <h2>Flat 50% discount on all the products for a very limited time</h2>
897
  <p>Take your AMP to the next level with more beautiful themes, great extensions and more powerful features.</p>
898
  <a class="buy" href="#upgrade">BUY NOW</a>
899
  </div>
996
  </div>
997
  <p>Integrates with WPML, Polylang and WeGlot to provide localization.</p>
998
  </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
999
  <div class="fe-2">
1000
  <div class="fe-t">
1001
  <img src="'.AMPFORWP_IMAGE_DIR . '/tick.png" />
1003
  </div>
1004
  <p>Easily add Rating to the posts. Supports 3 popular rating plugins.</p>
1005
  </div>
 
 
 
 
 
 
 
1006
  <div class="fe-2">
1007
  <div class="fe-t">
1008
  <img src="'.AMPFORWP_IMAGE_DIR . '/tick.png" />
1024
  </div>
1025
  <p>Be the first one to get the innovative features that we build in the future.</p>
1026
  </div>
1027
+ <div class="fe-2">
1028
+ <div class="fe-t">
1029
+ <img src="'.AMPFORWP_IMAGE_DIR . '/tick.png" />
1030
+ <h4>45+ AMP Extensions</h4>
1031
+ </div>
1032
+ <p>Super Charge your AMP pages with Powerful AMP Extensions</p>
1033
+ </div>
1034
  </div><!-- /. fet -->
1035
  <div class="pr-btn">
1036
  <a href="#upgrade">Upgrade to Pro</a>
1046
  </div>
1047
  <div class="pri-lst">
1048
  <div class="pri-tb">
1049
+ <a href="https://accounts.ampforwp.com/order?edd_action=add_to_cart&discount=BFCM2020&download_id=24570&edd_options[price_id]=1">
1050
  <h5>PERSONAL</h5>
1051
  <span class="d-amt"><sup>$</sup>149</span>
1052
+ <span class="amt"><sup>$</sup>74</span>
1053
+ <span class="s-amt">(Save $75)</span>
1054
  <span class="bil">Billed Annually</span>
1055
  <span class="s">1 Site License</span>
1056
  <span class="e">E-mail support</span>
1060
  </a>
1061
  </div>
1062
  <div class="pri-tb rec">
1063
+ <a href="https://accounts.ampforwp.com/order?edd_action=add_to_cart&discount=BFCM2020&download_id=24570&edd_options[price_id]=2">
1064
  <h5>MULTIPLE</h5>
1065
  <span class="d-amt"><sup>$</sup>199</span>
1066
+ <span class="amt"><sup>$</sup>99</span>
1067
+ <span class="s-amt">(Save $100)</span>
1068
  <span class="bil">Billed Annually</span>
1069
  <span class="s">3 Site License</span>
1070
  <span class="e">E-mail support</span>
1075
  </a>
1076
  </div>
1077
  <div class="pri-tb">
1078
+ <a href="https://accounts.ampforwp.com/order?edd_action=add_to_cart&discount=BFCM2020&download_id=24570&edd_options[price_id]=3">
1079
  <h5>WEBMASTER</h5>
1080
  <span class="d-amt"><sup>$</sup>249</span>
1081
+ <span class="amt"><sup>$</sup>124</span>
1082
+ <span class="s-amt">(Save $125)</span>
1083
  <span class="bil">Billed Annually</span>
1084
  <span class="s">10 Site License</span>
1085
  <span class="e">E-mail support</span>
1089
  </a>
1090
  </div>
1091
  <div class="pri-tb">
1092
+ <a href="https://accounts.ampforwp.com/order?edd_action=add_to_cart&discount=BFCM2020&download_id=24570&edd_options[price_id]=4">
1093
  <h5>FREELANCER</h5>
1094
  <span class="d-amt"><sup>$</sup>299</span>
1095
+ <span class="amt"><sup>$</sup>149</span>
1096
+ <span class="s-amt">(Save $150)</span>
1097
  <span class="bil">Billed Annually</span>
1098
  <span class="s">25 Site License</span>
1099
  <span class="e">E-mail support</span>
1103
  </a>
1104
  </div>
1105
  <div class="pri-tb">
1106
+ <a href="https://accounts.ampforwp.com/order?edd_action=add_to_cart&discount=BFCM2020&download_id=24570&edd_options[price_id]=5">
1107
  <h5>AGENCY</h5>
1108
  <span class="d-amt"><sup>$</sup>499</span>
1109
+ <span class="amt"><sup>$</sup>249</span>
1110
+ <span class="s-amt">(Save $250)</span>
1111
  <span class="bil">Billed Annually</span>
1112
  <span class="s">Unlimited</span>
1113
  <span class="e">E-mail support</span>
1397
  $upg_to_pro_url = 'https://ampforwp.com/membership/#utm_source=options-panel&utm_medium=view_pro_features_btn&utm_campaign=AMP%20Plugin';
1398
  $upg_to_pro_target = 'target="_blank"';
1399
  }
1400
+ $proDetailsProvide = '<a class="technical_support_btn_txt" href="https://ampforwp.com/support/" target="_blank">'.esc_html__('Technical Support','accelerated-mobile-pages').'</a> <a class="premium_features_btn dof" href="'.$upg_to_pro_url.'" id="ampforwp-prem-upg-to" '.$upg_to_pro_target.'>
1401
+ <img class="black-friday-img" src="'.AMPFORWP_IMAGE_DIR . '/blackfriday.png" />
1402
+ <span>50% OFF on Upgrades & Renewals</span>
1403
+ </a> ';
1404
  if($ampforwp_nameOfUser!=""){
1405
  $proDetailsProvide = "<span class='extension-menu-call'><span class='activated-plugins'>Hello, ".esc_html($ampforwp_nameOfUser)."</span> <a class='' href='".esc_url($amppro_settings_url)."'><i class='dashicons-before dashicons-admin-generic'></i></a></span>";
1406
  }elseif($ampforwp_is_productActivated){
4140
  'id' => 'ampforwp-infinite-scroll',
4141
  'type' => 'switch',
4142
  'title' => esc_html__('Infinite Scroll (Experimental)', 'accelerated-mobile-pages'),
4143
+ 'tooltip-subtitle' => sprintf('%s <a href="%s" target="_blank">%s</a>', esc_html__('Read more about it', 'accelerated-mobile-pages'), esc_url('https://ampforwp.com/tutorials/article/infinite-scroll-feature-in-amp/'), esc_html__('here:','accelerated-mobile-pages')),
4144
  'default' => false,
4145
  ),
4146
  $newspaper_theme_check,
5972
  'default' => '1',
5973
  'required' => array('amp-pagination' , '=' , '1'),
5974
  ),
5975
+ array(
5976
+ 'id' => 'ampforwp-pagination-link-type',
5977
+ 'class' => 'child_opt child_opt_arrow',
5978
+ 'type' => 'switch',
5979
+ 'title' => esc_html__('Change Pagination Links to /amp', 'accelerated-mobile-pages'),
5980
+ 'default' => '0',
5981
+ 'required' => array('amp-pagination' , '=' , '1'),
5982
+ 'tooltip-subtitle' => sprintf('%s',
5983
+ esc_html__('Enable this option if post pagination link with ?amp=1 does not work. It will change pagination link ?amp=1 to /amp', 'accelerated-mobile-pages')),
5984
+ ),
5985
  array(
5986
  'id' => 'ampforwp-swift-recent-posts',
5987
  'type' => 'switch',
includes/options/redux-core/assets/css/redux-admin.css CHANGED
@@ -91,7 +91,7 @@
91
  .search-wrapper{
92
  align-items: center;
93
  display: flex;
94
- margin-right: 5px;
95
  }
96
  .display_header .search-wrapper .redux-amp-search-icon{
97
  color:#cacaca;
@@ -103,7 +103,7 @@
103
  .redux-amp-search-icon{
104
  position: absolute;
105
  top: 21px;
106
- right: 293px;
107
  }
108
  .redux-container{
109
  position: relative;
@@ -511,7 +511,7 @@ background: linear-gradient(45deg, #E47B49 0%, #ea4c89 100%);
511
  top: 1px;
512
  left: 4px;
513
  }
514
- .premium_features_btn:hover{background: #fff;color:#eb3349 !important; }
515
  .getting_started_listing .align_left{display: none}
516
  .getting_started_listing li a{width: 288px}
517
  .extension_listing li:hover{border-color:rgba(48, 63, 159, 0.35)}
@@ -716,14 +716,19 @@ background: linear-gradient(45deg, #E47B49 0%, #ea4c89 100%);
716
  text-align: center;
717
  }
718
  .fp-cnt h1{
719
- font-size: 50px;
 
 
 
 
 
720
  color: #fff;
721
  font-weight: 600;
722
  }
723
  .fp-cnt p{
724
  margin-top: 5px;
725
  color: #fff;
726
- font-size:23px;
727
  padding: 0 100px;
728
  line-height: 1.4;
729
  }
@@ -971,7 +976,7 @@ background: linear-gradient(45deg, #E47B49 0%, #ea4c89 100%);
971
  color: #666;
972
  font-weight: 500;
973
  margin-bottom: 15px;
974
- display: none;
975
  text-decoration: line-through;
976
  }
977
  .d-amt sup{
@@ -984,7 +989,7 @@ background: linear-gradient(45deg, #E47B49 0%, #ea4c89 100%);
984
  color: #4caf50;
985
  font-weight: 500;
986
  margin-bottom:10px;
987
- display: none;
988
  }
989
  .pri-tb .amt sup{
990
  font-size:22px;
@@ -1009,6 +1014,7 @@ background: linear-gradient(45deg, #E47B49 0%, #ea4c89 100%);
1009
  margin: 0 auto;
1010
  padding: 1px 7px 2px 7px;
1011
  border-radius: 45px;
 
1012
  }
1013
  .pri-by{
1014
  font-size: 15px;
@@ -1529,4 +1535,37 @@ doc-cnt h1 , .doc-cnt p{
1529
  }
1530
  .doc-cnt .buy{
1531
  background: #000;
1532
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
91
  .search-wrapper{
92
  align-items: center;
93
  display: flex;
94
+ margin-right: 45%;
95
  }
96
  .display_header .search-wrapper .redux-amp-search-icon{
97
  color:#cacaca;
103
  .redux-amp-search-icon{
104
  position: absolute;
105
  top: 21px;
106
+ left: 22%;
107
  }
108
  .redux-container{
109
  position: relative;
511
  top: 1px;
512
  left: 4px;
513
  }
514
+ .premium_features_btn:hover{color:#7bf3ff !important; }
515
  .getting_started_listing .align_left{display: none}
516
  .getting_started_listing li a{width: 288px}
517
  .extension_listing li:hover{border-color:rgba(48, 63, 159, 0.35)}
716
  text-align: center;
717
  }
718
  .fp-cnt h1{
719
+ font-size: 45px;
720
+ color: #fff;
721
+ font-weight: 600;
722
+ }
723
+ .fp-cnt h2{
724
+ font-size: 25px;
725
  color: #fff;
726
  font-weight: 600;
727
  }
728
  .fp-cnt p{
729
  margin-top: 5px;
730
  color: #fff;
731
+ font-size:20px;
732
  padding: 0 100px;
733
  line-height: 1.4;
734
  }
976
  color: #666;
977
  font-weight: 500;
978
  margin-bottom: 15px;
979
+ display: block;
980
  text-decoration: line-through;
981
  }
982
  .d-amt sup{
989
  color: #4caf50;
990
  font-weight: 500;
991
  margin-bottom:10px;
992
+ display: block;
993
  }
994
  .pri-tb .amt sup{
995
  font-size:22px;
1014
  margin: 0 auto;
1015
  padding: 1px 7px 2px 7px;
1016
  border-radius: 45px;
1017
+ display: none;
1018
  }
1019
  .pri-by{
1020
  font-size: 15px;
1535
  }
1536
  .doc-cnt .buy{
1537
  background: #000;
1538
+ }
1539
+ /** Discount Offer CSS **/
1540
+ .premium_features_btn.dof{
1541
+ background: linear-gradient(to right,#eb3349,#f14f35);
1542
+ padding: 22px 14px 22px 110px;
1543
+ border-radius: 0;
1544
+ position: relative;
1545
+ top: 0px;
1546
+ right: -15px;
1547
+ font-weight: 500;
1548
+ font-size: 15px !important;
1549
+ }
1550
+ .premium_features_btn.dof img{
1551
+ width: 100px;
1552
+ position: absolute;
1553
+ left: 0px;
1554
+ top: 0px;
1555
+ }
1556
+ #toplevel_page_amp_options > a{
1557
+ position: relative;
1558
+ }
1559
+ #toplevel_page_amp_options .wp-menu-name:after{
1560
+ content:"";
1561
+ display:inline-block;
1562
+ background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" id="Capa_1" x="0px" y="0px" viewBox="0 0 512.003 512.003" style="enable-background:new 0 0 512.003 512.003;" xml:space="preserve"><g><g><path xmlns="http://www.w3.org/2000/svg" d="M477.958,262.633c-2.06-4.215-2.06-9.049,0-13.263l19.096-39.065c10.632-21.751,2.208-47.676-19.178-59.023l-38.41-20.38 c-4.144-2.198-6.985-6.11-7.796-10.729l-7.512-42.829c-4.183-23.846-26.241-39.87-50.208-36.479l-43.053,6.09 c-4.647,0.656-9.242-0.838-12.613-4.099l-31.251-30.232c-17.401-16.834-44.661-16.835-62.061,0L193.72,42.859 c-3.372,3.262-7.967,4.753-12.613,4.099l-43.053-6.09c-23.975-3.393-46.025,12.633-50.208,36.479l-7.512,42.827 c-0.811,4.62-3.652,8.531-7.795,10.73l-38.41,20.38c-21.386,11.346-29.81,37.273-19.178,59.024l19.095,39.064 c2.06,4.215,2.06,9.049,0,13.263l-19.096,39.064c-10.632,21.751-2.208,47.676,19.178,59.023l38.41,20.38 c4.144,2.198,6.985,6.11,7.796,10.729l7.512,42.829c3.808,21.708,22.422,36.932,43.815,36.93c2.107,0,4.245-0.148,6.394-0.452 l43.053-6.09c4.643-0.659,9.241,0.838,12.613,4.099l31.251,30.232c8.702,8.418,19.864,12.626,31.03,12.625 c11.163-0.001,22.332-4.209,31.03-12.625l31.252-30.232c3.372-3.261,7.968-4.751,12.613-4.099l43.053,6.09 c23.978,3.392,46.025-12.633,50.208-36.479l7.513-42.827c0.811-4.62,3.652-8.531,7.795-10.73l38.41-20.38 c21.386-11.346,29.81-37.273,19.178-59.024L477.958,262.633z M464.035,334.635l-38.41,20.38 c-12.246,6.499-20.645,18.057-23.04,31.713l-7.512,42.828c-1.415,8.068-8.874,13.487-16.987,12.342l-43.053-6.09 c-13.73-1.945-27.316,2.474-37.281,12.113L266.5,478.152c-5.886,5.694-15.109,5.694-20.997,0l-31.251-30.232 c-8.422-8.147-19.432-12.562-30.926-12.562c-2.106,0-4.229,0.148-6.355,0.449l-43.053,6.09 c-8.106,1.146-15.571-4.274-16.987-12.342l-7.513-42.829c-2.396-13.656-10.794-25.215-23.041-31.712l-38.41-20.38 c-7.236-3.839-10.086-12.61-6.489-19.969l19.096-39.065c6.088-12.456,6.088-26.742,0-39.198l-19.096-39.065 c-3.597-7.359-0.747-16.13,6.489-19.969l38.41-20.38c12.246-6.499,20.645-18.057,23.04-31.713l7.512-42.828 c1.416-8.068,8.874-13.488,16.987-12.342l43.053,6.09c13.725,1.943,27.316-2.474,37.281-12.113l31.252-30.232 c5.886-5.694,15.109-5.694,20.997,0l31.251,30.232c9.965,9.64,23.554,14.056,37.281,12.113l43.053-6.09 c8.107-1.147,15.572,4.274,16.987,12.342l7.512,42.829c2.396,13.656,10.794,25.215,23.041,31.712l38.41,20.38 c7.236,3.839,10.086,12.61,6.489,19.969l-19.096,39.064c-6.088,12.455-6.088,26.743,0,39.198l19.096,39.064 C474.121,322.024,471.271,330.796,464.035,334.635z" style="fill: white;"/></g></g><g><g><path xmlns="http://www.w3.org/2000/svg" d="M363.886,148.116c-5.765-5.766-15.115-5.766-20.881,0L148.116,343.006c-5.766,5.766-5.766,15.115,0,20.881 c2.883,2.883,6.662,4.325,10.44,4.325c3.778,0,7.558-1.441,10.44-4.325l194.889-194.889 C369.653,163.231,369.653,153.883,363.886,148.116z" style="fill: white;"/></g></g><g><g><path xmlns="http://www.w3.org/2000/svg" d="M196.941,123.116c-29.852,0-54.139,24.287-54.139,54.139s24.287,54.139,54.139,54.139s54.139-24.287,54.139-54.139 S226.793,123.116,196.941,123.116z M196.941,201.863c-13.569,0-24.608-11.039-24.608-24.609c0-13.569,11.039-24.608,24.608-24.608 c13.569,0,24.609,11.039,24.609,24.608C221.549,190.824,210.51,201.863,196.941,201.863z" style="fill: white;"/></g></g><g><g><path xmlns="http://www.w3.org/2000/svg" d="M315.061,280.61c-29.852,0-54.139,24.287-54.139,54.139s24.287,54.139,54.139,54.139 c29.852,0,54.139-24.287,54.139-54.139S344.913,280.61,315.061,280.61z M315.061,359.357c-13.569,0-24.609-11.039-24.609-24.608 s11.039-24.608,24.609-24.608c13.569,0,24.608,11.039,24.608,24.608S328.63,359.357,315.061,359.357z" style="fill: white;"/></g></g><g/><g/><g/><g/><g/><g/><g/><g/><g/><g/><g/><g/><g/><g/><g/></svg>');
1563
+ width: 20px;
1564
+ height: 20px;
1565
+ background-repeat: no-repeat;
1566
+ position: absolute;
1567
+ right: 20px;
1568
+ top: 7px;
1569
+ }
1570
+
1571
+ /** Discount Offer CSS Ends **/
includes/vendor/amp/includes/amp-post-template-actions.php CHANGED
@@ -53,7 +53,7 @@ function amp_post_template_add_cached_link($amp_template) {
53
  <?php
54
  $scripts = $amp_template->get( 'amp_component_scripts', array() );
55
  foreach ( $scripts as $element => $script ) :
56
- if (strpos($script, "amp-experiment") || strpos($script, "amp-dynamic-css-classes") || strpos($script, "amp-story")) {
57
  ?>
58
  <link rel="preload" as="script" href="<?php echo esc_url( $script ); ?>">
59
  <?php }
53
  <?php
54
  $scripts = $amp_template->get( 'amp_component_scripts', array() );
55
  foreach ( $scripts as $element => $script ) :
56
+ if (strpos($script, "amp-experiment") || strpos($script, "amp-dynamic-css-classes")) {
57
  ?>
58
  <link rel="preload" as="script" href="<?php echo esc_url( $script ); ?>">
59
  <?php }
readme.txt CHANGED
@@ -3,8 +3,8 @@ Contributors: mohammed_kaludi, ahmedkaludi, ampforwp
3
  Tags: AMP, accelerated mobile pages, mobile, amp project, google amp, amp wp, google, plugin, SEO
4
  Donate link: https://www.paypal.me/Kaludi/25
5
  Requires at least: 3.0
6
- Tested up to: 5.5
7
- Stable tag: 1.0.68.1
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -190,6 +190,16 @@ You can contact us from [here](https://ampforwp.com/contact/)
190
 
191
  == Changelog ==
192
 
 
 
 
 
 
 
 
 
 
 
193
  = 1.0.68.1 (10th November 2020) =
194
  * Fixed: Missing amphtml on product pages #4822
195
  * Fixed: Debug warnings #4821
3
  Tags: AMP, accelerated mobile pages, mobile, amp project, google amp, amp wp, google, plugin, SEO
4
  Donate link: https://www.paypal.me/Kaludi/25
5
  Requires at least: 3.0
6
+ Tested up to: 5.6
7
+ Stable tag: 1.0.69
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
190
 
191
  == Changelog ==
192
 
193
+ = 1.0.69 (25th November 2020) =
194
+ * Fixed: Wrong tooltip link in the infinite scroll #4823
195
+ * Fixed: Images are not showing in the AMP due to SG Optimizer lazy load #4815
196
+ * Fixed: Embeds not working in AMP Takeover mode #4819
197
+ * Fixed: AMPHTML appearing in archive page of Google web stories #4820
198
+ * Fixed: AMP option panel page is blank with ECPay Payment for WooCommerce plugin #4816
199
+ * Fixed: 404 errors on pagination urls #4373
200
+ * Fixed: Blank lines not appearing between paragraphs #4818
201
+ * Fixed: amp-story-player preload is being added when not using #4828
202
+
203
  = 1.0.68.1 (10th November 2020) =
204
  * Fixed: Missing amphtml on product pages #4822
205
  * Fixed: Debug warnings #4821
templates/design-manager/swift/page.php CHANGED
@@ -15,7 +15,11 @@ amp_header(); ?>
15
  <?php } ?>
16
  <?php } // Level up Condition ends here?>
17
  </div>
18
- <?php if ( true == ampforwp_get_setting('featured_image_swift_page') && ampforwp_has_post_thumbnail() && !checkAMPforPageBuilderStatus(ampforwp_get_the_ID()) ) { ?>
 
 
 
 
19
  <div class="sf-img">
20
  <?php amp_featured_image();?>
21
  </div>
@@ -23,7 +27,7 @@ amp_header(); ?>
23
  <div class="sf-img">
24
  <?php amp_featured_image();?>
25
  </div>
26
- <?php } ?>
27
  <div <?php if(!checkAMPforPageBuilderStatus(ampforwp_get_the_ID())){ ?>class="cntr"<?php } ?>>
28
  <div class="pg">
29
  <?php if ( is_page() && true == ampforwp_get_setting('ampforwp-page-social') && 'above-content' == ampforwp_get_setting('swift-social-position') ){
15
  <?php } ?>
16
  <?php } // Level up Condition ends here?>
17
  </div>
18
+ <?php
19
+ $paged = get_query_var( 'paged' );
20
+ $page = get_query_var( 'page' );
21
+ if($paged==0 && $page==0){
22
+ if ( true == ampforwp_get_setting('featured_image_swift_page') && ampforwp_has_post_thumbnail() && !checkAMPforPageBuilderStatus(ampforwp_get_the_ID()) ) { ?>
23
  <div class="sf-img">
24
  <?php amp_featured_image();?>
25
  </div>
27
  <div class="sf-img">
28
  <?php amp_featured_image();?>
29
  </div>
30
+ <?php } } ?>
31
  <div <?php if(!checkAMPforPageBuilderStatus(ampforwp_get_the_ID())){ ?>class="cntr"<?php } ?>>
32
  <div class="pg">
33
  <?php if ( is_page() && true == ampforwp_get_setting('ampforwp-page-social') && 'above-content' == ampforwp_get_setting('swift-social-position') ){
templates/design-manager/swift/single.php CHANGED
@@ -3,7 +3,9 @@ if ( ! defined( 'ABSPATH' ) ) {
3
  exit;
4
  }
5
  global $redux_builder_amp; ?>
6
- <?php amp_header(); ?>
 
 
7
  <?php if(ampforwp_get_setting('single-design-type') == '1'){?>
8
  <div class="sp sgl">
9
  <?php if(!checkAMPforPageBuilderStatus(get_the_ID())){ ?>
@@ -19,13 +21,16 @@ global $redux_builder_amp; ?>
19
  </div>
20
  <?php } ?>
21
  </div>
22
- <?php if ( ampforwp_get_setting('swift-featued-image') && ampforwp_has_post_thumbnail() ) { ?>
 
 
23
  <?php if ( ampforwp_get_setting('swift-featued-image-type') == 1 || empty(ampforwp_get_setting('swift-featued-image-type')) ) { ?>
24
  <div class="sf-img">
25
  <?php amp_featured_image();?>
26
  </div>
27
  <?php } // Swift Featured Image Type 1
28
  }
 
29
  } ?>
30
  <div class="sp-cnt">
31
  <div class="cntr">
@@ -38,13 +43,16 @@ global $redux_builder_amp; ?>
38
  echo ampforwp_addThis_support();
39
  } ?>
40
  <div class="cntn-wrp artl-cnt">
41
- <?php if ( ampforwp_get_setting('swift-featued-image') && ampforwp_has_post_thumbnail() ) { ?>
 
 
42
  <?php if ( ampforwp_get_setting('swift-featued-image-type') == 2) { ?>
43
  <div class="sf-img">
44
  <?php amp_featured_image();?>
45
  </div>
46
  <?php } // Swift Featured Image Type 2
47
- } // Swift Featured Image ?>
 
48
  <?php amp_content(); ?>
49
  </div>
50
  <?php do_action( 'ampforwp_after_the_post_content_wrp' ); ?>
@@ -331,11 +339,14 @@ do_action("ampforwp_single_design_type_handle_d1");
331
  <?php amp_excerpt(); ?>
332
  </div>
333
  <?php } ?>
334
- <?php if ( ampforwp_get_setting('swift-featued-image') && ampforwp_has_post_thumbnail() ) { ?>
 
 
335
  <div class="sf-img">
336
  <?php amp_featured_image();?>
337
  </div>
338
  <?php }
 
339
  }?>
340
  <div class="sp-cnt">
341
  <div class="sp-rl">
3
  exit;
4
  }
5
  global $redux_builder_amp; ?>
6
+ <?php amp_header();
7
+ $paged = get_query_var( 'paged' );
8
+ $page = get_query_var( 'page' ); ?>
9
  <?php if(ampforwp_get_setting('single-design-type') == '1'){?>
10
  <div class="sp sgl">
11
  <?php if(!checkAMPforPageBuilderStatus(get_the_ID())){ ?>
21
  </div>
22
  <?php } ?>
23
  </div>
24
+ <?php
25
+ if($paged==0 && $page==0){
26
+ if ( ampforwp_get_setting('swift-featued-image') && ampforwp_has_post_thumbnail() ) { ?>
27
  <?php if ( ampforwp_get_setting('swift-featued-image-type') == 1 || empty(ampforwp_get_setting('swift-featued-image-type')) ) { ?>
28
  <div class="sf-img">
29
  <?php amp_featured_image();?>
30
  </div>
31
  <?php } // Swift Featured Image Type 1
32
  }
33
+ }
34
  } ?>
35
  <div class="sp-cnt">
36
  <div class="cntr">
43
  echo ampforwp_addThis_support();
44
  } ?>
45
  <div class="cntn-wrp artl-cnt">
46
+ <?php
47
+ if($paged==0 && $page==0){
48
+ if ( ampforwp_get_setting('swift-featued-image') && ampforwp_has_post_thumbnail() ) { ?>
49
  <?php if ( ampforwp_get_setting('swift-featued-image-type') == 2) { ?>
50
  <div class="sf-img">
51
  <?php amp_featured_image();?>
52
  </div>
53
  <?php } // Swift Featured Image Type 2
54
+ } // Swift Featured Image
55
+ }?>
56
  <?php amp_content(); ?>
57
  </div>
58
  <?php do_action( 'ampforwp_after_the_post_content_wrp' ); ?>
339
  <?php amp_excerpt(); ?>
340
  </div>
341
  <?php } ?>
342
+ <?php
343
+ if($paged==0 && $page==0){
344
+ if ( ampforwp_get_setting('swift-featued-image') && ampforwp_has_post_thumbnail() ) { ?>
345
  <div class="sf-img">
346
  <?php amp_featured_image();?>
347
  </div>
348
  <?php }
349
+ }
350
  }?>
351
  <div class="sp-cnt">
352
  <div class="sp-rl">
templates/features.php CHANGED
@@ -333,6 +333,9 @@ define('AMPFORWP_COMMENTS_PER_PAGE', ampforwp_define_comments_number() );
333
  //dont Echo anything
334
  } else {
335
  $supported_types = ampforwp_get_all_post_types();
 
 
 
336
  $supported_types = apply_filters('get_amp_supported_post_types',$supported_types);
337
 
338
  $type = get_post_type();
@@ -3966,6 +3969,49 @@ function ampforwp_post_pagination( $args = '' ) {
3966
  }
3967
  $numpages = count($ampforwp_new_content);
3968
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3969
  }
3970
  }
3971
  $defaults = array(
@@ -4095,7 +4141,11 @@ function ampforwp_post_paginated_link_generator( $i ) {
4095
 
4096
  }
4097
  if ( false == ampforwp_get_setting('ampforwp-amp-takeover') ) {
4098
- $url = add_query_arg(AMPFORWP_AMP_QUERY_VAR,'1',$url);
 
 
 
 
4099
  }
4100
  return '<a href="' . esc_url( $url ) . '">';
4101
  }
@@ -4109,6 +4159,45 @@ function ampforwp_post_paginated_content($content){
4109
  if ( is_singular() || ampforwp_is_front_page() ){
4110
  global $redux_builder_amp, $page, $multipage;
4111
  $ampforwp_new_content = $ampforwp_the_content = $checker = '';
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4112
  $ampforwp_the_content = $content;
4113
  $checker = preg_match('/<!--nextpage-->/', $ampforwp_the_content);
4114
  if ( 1 === $checker && true == ampforwp_get_setting('amp-pagination') ) {
@@ -4129,6 +4218,7 @@ function ampforwp_post_paginated_content($content){
4129
  else {
4130
  return $ampforwp_the_content;
4131
  }
 
4132
  }
4133
  return $content;
4134
  }
@@ -6023,6 +6113,9 @@ function ampforwp_is_non_amp( $type="" ) {
6023
  if(get_query_var( 'robots' )){
6024
  return;
6025
  }
 
 
 
6026
  if(is_search() && 0 == ampforwp_get_setting('amp-redirection-search')){
6027
  return false;
6028
  }
@@ -9020,4 +9113,51 @@ function ampforwp_video_lightbox_css(){
9020
  .amp-video-box{max-width:800px}
9021
  .amp-video-img{max-width:600px;position:relative}
9022
  .amp-video-play-on-image{cursor:pointer;margin:auto;width:56px;height:56px;-webkit-border-radius:50%;border-radius:50%;background-color:rgba(0,0,0,.2);background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGAAAABgCAMAAADVRocKAAAAY1BMVEVHcEz///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////80LMUcAAAAIHRSTlMA1d4MSXeg9glf6yEq4hfnnr7Z8qm5U/3Jm1pwFJcmBYTgJ9QAAAIjSURBVGje7VnJdoMwDFSMHVMSQljCklX//5U99NQHGEm22gtz9tPAWNYKsGPHDiou1h3rpvDD4Iumvjp7SWg86yeDM5ipz5KYt53HFfjORn+8KzEI88iizLe4icLlUvtfFZJQ3kXmTzWScTsJPr9FBtovpvn8iExMrJu4jMjGyHh67xIFMOSLOFcoQnUmfr/QPmL1JulfohiGcA/5iBEYt33piFG4br4vjMTGizu1sQRt2FlrjMZNVSBExEBszaoUBOW6JzlMArf6A0XIOzyZoMgkPwDnA5nhsWz/E4wRnBxhVuoTDBMAkGVarma6TQKyTN3iFfttAqJMg1/y1B4JBFSZ+gWCiUZAk+m1QGCIBCSZmoVEhlQCkkxPppP+JiDIZNlxiFmYOXaqnEX2sEwTO9XMq6egTPXsfMMlCMt0mB0v2ARBmYrZYS8gCMjkZ2cHCcG6TMPfE6hLpH7J6m6a+KHN67urdqhQD3bq4Vo94ainTP2kn7RssbqFF7a5buk4dP9T/Ib9KEH5Dg/lBkS/hVJvAiEvU9gPtLFwT0HQh1r9m/IoQX8YEj+t2JwCX+PsT7ojtWH8EIaCJmIo+FQeaxJHs9LBbPkGIt4ilQxjxi8ajj+BgZztra8P8MBcUAi2LCdGXJKsWADgTozeppeuoXJXEPKXfM0FANnDaC7qtlaNbfyq8Uep/rXQYDUvm0M6XKyb6sPPuvdwm5x9wo4dO6j4BoilN6H4pmTiAAAAAElFTkSuQmCC);background-position:center;-webkit-background-size:48px 48px;background-size:48px 48px;position:absolute;top:0;bottom:0;left:0;right:0}';
9023
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
333
  //dont Echo anything
334
  } else {
335
  $supported_types = ampforwp_get_all_post_types();
336
+ if(isset($supported_types['web-story'])){
337
+ $supported_types['web-story'] = '';
338
+ }
339
  $supported_types = apply_filters('get_amp_supported_post_types',$supported_types);
340
 
341
  $type = get_post_type();
3969
  }
3970
  $numpages = count($ampforwp_new_content);
3971
  }
3972
+ }else if(ampforwp_get_setting('ampforwp-pagination-link-type')==true && is_singular()){
3973
+ $id = ampforwp_get_the_ID();
3974
+ $content = get_post_field( 'post_content', $id);
3975
+ if ($content) {
3976
+ $sanitizer_obj = new AMPFORWP_Content( $content,
3977
+ apply_filters( 'amp_content_embed_handlers', array(
3978
+ 'AMP_Reddit_Embed_Handler' => array(),
3979
+ 'AMP_Twitter_Embed_Handler' => array(),
3980
+ 'AMP_YouTube_Embed_Handler' => array(),
3981
+ 'AMP_DailyMotion_Embed_Handler' => array(),
3982
+ 'AMP_Vimeo_Embed_Handler' => array(),
3983
+ 'AMP_SoundCloud_Embed_Handler' => array(),
3984
+ 'AMP_Instagram_Embed_Handler' => array(),
3985
+ 'AMP_Vine_Embed_Handler' => array(),
3986
+ 'AMP_Facebook_Embed_Handler' => array(),
3987
+ 'AMP_Pinterest_Embed_Handler' => array(),
3988
+ 'AMP_Gallery_Embed_Handler' => array(),
3989
+ 'AMP_Playlist_Embed_Handler' => array(),
3990
+ ) ),
3991
+ apply_filters( 'amp_content_sanitizers', array(
3992
+ 'AMP_Style_Sanitizer' => array(),
3993
+ 'AMP_Blacklist_Sanitizer' => array(),
3994
+ 'AMP_Img_Sanitizer' => array(),
3995
+ 'AMP_Video_Sanitizer' => array(),
3996
+ 'AMP_Audio_Sanitizer' => array(),
3997
+ 'AMP_Playbuzz_Sanitizer' => array(),
3998
+ 'AMP_Iframe_Sanitizer' => array(
3999
+ 'add_placeholder' => true,
4000
+ ),
4001
+ ) ) );
4002
+ $content = $sanitizer_obj->get_amp_content();
4003
+ $checker = preg_match('/<!--nextpage-->/', $content);
4004
+ if ( 1 === $checker ) {
4005
+ $multipage = $more = 1;
4006
+ $ampforwp_new_content = explode('<!--nextpage-->', $content);
4007
+ $queried_var = get_query_var('paged');
4008
+ if ( $queried_var > 1 ) {
4009
+ $page = $queried_var;
4010
+ }
4011
+ $numpages = count($ampforwp_new_content);
4012
+ }
4013
+ }
4014
+
4015
  }
4016
  }
4017
  $defaults = array(
4141
 
4142
  }
4143
  if ( false == ampforwp_get_setting('ampforwp-amp-takeover') ) {
4144
+ if(ampforwp_get_setting('ampforwp-pagination-link-type')==true && is_singular()){
4145
+ $url = ampforwp_url_controller($url);
4146
+ }else{
4147
+ $url = add_query_arg(AMPFORWP_AMP_QUERY_VAR,'1',$url);
4148
+ }
4149
  }
4150
  return '<a href="' . esc_url( $url ) . '">';
4151
  }
4159
  if ( is_singular() || ampforwp_is_front_page() ){
4160
  global $redux_builder_amp, $page, $multipage;
4161
  $ampforwp_new_content = $ampforwp_the_content = $checker = '';
4162
+ if(ampforwp_get_setting('ampforwp-pagination-link-type')==true && is_singular()){
4163
+ $id = ampforwp_get_the_ID();
4164
+ $content = get_post_field( 'post_content', $id);
4165
+ if ($content) {
4166
+ $sanitizer_obj = new AMPFORWP_Content( $content,
4167
+ apply_filters( 'amp_content_embed_handlers', array(
4168
+ 'AMP_Reddit_Embed_Handler' => array(),
4169
+ 'AMP_Twitter_Embed_Handler' => array(),
4170
+ 'AMP_YouTube_Embed_Handler' => array(),
4171
+ 'AMP_DailyMotion_Embed_Handler' => array(),
4172
+ 'AMP_Vimeo_Embed_Handler' => array(),
4173
+ 'AMP_SoundCloud_Embed_Handler' => array(),
4174
+ 'AMP_Instagram_Embed_Handler' => array(),
4175
+ 'AMP_Vine_Embed_Handler' => array(),
4176
+ 'AMP_Facebook_Embed_Handler' => array(),
4177
+ 'AMP_Pinterest_Embed_Handler' => array(),
4178
+ 'AMP_Gallery_Embed_Handler' => array(),
4179
+ 'AMP_Playlist_Embed_Handler' => array(),
4180
+ ) ),
4181
+ apply_filters( 'amp_content_sanitizers', array(
4182
+ 'AMP_Style_Sanitizer' => array(),
4183
+ 'AMP_Blacklist_Sanitizer' => array(),
4184
+ 'AMP_Img_Sanitizer' => array(),
4185
+ 'AMP_Video_Sanitizer' => array(),
4186
+ 'AMP_Audio_Sanitizer' => array(),
4187
+ 'AMP_Playbuzz_Sanitizer' => array(),
4188
+ 'AMP_Iframe_Sanitizer' => array(
4189
+ 'add_placeholder' => true,
4190
+ ),
4191
+ ) ) );
4192
+ $content = $sanitizer_obj->get_amp_content();
4193
+ $queried_var = get_query_var('paged');
4194
+ $con = explode("<!--nextpage-->", $content);
4195
+ if($queried_var>=2){
4196
+ if(isset($con[$queried_var-1])){
4197
+ $content = $con[$queried_var-1];
4198
+ }
4199
+ }
4200
+ }
4201
  $ampforwp_the_content = $content;
4202
  $checker = preg_match('/<!--nextpage-->/', $ampforwp_the_content);
4203
  if ( 1 === $checker && true == ampforwp_get_setting('amp-pagination') ) {
4218
  else {
4219
  return $ampforwp_the_content;
4220
  }
4221
+ }
4222
  }
4223
  return $content;
4224
  }
6113
  if(get_query_var( 'robots' )){
6114
  return;
6115
  }
6116
+ if ( function_exists('is_embed') && is_embed() ){
6117
+ return;
6118
+ }
6119
  if(is_search() && 0 == ampforwp_get_setting('amp-redirection-search')){
6120
  return false;
6121
  }
9113
  .amp-video-box{max-width:800px}
9114
  .amp-video-img{max-width:600px;position:relative}
9115
  .amp-video-play-on-image{cursor:pointer;margin:auto;width:56px;height:56px;-webkit-border-radius:50%;border-radius:50%;background-color:rgba(0,0,0,.2);background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGAAAABgCAMAAADVRocKAAAAY1BMVEVHcEz///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////80LMUcAAAAIHRSTlMA1d4MSXeg9glf6yEq4hfnnr7Z8qm5U/3Jm1pwFJcmBYTgJ9QAAAIjSURBVGje7VnJdoMwDFSMHVMSQljCklX//5U99NQHGEm22gtz9tPAWNYKsGPHDiou1h3rpvDD4Iumvjp7SWg86yeDM5ipz5KYt53HFfjORn+8KzEI88iizLe4icLlUvtfFZJQ3kXmTzWScTsJPr9FBtovpvn8iExMrJu4jMjGyHh67xIFMOSLOFcoQnUmfr/QPmL1JulfohiGcA/5iBEYt33piFG4br4vjMTGizu1sQRt2FlrjMZNVSBExEBszaoUBOW6JzlMArf6A0XIOzyZoMgkPwDnA5nhsWz/E4wRnBxhVuoTDBMAkGVarma6TQKyTN3iFfttAqJMg1/y1B4JBFSZ+gWCiUZAk+m1QGCIBCSZmoVEhlQCkkxPppP+JiDIZNlxiFmYOXaqnEX2sEwTO9XMq6egTPXsfMMlCMt0mB0v2ARBmYrZYS8gCMjkZ2cHCcG6TMPfE6hLpH7J6m6a+KHN67urdqhQD3bq4Vo94ainTP2kn7RssbqFF7a5buk4dP9T/Ib9KEH5Dg/lBkS/hVJvAiEvU9gPtLFwT0HQh1r9m/IoQX8YEj+t2JwCX+PsT7ojtWH8EIaCJmIo+FQeaxJHs9LBbPkGIt4ilQxjxi8ajj+BgZztra8P8MBcUAi2LCdGXJKsWADgTozeppeuoXJXEPKXfM0FANnDaC7qtlaNbfyq8Uep/rXQYDUvm0M6XKyb6sPPuvdwm5x9wo4dO6j4BoilN6H4pmTiAAAAAElFTkSuQmCC);background-position:center;-webkit-background-size:48px 48px;background-size:48px 48px;position:absolute;top:0;bottom:0;left:0;right:0}';
9116
+ }
9117
+ function ampforwp_admin_discount_btn() {
9118
+ if(! current_user_can( 'manage_options' )) {
9119
+ return ;
9120
+ }
9121
+ $screen = get_current_screen();
9122
+ $result = get_option( "ampforwp_dismiss_discount_btn");
9123
+ $date_now = new DateTime();
9124
+ $date_exp = new DateTime("02/12/2020");
9125
+ if ($result != 'removed' && ($date_now > $date_exp) && ('toplevel_page_amp_options' == $screen->base || 'dashboard' == $screen->base || 'plugins' == $screen->base)) {
9126
+ $date = date('d-m-y');
9127
+ if ($date == '01-12-20') {
9128
+ $msg = 'Only 24 Hours Remaining';
9129
+ $img = AMPFORWP_IMAGE_DIR . '/last-chance.png';
9130
+ $class_img = 'offer-img-24';
9131
+ $class_text = 'offer-text-bm-24';
9132
+ }else{
9133
+ $msg = 'Black Friday &amp; Cyber Monday';
9134
+ $img = AMPFORWP_IMAGE_DIR . '/bf-offer.png';
9135
+ $class_img = 'offer-img';
9136
+ $class_text = 'offer-text-bm';
9137
+ }
9138
+ $href = admin_url('admin.php?page=amp_options&tab=31');
9139
+ if (ampforwp_check_extensions()) {
9140
+ $href = 'https://ampforwp.com/festive-season/';
9141
+ }
9142
+ ?>
9143
+ <div class="wrapper-discount">
9144
+ <a class="admin_discount_btn" target="_blank" href="<?php echo esc_url_raw($href) ?>">
9145
+ <img src="<?php echo esc_url($img) ?>" class="<?php echo esc_attr($class_img) ?>" >
9146
+ <span class="offer-text-top" ><?php echo esc_html($msg) ?></span><br><span class="<?php echo esc_html($class_text) ?>">50% OFF on AMPforWP</span></a>
9147
+ <span id='amp-close'>x</span></div>
9148
+ <?php } }
9149
+ add_action('admin_footer', 'ampforwp_admin_discount_btn');
9150
+
9151
+ function ampforwp_dismiss_discount_btn(){
9152
+ if(! current_user_can( 'manage_options' )) {
9153
+ return ;
9154
+ }
9155
+ $result = update_option( "ampforwp_dismiss_discount_btn", 'removed');
9156
+ if($result){
9157
+ echo json_encode(array('status'=>'t'));
9158
+ }else{
9159
+ echo json_encode(array('status'=>'f'));
9160
+ }
9161
+ wp_die();
9162
+ }
9163
+ add_action('wp_ajax_ampforwp_dismiss_discount_btn', 'ampforwp_dismiss_discount_btn');