ITRO Popup Plugin - Version 4.6.2

Version Description

FIXED: visualization bugs. FIXED: "only selected pages" doesn't work for pages set as blog hompage in Settings->Reading.

Download this release

Release Info

Developer ITRO
Plugin Icon 128x128 ITRO Popup Plugin
Version 4.6.2
Comparing to
See all releases

Code changes from version 4.6.1 to 4.6.2

functions/core-function.php CHANGED
@@ -118,6 +118,9 @@ function itro_display_popup()
118
  /* this condition, control if the popup must or not by displayed in a specified page */
119
  $selected_page_id = json_decode(itro_get_option('selected_page_id'));
120
  $id_match = NULL;
 
 
 
121
 
122
  switch (itro_get_option('page_selection'))
123
  {
@@ -126,7 +129,7 @@ function itro_display_popup()
126
  {
127
  foreach ($selected_page_id as $single_id)
128
  {
129
- if ( $single_id == get_the_id() || ( $single_id == $woo_shop_id && $woo_shop ) ) /* if the selected id is the current page id popup will be displayed OR if the woo_shop_id has been selected and you are in the woocommerce standard shop page ($woo_shop == true), popup will be displayed. */
130
  {
131
  $id_match++;
132
  }
@@ -136,7 +139,7 @@ function itro_display_popup()
136
  {
137
  $id_match++;
138
  }
139
- if( $id_match != NULL || itro_get_option('preview_id') == get_the_id() )
140
  {
141
  itro_style();
142
  itro_popup_template();
@@ -149,7 +152,7 @@ function itro_display_popup()
149
  itro_popup_js();
150
  break;
151
  case 'none':
152
- if( itro_get_option('preview_id') == get_the_id() )
153
  {
154
  itro_style();
155
  itro_popup_template();
118
  /* this condition, control if the popup must or not by displayed in a specified page */
119
  $selected_page_id = json_decode(itro_get_option('selected_page_id'));
120
  $id_match = NULL;
121
+ /* get the page id */
122
+ global $wp_query;
123
+ $current_page_id = $wp_query->get_queried_object_id();
124
 
125
  switch (itro_get_option('page_selection'))
126
  {
129
  {
130
  foreach ($selected_page_id as $single_id)
131
  {
132
+ if ( $single_id == $current_page_id || ( $single_id == $woo_shop_id && $woo_shop ) ) /* if the selected id is the current page id popup will be displayed OR if the woo_shop_id has been selected and you are in the woocommerce standard shop page ($woo_shop == true), popup will be displayed. */
133
  {
134
  $id_match++;
135
  }
139
  {
140
  $id_match++;
141
  }
142
+ if( $id_match != NULL || itro_get_option('preview_id') == $current_page_id )
143
  {
144
  itro_style();
145
  itro_popup_template();
152
  itro_popup_js();
153
  break;
154
  case 'none':
155
+ if( itro_get_option('preview_id') == $current_page_id )
156
  {
157
  itro_style();
158
  itro_popup_template();
mc-main.php CHANGED
@@ -8,12 +8,12 @@ Plugin URI: http://www.itro.eu/
8
  Description: EN - Show a perfecly centered customizable popup and a popup-system for age-restricted site and allow to insert own HTML code. IT - Visualizza un popup perfettamente centrato e personalizzabile con possibile blocco per i siti con restrizioni di eta' e permette di inserire il proprio codice HTML.
9
  Author: ITRO Team
10
  E-mail: support@itro.eu
11
- Version: 4.6.1
12
  Author URI: http://www.itro.eu/
13
  */
14
 
15
  global $ITRO_VER;
16
- $ITRO_VER = 4.61;
17
 
18
  define('itroPath', plugins_url() . '/itro-popup/');
19
  define('itroImages', plugins_url() . '/itro-popup/images/');
8
  Description: EN - Show a perfecly centered customizable popup and a popup-system for age-restricted site and allow to insert own HTML code. IT - Visualizza un popup perfettamente centrato e personalizzabile con possibile blocco per i siti con restrizioni di eta' e permette di inserire il proprio codice HTML.
9
  Author: ITRO Team
10
  E-mail: support@itro.eu
11
+ Version: 4.6.2
12
  Author URI: http://www.itro.eu/
13
  */
14
 
15
  global $ITRO_VER;
16
+ $ITRO_VER = 4.62;
17
 
18
  define('itroPath', plugins_url() . '/itro-popup/');
19
  define('itroImages', plugins_url() . '/itro-popup/images/');
readme.txt CHANGED
@@ -2,9 +2,9 @@
2
  Contributors: ITRO
3
  Donate link: http://www.itro.eu/index.php/donate/
4
  Tags: popup, popup message, popup box, popup ads, popup advertising, jquery popup, popup jquery, automatic popup, age restriction, popup block, popup violence, age validation popup, adult, adult content, content warning, content warning popup, fancy box, fancy popup, custom popup, advertising popup, pop-up, lightbox, lightbox popup
5
- Requires at least: 3.3
6
- Tested up to: 3.9
7
- Stable tag: 4.6.1
8
  License: GPLv3 or later
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
@@ -91,11 +91,15 @@ DONATE NOW! - HELP US TO DEVELOP FOR YOU! [DONATE NOW](http://www.itro.eu/?page_
91
 
92
  == Screenshots ==
93
 
94
- VIEW NOW DEMOS ON OUR OFFICIAL SITE - [CLICK HERE!](http://www.itro.eu/?page_id=4624)
95
 
96
  == Changelog ==
 
 
 
 
97
  = 4.6.1 =
98
- database collate problem fixed
99
 
100
  = 4.6 =
101
  database error fixed
@@ -275,9 +279,6 @@ bug fixed: color table now works in admin pannel.
275
  First released version.
276
 
277
  == Upgrade Notice ==
278
- = 4.6.1 =
279
- database collate problem fixed
280
-
281
  = 4.6 =
282
  database error fixed
283
 
2
  Contributors: ITRO
3
  Donate link: http://www.itro.eu/index.php/donate/
4
  Tags: popup, popup message, popup box, popup ads, popup advertising, jquery popup, popup jquery, automatic popup, age restriction, popup block, popup violence, age validation popup, adult, adult content, content warning, content warning popup, fancy box, fancy popup, custom popup, advertising popup, pop-up, lightbox, lightbox popup
5
+ Requires at least: 3.0.1
6
+ Tested up to: 4.0
7
+ Stable tag: 4.6.2
8
  License: GPLv3 or later
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
91
 
92
  == Screenshots ==
93
 
94
+ VIEW NOW DEMOS ON OUR OFFICIAL SITE - [CLICK HERE!](http://www.itro.eu/?page_id=3056)
95
 
96
  == Changelog ==
97
+ = 4.6.2 =
98
+ FIXED: visualization bugs.
99
+ FIXED: "only selected pages" doesn't work for pages set as blog hompage in Settings->Reading.
100
+
101
  = 4.6.1 =
102
+ database collation issue solved.
103
 
104
  = 4.6 =
105
  database error fixed
279
  First released version.
280
 
281
  == Upgrade Notice ==
 
 
 
282
  = 4.6 =
283
  database error fixed
284
 
templates/itro-popup-template.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  function itro_popup_template()
3
  { ?>
4
- <div id="itro_popup" style="visibility:hidden">
5
  <?php
6
  if( itro_get_option('age_restriction') == NULL ) /* age restriction off */
7
  {
1
  <?php
2
  function itro_popup_template()
3
  { ?>
4
+ <div id="itro_popup" style="visibility:hidden; display: none;">
5
  <?php
6
  if( itro_get_option('age_restriction') == NULL ) /* age restriction off */
7
  {