AMP for WP – Accelerated Mobile Pages - Version 1.0.77.4

Version Description

(1st June 2021) = * Improvements: Added dynamic copyright code so that year changes automatically #5019 * Improvements: Added Smart Sticky Header Extension #5001 * Fixed: View Non-amp version link redirecting to 404 using custom permalink #5039 * Fixed: Headline error in schema when adding more than 110 characters in title #5033 * Fixed: Aq_resize.process() error in error logs #5041 * Fixed: Google Fonts are not getting saved while using Safari #4978 * Fixed: The tag 'animatetransform' is disallowed validation error #5043 * Fixed: Debug Warning Function get_magic_quotes_gpc() is deprecated #5035 * Fixed: Debug Warning Trying to get property 'ID' of non-object #5046

Download this release

Release Info

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

Code changes from version 1.0.77.3 to 1.0.77.4

README.md CHANGED
@@ -4,7 +4,7 @@ Tags: AMP, accelerated mobile pages, mobile, amp project, google amp, amp wp, go
4
  Donate link: https://www.paypal.me/Kaludi/25
5
  Requires at least: 3.0
6
  Tested up to: 5.7
7
- Stable tag: 1.0.77.3
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -193,6 +193,17 @@ Device testing done through [BrowserStack](https://www.browserstack.com)
193
 
194
  == Changelog ==
195
 
 
 
 
 
 
 
 
 
 
 
 
196
  = 1.0.77.3 (27th May 2021) =
197
  * Improvements: Added Compatibility with WebP Express plugin #4357
198
  * Improvements: Added an option to allow users to upload and use local fonts on AMP #4264
@@ -208,12 +219,4 @@ Device testing done through [BrowserStack](https://www.browserstack.com)
208
  = 1.0.77.2 (20th May 2021) =
209
  * Fixed: Some issues with style on normal version after update #3844
210
 
211
- = 1.0.77.1 (19th May 2021) =
212
- * Improvements: Added a filter from which user can control Mobile redirection #4488
213
- * Improvements: Implemented the Mobile redirection functionality using Javascript method #3844
214
- * Improvements: Added preload to get featured image on AMP #5020
215
- * Fixed: Debug Warning in templates/features.php #5014
216
- * Fixed: Validation error in image lightbox for gallery #5021
217
- * Fixed: Fatal error on AMP pages after updating WP User Avatar plugin #5029
218
-
219
  Full changelog available [ at changelog.txt](https://plugins.svn.wordpress.org/accelerated-mobile-pages/trunk/changelog.txt)
4
  Donate link: https://www.paypal.me/Kaludi/25
5
  Requires at least: 3.0
6
  Tested up to: 5.7
7
+ Stable tag: 1.0.77.4
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.77.4 (1st June 2021) =
197
+ * Improvements: Added dynamic copyright code so that year changes automatically #5019
198
+ * Improvements: Added Smart Sticky Header Extension #5001
199
+ * Fixed: View Non-amp version link redirecting to 404 using custom permalink #5039
200
+ * Fixed: Headline error in schema when adding more than 110 characters in title #5033
201
+ * Fixed: Aq_resize.process() error in error logs #5041
202
+ * Fixed: Google Fonts are not getting saved while using Safari #4978
203
+ * Fixed: The tag 'animatetransform' is disallowed validation error #5043
204
+ * Fixed: Debug Warning Function get_magic_quotes_gpc() is deprecated #5035
205
+ * Fixed: Debug Warning Trying to get property 'ID' of non-object #5046
206
+
207
  = 1.0.77.3 (27th May 2021) =
208
  * Improvements: Added Compatibility with WebP Express plugin #4357
209
  * Improvements: Added an option to allow users to upload and use local fonts on AMP #4264
219
  = 1.0.77.2 (20th May 2021) =
220
  * Fixed: Some issues with style on normal version after update #3844
221
 
 
 
 
 
 
 
 
 
222
  Full changelog available [ at changelog.txt](https://plugins.svn.wordpress.org/accelerated-mobile-pages/trunk/changelog.txt)
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.77.3
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.77.3');
24
  define('AMPFORWP_EXTENSION_DIR',plugin_dir_path(__FILE__).'includes/options/extensions');
25
  if(!defined('AMPFROWP_HOST_NAME')){
26
  $urlinfo = get_bloginfo('url');
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.77.4
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.77.4');
24
  define('AMPFORWP_EXTENSION_DIR',plugin_dir_path(__FILE__).'includes/options/extensions');
25
  if(!defined('AMPFROWP_HOST_NAME')){
26
  $urlinfo = get_bloginfo('url');
changelog.txt CHANGED
@@ -1,5 +1,16 @@
1
  == Changelog ==
2
 
 
 
 
 
 
 
 
 
 
 
 
3
  = 1.0.77.3 (27th May 2021) =
4
  * Improvements: Added Compatibility with WebP Express plugin #4357
5
  * Improvements: Added an option to allow users to upload and use local fonts on AMP #4264
1
  == Changelog ==
2
 
3
+ = 1.0.77.4 (1st June 2021) =
4
+ * Improvements: Added dynamic copyright code so that year changes automatically #5019
5
+ * Improvements: Added Smart Sticky Header Extension #5001
6
+ * Fixed: View Non-amp version link redirecting to 404 using custom permalink #5039
7
+ * Fixed: Headline error in schema when adding more than 110 characters in title #5033
8
+ * Fixed: Aq_resize.process() error in error logs #5041
9
+ * Fixed: Google Fonts are not getting saved while using Safari #4978
10
+ * Fixed: The tag 'animatetransform' is disallowed validation error #5043
11
+ * Fixed: Debug Warning Function get_magic_quotes_gpc() is deprecated #5035
12
+ * Fixed: Debug Warning Trying to get property 'ID' of non-object #5046
13
+
14
  = 1.0.77.3 (27th May 2021) =
15
  * Improvements: Added Compatibility with WebP Express plugin #4357
16
  * Improvements: Added an option to allow users to upload and use local fonts on AMP #4264
components/components-core.php CHANGED
@@ -466,7 +466,7 @@ function amp_non_amp_link(){
466
  if (function_exists('pll__')) {
467
  echo '<span>' . strip_tags(pll__(ampforwp_get_setting('amp-translator-footer-text'),'All Rights Reserved'),$allowed_tags) . '</span>';
468
  }else {
469
- echo '<span>' . strip_tags(ampforwp_translation(ampforwp_get_setting('amp-translator-footer-text'),'All Rights Reserved'),$allowed_tags) . '</span>';
470
  }
471
  if(ampforwp_get_setting('amp-footer-link-non-amp-page')=='1') { ampforwp_view_nonamp(); }
472
  }
466
  if (function_exists('pll__')) {
467
  echo '<span>' . strip_tags(pll__(ampforwp_get_setting('amp-translator-footer-text'),'All Rights Reserved'),$allowed_tags) . '</span>';
468
  }else {
469
+ echo '<span>' . strip_tags(ampforwp_translation(do_shortcode(ampforwp_get_setting('amp-translator-footer-text')),'All Rights Reserved'),$allowed_tags) . '</span>';
470
  }
471
  if(ampforwp_get_setting('amp-footer-link-non-amp-page')=='1') { ampforwp_view_nonamp(); }
472
  }
images/Sticky_Header.png ADDED
Binary file
includes/admin-script.js CHANGED
@@ -475,11 +475,15 @@ jQuery(function($) {
475
 
476
  // Creating a select
477
  var s = $('<select/>');
478
-
479
  for (var i in allFonts) {
480
 
481
  var fontDetail = allFonts[i].fontFamily;
482
-
 
 
 
 
483
  $('#amp_font_selector-select').append($('<option value="'+ fontDetail +'" data-font-number="'+ i +'"> '+ fontDetail +' </option>'));
484
  $('#amp_font_selector_content_single-select').append($('<option value="'+ fontDetail +'" data-font-number="'+ i +'"> '+ fontDetail +' </option>'));
485
  }
475
 
476
  // Creating a select
477
  var s = $('<select/>');
478
+ var amp_font_selector = redux_data['amp_font_selector'];
479
  for (var i in allFonts) {
480
 
481
  var fontDetail = allFonts[i].fontFamily;
482
+ var selected = '';
483
+ if(amp_font_selector===fontDetail){
484
+ selected = 'selected';
485
+ }
486
+ $('#amp_font_selector-select').append($('<option value="'+ fontDetail +'" data-font-number="'+ i +'" '+ selected +'> '+ fontDetail +' </option>'));
487
  $('#amp_font_selector-select').append($('<option value="'+ fontDetail +'" data-font-number="'+ i +'"> '+ fontDetail +' </option>'));
488
  $('#amp_font_selector_content_single-select').append($('<option value="'+ fontDetail +'" data-font-number="'+ i +'"> '+ fontDetail +' </option>'));
489
  }
includes/features/performance/performance-functions.php CHANGED
@@ -69,6 +69,9 @@ function ampforwp_minify_html_output($content_buffer){
69
  $mfn_content = str_replace("img", 'amp-img', $match);
70
  $content_buffer = preg_replace('/<div\sclass="section mcb-section(.*?)<div class="amp-wp-content">/s', $mfn_content , $content_buffer);
71
  }
 
 
 
72
  global $redux_builder_amp;
73
  if(!$redux_builder_amp['ampforwp_cache_minimize_mode']){
74
  return $content_buffer;
69
  $mfn_content = str_replace("img", 'amp-img', $match);
70
  $content_buffer = preg_replace('/<div\sclass="section mcb-section(.*?)<div class="amp-wp-content">/s', $mfn_content , $content_buffer);
71
  }
72
+ if(preg_match('/<animatetransform(.*?)<\/animatetransform>/', $content_buffer)){
73
+ $content_buffer = preg_replace('/<animatetransform(.*?)<\/animatetransform>/', '', $content_buffer);
74
+ }
75
  global $redux_builder_amp;
76
  if(!$redux_builder_amp['ampforwp_cache_minimize_mode']){
77
  return $content_buffer;
includes/options/admin-config.php CHANGED
@@ -699,6 +699,18 @@ $extension_listing_array = array(
699
  'store_url'=>'https://accounts.ampforwp.com',
700
  'is_activated'=>(is_plugin_active('forminator-for-amp/forminator-for-amp.php')? 1 : 2),
701
  ),
 
 
 
 
 
 
 
 
 
 
 
 
702
  array(
703
  'name'=>'Happyforms for AMP',
704
  'class'=>'new-ext',
@@ -3526,7 +3538,9 @@ $e_commerce_support[] = array(
3526
  'title' => esc_html__('Footer', 'accelerated-mobile-pages'),
3527
  'default' => esc_html__('All Rights Reserved','accelerated-mobile-pages'),
3528
  'placeholder'=>esc_html__('write here','accelerated-mobile-pages'),
3529
- 'required' => array( 'amp-use-pot', '=' , 0 )
 
 
3530
  ),
3531
  array(
3532
  'id' => 'amp-translator-categories-text',
699
  'store_url'=>'https://accounts.ampforwp.com',
700
  'is_activated'=>(is_plugin_active('forminator-for-amp/forminator-for-amp.php')? 1 : 2),
701
  ),
702
+ array(
703
+ 'name'=>'Smart Sticky Header for AMP',
704
+ 'class'=>'new-ext',
705
+ 'desc'=>'Adds Smart Sticky Header in AMP',
706
+ 'img_src'=>AMPFORWP_IMAGE_DIR . '/Sticky_Header.png',
707
+ 'price'=>'$19',
708
+ 'url_link'=>'https://ampforwp.com/addons/smart-sticky-header-for-amp/',
709
+ 'plugin_active_path'=> 'smart-sticky-header-for-amp/smart-sticky-header-for-amp.php',
710
+ 'item_name'=>'Smart Sticky Header for AMP',
711
+ 'store_url'=>'https://accounts.ampforwp.com',
712
+ 'is_activated'=>(is_plugin_active('smart-sticky-header-for-amp/smart-sticky-header-for-amp.php')? 1 : 2),
713
+ ),
714
  array(
715
  'name'=>'Happyforms for AMP',
716
  'class'=>'new-ext',
3538
  'title' => esc_html__('Footer', 'accelerated-mobile-pages'),
3539
  'default' => esc_html__('All Rights Reserved','accelerated-mobile-pages'),
3540
  'placeholder'=>esc_html__('write here','accelerated-mobile-pages'),
3541
+ 'required' => array( 'amp-use-pot', '=' , 0 ),
3542
+ 'tooltip-subtitle' => sprintf('%s <a href="%s" target="_blank">%s</a> %s',
3543
+ esc_html__('If you want to add the current year then use this shortcode [ampforwp_current_year] and', 'accelerated-mobile-pages'), esc_url('https://ampforwp.com/tutorials/article/how-to-add-current-year-in-amp-footer/'),esc_html__('Click Here','accelerated-mobile-pages'), esc_html__('for more info','accelerated-mobile-pages')),
3544
  ),
3545
  array(
3546
  'id' => 'amp-translator-categories-text',
includes/options/redux-core/framework.php CHANGED
@@ -2846,9 +2846,12 @@
2846
 
2847
  $values = $values[ $redux->args['opt_name'] ];
2848
 
2849
- if ( function_exists( 'get_magic_quotes_gpc' ) && get_magic_quotes_gpc() ) {
2850
  $values = array_map( 'stripslashes_deep', $values );
2851
  }
 
 
 
2852
 
2853
  if ( ! empty ( $values ) ) {
2854
 
2846
 
2847
  $values = $values[ $redux->args['opt_name'] ];
2848
 
2849
+ if ( version_compare( PHP_VERSION, '7.4', '<' ) && function_exists( 'get_magic_quotes_gpc' ) && get_magic_quotes_gpc() ) {
2850
  $values = array_map( 'stripslashes_deep', $values );
2851
  }
2852
+ else{
2853
+ $values = stripslashes_deep($values);
2854
+ }
2855
 
2856
  if ( ! empty ( $values ) ) {
2857
 
includes/vendor/amp/includes/class-amp-post-template.php CHANGED
@@ -201,6 +201,10 @@ class AMP_Post_Template {
201
  $post_author_image = get_avatar_url($post_author->ID, array('size' => 50));
202
  }
203
  }
 
 
 
 
204
  $this->add_data( array(
205
  'post' => $this->post,
206
  'post_id' => $this->ID,
@@ -218,7 +222,7 @@ class AMP_Post_Template {
218
  '@type' => 'Organization',
219
  'name' => $this->get( 'blog_name' ),
220
  ),
221
- 'headline' => $post_title,
222
  'author' => array(
223
  '@type' => 'Person',
224
  'name' => $post_author_name,
201
  $post_author_image = get_avatar_url($post_author->ID, array('size' => 50));
202
  }
203
  }
204
+ $headline_str = $post_title;
205
+ if (strlen($headline_str) > 110){
206
+ $headline_str = substr($post_title,0,107) . '...';
207
+ }
208
  $this->add_data( array(
209
  'post' => $this->post,
210
  'post_id' => $this->ID,
222
  '@type' => 'Organization',
223
  'name' => $this->get( 'blog_name' ),
224
  ),
225
+ 'headline' => $headline_str,
226
  'author' => array(
227
  '@type' => 'Person',
228
  'name' => $post_author_name,
includes/vendor/aq_resizer.php CHANGED
@@ -286,6 +286,9 @@ if(!function_exists('ampforwp_aq_resize')) {
286
  * need to change any code in your own WP themes. Usage is still the same :)
287
  */
288
  function ampforwp_aq_resize( $url, $width = null, $height = null, $crop = null, $single = true, $upscale = false ) {
 
 
 
289
  // Disable ampforwp_aq_resize and return images without compressing.
290
  // Useful for some who wants to disable when using CDN images
291
  $disable_aq_resize = false;
286
  * need to change any code in your own WP themes. Usage is still the same :)
287
  */
288
  function ampforwp_aq_resize( $url, $width = null, $height = null, $crop = null, $single = true, $upscale = false ) {
289
+ if (empty($url)) {
290
+ return;
291
+ }
292
  // Disable ampforwp_aq_resize and return images without compressing.
293
  // Useful for some who wants to disable when using CDN images
294
  $disable_aq_resize = false;
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: AMP, accelerated mobile pages, mobile, amp project, google amp, amp wp, go
4
  Donate link: https://www.paypal.me/Kaludi/25
5
  Requires at least: 3.0
6
  Tested up to: 5.7
7
- Stable tag: 1.0.77.3
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -190,6 +190,17 @@ You can contact us from [here](https://ampforwp.com/contact/)
190
 
191
  == Changelog ==
192
 
 
 
 
 
 
 
 
 
 
 
 
193
  = 1.0.77.3 (27th May 2021) =
194
  * Improvements: Added Compatibility with WebP Express plugin #4357
195
  * Improvements: Added an option to allow users to upload and use local fonts on AMP #4264
@@ -205,12 +216,4 @@ You can contact us from [here](https://ampforwp.com/contact/)
205
  = 1.0.77.2 (20th May 2021) =
206
  * Fixed: Some issues with style on normal version after update #3844
207
 
208
- = 1.0.77.1 (19th May 2021) =
209
- * Improvements: Added a filter from which user can control Mobile redirection #4488
210
- * Improvements: Implemented the Mobile redirection functionality using Javascript method #3844
211
- * Improvements: Added preload to get featured image on AMP #5020
212
- * Fixed: Debug Warning in templates/features.php #5014
213
- * Fixed: Validation error in image lightbox for gallery #5021
214
- * Fixed: Fatal error on AMP pages after updating WP User Avatar plugin #5029
215
-
216
  Full changelog available [ at changelog.txt](https://plugins.svn.wordpress.org/accelerated-mobile-pages/trunk/changelog.txt)
4
  Donate link: https://www.paypal.me/Kaludi/25
5
  Requires at least: 3.0
6
  Tested up to: 5.7
7
+ Stable tag: 1.0.77.4
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.77.4 (1st June 2021) =
194
+ * Improvements: Added dynamic copyright code so that year changes automatically #5019
195
+ * Improvements: Added Smart Sticky Header Extension #5001
196
+ * Fixed: View Non-amp version link redirecting to 404 using custom permalink #5039
197
+ * Fixed: Headline error in schema when adding more than 110 characters in title #5033
198
+ * Fixed: Aq_resize.process() error in error logs #5041
199
+ * Fixed: Google Fonts are not getting saved while using Safari #4978
200
+ * Fixed: The tag 'animatetransform' is disallowed validation error #5043
201
+ * Fixed: Debug Warning Function get_magic_quotes_gpc() is deprecated #5035
202
+ * Fixed: Debug Warning Trying to get property 'ID' of non-object #5046
203
+
204
  = 1.0.77.3 (27th May 2021) =
205
  * Improvements: Added Compatibility with WebP Express plugin #4357
206
  * Improvements: Added an option to allow users to upload and use local fonts on AMP #4264
216
  = 1.0.77.2 (20th May 2021) =
217
  * Fixed: Some issues with style on normal version after update #3844
218
 
 
 
 
 
 
 
 
 
219
  Full changelog available [ at changelog.txt](https://plugins.svn.wordpress.org/accelerated-mobile-pages/trunk/changelog.txt)
templates/design-manager/design-2/style.php CHANGED
@@ -13,7 +13,7 @@ global $redux_builder_amp;
13
  global $redux_builder_amp;
14
  global $post;
15
  $post_id = '';
16
- $post_id = $post->ID;
17
  $get_customizer = new AMP_Post_Template( $post_id );
18
  // Get content width
19
  $content_max_width = absint( $get_customizer->get( 'content_max_width' ) );
13
  global $redux_builder_amp;
14
  global $post;
15
  $post_id = '';
16
+ $post_id = ampforwp_get_the_ID();
17
  $get_customizer = new AMP_Post_Template( $post_id );
18
  // Get content width
19
  $content_max_width = absint( $get_customizer->get( 'content_max_width' ) );
templates/features.php CHANGED
@@ -4002,7 +4002,10 @@ function ampforwp_view_nonamp(){
4002
  if ( true == ampforwp_get_setting('ampforwp-amp-takeover') || $mob_pres_link == true) {
4003
  $non_amp_url = '';
4004
  }
4005
-
 
 
 
4006
  if ( $non_amp_url ) { ?><a class="view-non-amp" href="<?php echo esc_url(apply_filters('ampforwp_view_nonamp_url', $non_amp_url) ) ?>" <?php echo esc_attr($nofollow); ?> title="<?php echo ampforwp_get_setting('amp-translator-non-amp-page-text') ?>"><?php if(function_exists('pll__')){echo pll__(esc_html__( ampforwp_get_setting('amp-translator-non-amp-page-text'), 'accelerated-mobile-pages'));}else{echo esc_html__( ampforwp_get_setting('amp-translator-non-amp-page-text'), 'accelerated-mobile-pages');}?></a> <?php }
4007
  }
4008
 
@@ -9603,4 +9606,10 @@ if(!function_exists('ampforwp_set_local_font')){
9603
  }
9604
  }
9605
  }
9606
- }
 
 
 
 
 
 
4002
  if ( true == ampforwp_get_setting('ampforwp-amp-takeover') || $mob_pres_link == true) {
4003
  $non_amp_url = '';
4004
  }
4005
+ $permalink = get_option('permalink_structure');
4006
+ if(strpos($permalink, '/%year%/%monthnum%/%day%/%postname%/') !== false){
4007
+ $non_amp_url = get_permalink(ampforwp_get_the_ID());
4008
+ }
4009
  if ( $non_amp_url ) { ?><a class="view-non-amp" href="<?php echo esc_url(apply_filters('ampforwp_view_nonamp_url', $non_amp_url) ) ?>" <?php echo esc_attr($nofollow); ?> title="<?php echo ampforwp_get_setting('amp-translator-non-amp-page-text') ?>"><?php if(function_exists('pll__')){echo pll__(esc_html__( ampforwp_get_setting('amp-translator-non-amp-page-text'), 'accelerated-mobile-pages'));}else{echo esc_html__( ampforwp_get_setting('amp-translator-non-amp-page-text'), 'accelerated-mobile-pages');}?></a> <?php }
4010
  }
4011
 
9606
  }
9607
  }
9608
  }
9609
+ }
9610
+
9611
+ function ampforwp_year_shortcode() {
9612
+ $year = date('Y');
9613
+ return $year;
9614
+ }
9615
+ add_shortcode('ampforwp_current_year', 'ampforwp_year_shortcode');