AdSense Plugin WP QUADS - Version 2.0.8.2

Version Description

Download this release

Release Info

Developer wpquads
Plugin Icon 128x128 AdSense Plugin WP QUADS
Version 2.0.8.2
Comparing to
See all releases

Code changes from version 2.0.8.1 to 2.0.8.2

includes/render-ad-functions.php CHANGED
@@ -787,13 +787,20 @@ function quads_render_amp($id,$ampsupport=''){
787
  if ( !quads_is_extra() ){
788
  return '';
789
  }
790
- if(isset($quads_options['ads'][$id]['amp']) && isset($quads_options['ads'][$id]['code']) && !empty($quads_options['ads'][$id]['code'])){
791
- return $quads_options['ads'][$id]['code'];
792
- }
793
  // if amp is not activated return empty
794
  if (!isset($quads_options['ads'][$id]['amp']) || quads_is_disabled_post_amp() ){
795
  return '';
796
  }
 
 
 
 
 
 
 
 
 
 
797
  }else{
798
 
799
  if((isset($quads_options['ads'][$id]['enabled_on_amp']) && isset($quads_options['ads'][$id]['code']) && !empty($quads_options['ads'][$id]['code']))|| (!empty($ampsupport) && $ampsupport)){
@@ -810,13 +817,10 @@ function quads_render_amp($id,$ampsupport=''){
810
  }
811
  }
812
  // if amp is not activated return empty
813
- if (!isset($quads_options['ads'][$id]['enabled_on_amp']) || quads_is_disabled_post_amp() ){
814
  return '';
815
  }
816
- }
817
- if (!empty($quads_options['ads'][$id]['amp_code'])){
818
- $html = $quads_options['ads'][$id]['amp_code'];
819
- } else {
820
  if($quads_options['ads'][$id]['ad_type'] == 'double_click'){
821
  $width = (isset($quads_options['ads'][$id]['g_data_ad_width']) && !empty($quads_options['ads'][$id]['g_data_ad_width'])) ? $quads_options['ads'][$id]['g_data_ad_width'] : '300';
822
  $height = (isset($quads_options['ads'][$id]['g_data_ad_height']) && !empty($quads_options['ads'][$id]['g_data_ad_height'])) ? $quads_options['ads'][$id]['g_data_ad_height'] : '250';
787
  if ( !quads_is_extra() ){
788
  return '';
789
  }
 
 
 
790
  // if amp is not activated return empty
791
  if (!isset($quads_options['ads'][$id]['amp']) || quads_is_disabled_post_amp() ){
792
  return '';
793
  }
794
+ // if having amp code
795
+ if(!empty($quads_options['ads'][$id]['amp_code'])){
796
+ return $quads_options['ads'][$id]['amp_code'];
797
+ }
798
+ if($quads_options['ads'][$id]['ad_type']=='plain_text'){
799
+ return $quads_options['ads'][$id]['code'];
800
+ }else{
801
+ return '<amp-ad layout="responsive" width=300 height=250 type="adsense" data-ad-client="'. esc_attr($quads_options['ads'][$id]['g_data_ad_client']) . '" data-ad-slot="'.esc_attr($quads_options['ads'][$id]['g_data_ad_slot']).'"></amp-ad>';
802
+ }
803
+
804
  }else{
805
 
806
  if((isset($quads_options['ads'][$id]['enabled_on_amp']) && isset($quads_options['ads'][$id]['code']) && !empty($quads_options['ads'][$id]['code']))|| (!empty($ampsupport) && $ampsupport)){
817
  }
818
  }
819
  // if amp is not activated return empty
820
+ if (!isset($quads_options['ads'][$id]['enabled_on_amp']) ){
821
  return '';
822
  }
823
+
 
 
 
824
  if($quads_options['ads'][$id]['ad_type'] == 'double_click'){
825
  $width = (isset($quads_options['ads'][$id]['g_data_ad_width']) && !empty($quads_options['ads'][$id]['g_data_ad_width'])) ? $quads_options['ads'][$id]['g_data_ad_width'] : '300';
826
  $height = (isset($quads_options['ads'][$id]['g_data_ad_height']) && !empty($quads_options['ads'][$id]['g_data_ad_height'])) ? $quads_options['ads'][$id]['g_data_ad_height'] : '250';
package.json CHANGED
@@ -1,6 +1,6 @@
1
  {
2
  "name": "quick-adsense-reloaded",
3
- "version": "2.0.8.1",
4
  "devDependencies": {
5
  "grunt": "~0.4.5",
6
  "grunt-contrib-clean": "~0.6.0",
1
  {
2
  "name": "quick-adsense-reloaded",
3
+ "version": "2.0.8.2",
4
  "devDependencies": {
5
  "grunt": "~0.4.5",
6
  "grunt-contrib-clean": "~0.6.0",
quick-adsense-reloaded.php CHANGED
@@ -6,7 +6,7 @@
6
  * Description: Insert Google AdSense and other ad formats fully automatic into your website
7
  * Author: WP Quads
8
  * Author URI: https://wordpress.org/plugins/quick-adsense-reloaded/
9
- * Version: 2.0.8.1
10
  * Text Domain: quick-adsense-reloaded
11
  * Domain Path: languages
12
  * Credits: WP QUADS - Quick AdSense Reloaded is a fork of Quick AdSense
@@ -38,7 +38,7 @@ if( !defined( 'ABSPATH' ) )
38
 
39
  // Plugin version
40
  if( !defined( 'QUADS_VERSION' ) ) {
41
- define( 'QUADS_VERSION', '2.0.8.1' );
42
  }
43
 
44
  // Plugin name
6
  * Description: Insert Google AdSense and other ad formats fully automatic into your website
7
  * Author: WP Quads
8
  * Author URI: https://wordpress.org/plugins/quick-adsense-reloaded/
9
+ * Version: 2.0.8.2
10
  * Text Domain: quick-adsense-reloaded
11
  * Domain Path: languages
12
  * Credits: WP QUADS - Quick AdSense Reloaded is a fork of Quick AdSense
38
 
39
  // Plugin version
40
  if( !defined( 'QUADS_VERSION' ) ) {
41
+ define( 'QUADS_VERSION', '2.0.8.2' );
42
  }
43
 
44
  // Plugin name
readme.txt CHANGED
@@ -8,9 +8,9 @@ License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
  Tags: adsense, ads, ad, google adsense, advertising, amp, ad injection, ad inserter, ad manager
10
  Requires at least: 3.6+
11
- Tested up to: 5.4
12
  Requires PHP: 5.3
13
- Stable tag: 2.0.8.1
14
 
15
  Ads & AdSense Plugin is the quickest way to insert Google AdSense & other ads into your website. Google AdSense integration with Google AMP support.
16
 
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
  Tags: adsense, ads, ad, google adsense, advertising, amp, ad injection, ad inserter, ad manager
10
  Requires at least: 3.6+
11
+ Tested up to: 5.4.2
12
  Requires PHP: 5.3
13
+ Stable tag: 2.0.8.2
14
 
15
  Ads & AdSense Plugin is the quickest way to insert Google AdSense & other ads into your website. Google AdSense integration with Google AMP support.
16