AdSense Plugin WP QUADS - Version 1.8.4

Version Description

  • Fix: Fatal error if Gutenberg is disabled
Download this release

Release Info

Developer ReneHermi
Plugin Icon 128x128 AdSense Plugin WP QUADS
Version 1.8.4
Comparing to
See all releases

Code changes from version 1.8.3 to 1.8.4

Files changed (3) hide show
  1. includes/scripts.php +38 -38
  2. quick-adsense-reloaded.php +2 -2
  3. readme.txt +9 -18
includes/scripts.php CHANGED
@@ -141,17 +141,17 @@ function quads_load_all_admin_scripts( $hook ) {
141
  /**
142
  * Create Gutenberg block
143
  */
144
- function quads_load_blocks() {
145
- $js_dir = QUADS_PLUGIN_URL . 'assets/js/';
146
-
147
- wp_register_script( 'wpquads', $js_dir . 'blocks.js', array('wp-blocks', 'wp-element', 'wp-editor') );
148
-
149
- register_block_type( 'wpquads/blocks', array(
150
- 'editor_script' => 'wpquads',
151
- ) );
152
- }
153
-
154
- add_action( 'init', 'quads_load_blocks' );
155
 
156
 
157
  /**
@@ -264,45 +264,45 @@ function quads_ads_head_script() {
264
  if( isset( $quads_options['quicktags']['QckTags'] ) ) {
265
  ?>
266
  <script type="text/javascript">
267
- wpvcomp = <?php echo (($wpvcomp == 1) ? "true " : "false"); ?>;
268
- edaddID = new Array();
269
- edaddNm = new Array();
270
- if (typeof (edButtons) != 'undefined') {
271
- edadd = edButtons.length;
272
- var dynads = {"all":[
273
  <?php
274
  for ( $i = 1; $i <= count( quads_get_ads() ) - 1; $i++ ) {
275
  if( isset( $quads_options['ads']['ad' . $i]['code'] ) && $quads_options['ads']['ad' . $i]['code'] != '' ) {
276
- echo('" 1",');
277
  } else {
278
  echo('"0",');
279
  };
280
  }
281
  ?>
282
- " 0 "] };
283
- for (i = 1; i <=<?php echo count( quads_get_ads() ) - 1; ?>; i++) { i f (dynads.all[ i - 1 ] == "1") {
284
- edButtons [ edButtons.le n gth] = n ew edB u tton("ads" + i.toString(), "Ads" + i.toString(), "\n<!--Ads"+i.toSt r ing()+"-->\n", "", "", - 1);
285
- edaddID[eda d dID.length] = " ads" + i.t oString();
286
- edaddNm[edaddNm.length] ="Ads" + i.toString();
287
- }
288
- }
 
289
  <?php if( !isset( $quads_options['quicktags']['QckRnds'] ) ) { ?>
290
- edButtons[edButtons.length] = n e w edButton("random_ads", " RndAds", "\n<!--RndAds-->\n", "", "", - 1);
291
- edaddID[edaddID.length] = "random_ads";
292
- edaddNm[edaddNm.length] = "RndAds";
293
  <?php } ?>
294
- edButtons[edButtons.length] = new edButton("no_ads", "NoAds", "\n<!--NoAds-->\n","","",-1);
295
- edaddID[edaddID.length] = "no_ads";
296
- edaddNm[edaddNm.length] = "NoAds";
297
  };
298
  (function(){
299
- if(typeof(edButtons)!='undefined' && typeof(jQuery)!='undefined' && wpvcomp){
300
- jQuery(document).ready(function(){
301
- for(i=0;i<edaddID.length;i++) {
302
- jQuery("#ed_toolbar").append('<input type="button" value="' + edaddNm[i] +'" id="' + edaddID[i] +'" class="ed_button" onclick="edInsertTag(edCanvas, ' + (edadd+i) + ');" title="' + edaddNm[i] +'" />');
303
- }
304
- });
305
- }
306
  }());
307
  </script>
308
  <?php
141
  /**
142
  * Create Gutenberg block
143
  */
144
+ //function quads_load_blocks() {
145
+ // $js_dir = QUADS_PLUGIN_URL . 'assets/js/';
146
+ //
147
+ // wp_register_script( 'wpquads', $js_dir . 'blocks.js', array('wp-blocks', 'wp-element', 'wp-editor') );
148
+ //
149
+ // register_block_type( 'wpquads/blocks', array(
150
+ // 'editor_script' => 'wpquads',
151
+ // ) );
152
+ //}
153
+ //
154
+ //add_action( 'init', 'quads_load_blocks' );
155
 
156
 
157
  /**
264
  if( isset( $quads_options['quicktags']['QckTags'] ) ) {
265
  ?>
266
  <script type="text/javascript">
267
+ wpvcomp = <?php echo (($wpvcomp == 1) ? "true " : "false"); ?>;
268
+ edaddID = new Array();
269
+ edaddNm = new Array();
270
+ if (typeof (edButtons) != 'undefined') { edadd = edButtons.length;
271
+ var dynads = {"all":[
 
272
  <?php
273
  for ( $i = 1; $i <= count( quads_get_ads() ) - 1; $i++ ) {
274
  if( isset( $quads_options['ads']['ad' . $i]['code'] ) && $quads_options['ads']['ad' . $i]['code'] != '' ) {
275
+ echo('"1",');
276
  } else {
277
  echo('"0",');
278
  };
279
  }
280
  ?>
281
+ "0"] };
282
+ for (i = 1; i <=<?php echo count( quads_get_ads() ) - 1; ?>; i++) {
283
+ if (dynads.all[ i - 1 ] == "1") {
284
+ edButtons [edButtons.length] = new edButton("ads" + i.toString(), " Ads" + i.toString(), "\n<!--Ads"+i.toString()+"-->\n", "", "", - 1);
285
+ edaddID[edaddID.length] = " ads" + i.toString();
286
+ edaddNm[edaddNm.length] = "Ads" + i.toString();
287
+ }
288
+ }
289
  <?php if( !isset( $quads_options['quicktags']['QckRnds'] ) ) { ?>
290
+ edButtons[edButtons.length] = new edButton("random_ads", " RndAds", "\n<!--RndAds-->\n", "", "", - 1);
291
+ edaddID[edaddID.length] = "random_ads";
292
+ edaddNm[edaddNm.length] = "RndAds";
293
  <?php } ?>
294
+ edButtons[edButtons.length] = new edButton("no_ads", "NoAds", "\n<!--NoAds-->\n","","",-1);
295
+ edaddID[edaddID.length] = "no_ads";
296
+ edaddNm[edaddNm.length] = "NoAds";
297
  };
298
  (function(){
299
+ if(typeof(edButtons)!='undefined' && typeof(jQuery)!='undefined' && wpvcomp){
300
+ jQuery(document).ready(function(){
301
+ for(i=0;i<edaddID.length;i++) {
302
+ jQuery("#ed_toolbar").append('<input type="button" value="' + edaddNm[i] +'" id="' + edaddID[i] +'" class="ed_button" onclick="edInsertTag(edCanvas, ' + (edadd+i) + ');" title="' + edaddNm[i] +'" />');
303
+ }
304
+ });
305
+ }
306
  }());
307
  </script>
308
  <?php
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: Rene Hermenau, WP-Staging
8
  * Author URI: https://wordpress.org/plugins/quick-adsense-reloaded/
9
- * Version: 1.8.3
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', '1.8.3' );
42
  }
43
 
44
  // Plugin name
6
  * Description: Insert Google AdSense and other ad formats fully automatic into your website
7
  * Author: Rene Hermenau, WP-Staging
8
  * Author URI: https://wordpress.org/plugins/quick-adsense-reloaded/
9
+ * Version: 1.8.4
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', '1.8.4' );
42
  }
43
 
44
  // Plugin name
readme.txt CHANGED
@@ -10,7 +10,7 @@ Tags: adsense, ads, ad, google adsense, advertising, amp, ad injection, ad inser
10
  Requires at least: 3.6+
11
  Tested up to: 5.1
12
  Requires PHP: 5.3
13
- Stable tag: 1.8.3
14
 
15
  Quick Adsense Reloaded! Quickest way to insert Google AdSense & other ads into your website. Google AdSense integration with Google AMP support
16
 
@@ -130,13 +130,18 @@ Alternative Installation:
130
 
131
  == Changelog ==
132
 
 
 
 
 
 
 
133
  = 1.8.3 =
134
  * New: WordPress 5.0 Gutenberg support
135
  * New: WordPress 5.1 support
136
  * New: WordPress 5.1.1 support
137
  * Fix: Undefined offset in wpquads\adsense
138
 
139
-
140
  = 1.8.2 =
141
  * Fix: Gutenberg breaks traditional admin notices so we remove our admin notices from the edit screen
142
 
@@ -157,23 +162,9 @@ Alternative Installation:
157
  * Fix: License notice shown even though license is not expired
158
  * Fix: Ads are injected into blog loop because of forgotten development code
159
 
160
- = 1.7.7 =
161
- * New: Option to prevent multiple injection of https://cdn.ampproject.org/v0/amp-ad-0.1.js into AMP pages
162
- * Fix: Revert load priority to 20
163
- * Fix: Change vi default background and text color
164
- * Fix: vi password field too large - css issue
165
- * Fix: Error in_array() if post_type condition is empty
166
- * Fix: If last counted paragraph is empty, ad is injected in wrong position
167
- * Fix: Ads are injected into blockquote elements
168
- * Fix: Do not show vi notice on all admin pages. If ad blocker is enabled it can not be closed
169
- * Fix: Do not update vi ad code when vi api returns null
170
- * Tweak: Show error message when vi ad can not be created
171
- * Tweak: Show notice if WP QUADS Pro license has been expired but make sure that the pro plugin does not stop working
172
- * Tweak: Better ad blocker notice
173
-
174
  Complete changelog: https://wpquads.com/changelog
175
 
176
  == Upgrade Notice ==
177
 
178
- = 1.8.3 =
179
- 1.8.3 Gutenberg Support
10
  Requires at least: 3.6+
11
  Tested up to: 5.1
12
  Requires PHP: 5.3
13
+ Stable tag: 1.8.4
14
 
15
  Quick Adsense Reloaded! Quickest way to insert Google AdSense & other ads into your website. Google AdSense integration with Google AMP support
16
 
130
 
131
  == Changelog ==
132
 
133
+ = 1.8.5 =
134
+ * Fix: Quicktags in editor not working any longer
135
+
136
+ = 1.8.4 =
137
+ * Fix: Fatal error if Gutenberg is disabled
138
+
139
  = 1.8.3 =
140
  * New: WordPress 5.0 Gutenberg support
141
  * New: WordPress 5.1 support
142
  * New: WordPress 5.1.1 support
143
  * Fix: Undefined offset in wpquads\adsense
144
 
 
145
  = 1.8.2 =
146
  * Fix: Gutenberg breaks traditional admin notices so we remove our admin notices from the edit screen
147
 
162
  * Fix: License notice shown even though license is not expired
163
  * Fix: Ads are injected into blog loop because of forgotten development code
164
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
165
  Complete changelog: https://wpquads.com/changelog
166
 
167
  == Upgrade Notice ==
168
 
169
+ = 1.8.5 =
170
+ * Fix: Quicktags in editor not working any longer