Version Description
Current Version of Popup Builder is 2.3.6
Download this release
Release Info
Developer | Sygnoos |
Plugin | Popup Builder – Responsive WordPress Pop up |
Version | 2.3.7 |
Comparing to | |
See all releases |
Code changes from version 2.3.6 to 2.3.7
- config.php +1 -1
- files/sg_functions.php +11 -11
- files/sg_popup_create_new.php +17 -1
- files/sg_popup_save.php +3 -0
- helpers/SgPopupGetData.php +5 -5
- javascript/sg_popup_backend.js +1 -1
- javascript/sg_popup_frontend.js +53 -2
- popup-builder.php +2 -2
- readme.txt +8 -2
- style/sg_popup_style.css +11 -2
config.php
CHANGED
@@ -9,7 +9,7 @@ define('SG_APP_POPUP_CLASSES', SG_APP_POPUP_PATH . '/classes');
|
|
9 |
define('SG_APP_POPUP_JS', SG_APP_POPUP_PATH . '/javascript');
|
10 |
define('SG_APP_POPUP_HELPERS', SG_APP_POPUP_PATH . '/helpers/');
|
11 |
define('SG_APP_POPUP_TABLE_LIMIT', 15);
|
12 |
-
define('SG_POPUP_VERSION', 2.
|
13 |
define('SG_POPUP_PRO_URL', 'http://popup-builder.com/');
|
14 |
define('SG_POPUP_EXTENTIONS_URL', 'http://popup-builder.com/extensions');
|
15 |
define('SG_MAILCHIMP_EXTENTION_URL', 'http://popup-builder.com/mailchimp/');
|
9 |
define('SG_APP_POPUP_JS', SG_APP_POPUP_PATH . '/javascript');
|
10 |
define('SG_APP_POPUP_HELPERS', SG_APP_POPUP_PATH . '/helpers/');
|
11 |
define('SG_APP_POPUP_TABLE_LIMIT', 15);
|
12 |
+
define('SG_POPUP_VERSION', 2.37);
|
13 |
define('SG_POPUP_PRO_URL', 'http://popup-builder.com/');
|
14 |
define('SG_POPUP_EXTENTIONS_URL', 'http://popup-builder.com/extensions');
|
15 |
define('SG_MAILCHIMP_EXTENTION_URL', 'http://popup-builder.com/mailchimp/');
|
files/sg_functions.php
CHANGED
@@ -19,21 +19,21 @@ class SGFunctions
|
|
19 |
$arr = $wpdb->get_row($st,ARRAY_A);
|
20 |
$options = json_decode($arr['options'], true);
|
21 |
$deleteStatus = ($options['tables-delete-status'] == 'on' ? true: false);
|
22 |
-
|
23 |
return $deleteStatus;
|
24 |
}
|
25 |
|
26 |
public static function addReview()
|
27 |
{
|
28 |
return '<div class="updated updated notice is-dismissible reviewPanel sg-review-panel">
|
29 |
-
<div class="reviewPanelContent">
|
30 |
<span class="reviewPanelSpan">
|
31 |
-
Dear user, we always do our best to help you and your opinion is very important for us!
|
32 |
</span></br>
|
33 |
<span class="reviewPanelSpan">
|
34 |
So if you liked our <b>Popup Builder Plugin</b> and if our support was helpful for you, we\'ll be thankful if you go ahead and leave a review.
|
35 |
</span>
|
36 |
-
<span class="reviewPanelSpan">
|
37 |
Please <a class="reviewPanelHref" href="https://wordpress.org/support/view/plugin-reviews/popup-builder?filter=5" target=\"_blank\">rate it 5 stars.</a>
|
38 |
</span>
|
39 |
</div>
|
@@ -51,7 +51,7 @@ class SGFunctions
|
|
51 |
|
52 |
$attrString = '';
|
53 |
$selected = '';
|
54 |
-
|
55 |
if(!empty($attrs) && isset($attrs)) {
|
56 |
|
57 |
foreach ($attrs as $attrName => $attrValue) {
|
@@ -129,9 +129,9 @@ class SGFunctions
|
|
129 |
public static function getCountryName($ip)
|
130 |
{
|
131 |
if(empty($_COOKIE['SG_POPUP_USER_COUNTRY_NAME'])) {
|
132 |
-
|
133 |
try {
|
134 |
-
|
135 |
$details = wp_remote_get(SG_IP_TO_COUNTRY_SERVICE_URL.$ip."&".SG_IP_TO_COUNTRY_SERVICE_TOKEN, array( 'timeout' => SG_IP_TO_COUNTRY_SERVICE_TIMEOUT));$details = wp_remote_get(SG_IP_TO_COUNTRY_SERVICE_URL.$ip."&".SG_IP_TO_COUNTRY_SERVICE_TOKEN, array( 'timeout' => SG_IP_TO_COUNTRY_SERVICE_TIMEOUT));
|
136 |
$dataIp = json_decode($details['body'], true);
|
137 |
if(!is_array($dataIp)) {
|
@@ -142,12 +142,12 @@ class SGFunctions
|
|
142 |
catch ( Exception $ex ) {
|
143 |
return true;
|
144 |
}
|
145 |
-
|
146 |
}
|
147 |
else {
|
148 |
$counrty = $_COOKIE['SG_POPUP_USER_COUNTRY_NAME'];
|
149 |
}
|
150 |
-
|
151 |
return $counrty;
|
152 |
}
|
153 |
|
@@ -173,7 +173,7 @@ class SGFunctions
|
|
173 |
|
174 |
public static function isShowMenuForCurrentUser() {
|
175 |
$usersSelectedRoles = SgPopupGetData::getValue('plugin_users_role', 'settings');
|
176 |
-
|
177 |
$currentUserRole = SgPopupGetData::getCurrentUserRole();
|
178 |
|
179 |
/*When user is admintrator or this user is in selected rules*/
|
@@ -437,4 +437,4 @@ class SGFunctions
|
|
437 |
<option value="ZW">Zimbabwe</option>
|
438 |
</select>';
|
439 |
}
|
440 |
-
}
|
19 |
$arr = $wpdb->get_row($st,ARRAY_A);
|
20 |
$options = json_decode($arr['options'], true);
|
21 |
$deleteStatus = ($options['tables-delete-status'] == 'on' ? true: false);
|
22 |
+
|
23 |
return $deleteStatus;
|
24 |
}
|
25 |
|
26 |
public static function addReview()
|
27 |
{
|
28 |
return '<div class="updated updated notice is-dismissible reviewPanel sg-review-panel">
|
29 |
+
<div class="reviewPanelContent">
|
30 |
<span class="reviewPanelSpan">
|
31 |
+
Dear user, we always do our best to help you and your opinion is very important for us!
|
32 |
</span></br>
|
33 |
<span class="reviewPanelSpan">
|
34 |
So if you liked our <b>Popup Builder Plugin</b> and if our support was helpful for you, we\'ll be thankful if you go ahead and leave a review.
|
35 |
</span>
|
36 |
+
<span class="reviewPanelSpan">
|
37 |
Please <a class="reviewPanelHref" href="https://wordpress.org/support/view/plugin-reviews/popup-builder?filter=5" target=\"_blank\">rate it 5 stars.</a>
|
38 |
</span>
|
39 |
</div>
|
51 |
|
52 |
$attrString = '';
|
53 |
$selected = '';
|
54 |
+
|
55 |
if(!empty($attrs) && isset($attrs)) {
|
56 |
|
57 |
foreach ($attrs as $attrName => $attrValue) {
|
129 |
public static function getCountryName($ip)
|
130 |
{
|
131 |
if(empty($_COOKIE['SG_POPUP_USER_COUNTRY_NAME'])) {
|
132 |
+
|
133 |
try {
|
134 |
+
|
135 |
$details = wp_remote_get(SG_IP_TO_COUNTRY_SERVICE_URL.$ip."&".SG_IP_TO_COUNTRY_SERVICE_TOKEN, array( 'timeout' => SG_IP_TO_COUNTRY_SERVICE_TIMEOUT));$details = wp_remote_get(SG_IP_TO_COUNTRY_SERVICE_URL.$ip."&".SG_IP_TO_COUNTRY_SERVICE_TOKEN, array( 'timeout' => SG_IP_TO_COUNTRY_SERVICE_TIMEOUT));
|
136 |
$dataIp = json_decode($details['body'], true);
|
137 |
if(!is_array($dataIp)) {
|
142 |
catch ( Exception $ex ) {
|
143 |
return true;
|
144 |
}
|
145 |
+
|
146 |
}
|
147 |
else {
|
148 |
$counrty = $_COOKIE['SG_POPUP_USER_COUNTRY_NAME'];
|
149 |
}
|
150 |
+
|
151 |
return $counrty;
|
152 |
}
|
153 |
|
173 |
|
174 |
public static function isShowMenuForCurrentUser() {
|
175 |
$usersSelectedRoles = SgPopupGetData::getValue('plugin_users_role', 'settings');
|
176 |
+
|
177 |
$currentUserRole = SgPopupGetData::getCurrentUserRole();
|
178 |
|
179 |
/*When user is admintrator or this user is in selected rules*/
|
437 |
<option value="ZW">Zimbabwe</option>
|
438 |
</select>';
|
439 |
}
|
440 |
+
}
|
files/sg_popup_create_new.php
CHANGED
@@ -88,6 +88,7 @@
|
|
88 |
$jsonData = json_decode($result->getOptions(), true);
|
89 |
$sgEscKey = @$jsonData['escKey'];
|
90 |
$sgScrolling = @$jsonData['scrolling'];
|
|
|
91 |
$sgCloseButton = @$jsonData['closeButton'];
|
92 |
$sgReposition = @$jsonData['reposition'];
|
93 |
$sgOverlayClose = @$jsonData['overlayClose'];
|
@@ -105,6 +106,8 @@
|
|
105 |
$beforeScrolingPrsent = @$jsonData['beforeScrolingPrsent'];
|
106 |
$duration = @$jsonData['duration'];
|
107 |
$delay = @$jsonData['delay'];
|
|
|
|
|
108 |
$sgThemeCloseText = @$jsonData['theme-close-text'];
|
109 |
$effect =@$jsonData['effect'];
|
110 |
$sgInitialWidth = @$jsonData['initialWidth'];
|
@@ -250,6 +253,7 @@
|
|
250 |
'escKey'=> true,
|
251 |
'closeButton' => true,
|
252 |
'scrolling'=> true,
|
|
|
253 |
'opacity'=>0.8,
|
254 |
'reposition' => true,
|
255 |
'width' => '640px',
|
@@ -358,6 +362,7 @@
|
|
358 |
$escKey = sgBoolToChecked($sgPopup['escKey']);
|
359 |
$closeButton = sgBoolToChecked($sgPopup['closeButton']);
|
360 |
$scrolling = sgBoolToChecked($sgPopup['scrolling']);
|
|
|
361 |
$reposition = sgBoolToChecked($sgPopup['reposition']);
|
362 |
$overlayClose = sgBoolToChecked($sgPopup['overlayClose']);
|
363 |
$contentClick = sgBoolToChecked($sgPopup['contentClick']);
|
@@ -477,6 +482,7 @@
|
|
477 |
$sgOverlayClose = @sgSetChecked($sgOverlayClose, $overlayClose);
|
478 |
$sgReposition = @sgSetChecked($sgReposition, $reposition);
|
479 |
$sgScrolling = @sgSetChecked($sgScrolling, $scrolling);
|
|
|
480 |
$sgCountdownAutoclose = @sgSetChecked($sgCountdownAutoclose, $countdownAutoclose);
|
481 |
|
482 |
$sgCloseType = @sgSetChecked($sgCloseType, $closeType);
|
@@ -1026,7 +1032,14 @@
|
|
1026 |
<div class="theme3 sg-hide"></div>
|
1027 |
<div class="theme4 sg-hide"></div>
|
1028 |
<div class="theme5 sg-hide"></div>
|
1029 |
-
<div class="theme-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1030 |
<span class="liquid-width">Close button text:</span>
|
1031 |
<input type="text" name="theme-close-text" value="<?php echo esc_attr($sgThemeCloseText);?>">
|
1032 |
</div>
|
@@ -1113,6 +1126,9 @@
|
|
1113 |
<span class="liquid-width">Enable reposition:</span><input class="input-width-static" type="checkbox" name="reposition" <?php echo $sgReposition;?> />
|
1114 |
<span class="dashicons dashicons-info repositionImg sameImageStyle"></span><span class="infoReposition samefontStyle">The popup will be resized/repositioned automatically when window is being resized.</span><br>
|
1115 |
|
|
|
|
|
|
|
1116 |
<span class="liquid-width">Dismiss on overlay click:</span><input class="input-width-static" type="checkbox" name="overlayClose" <?php echo $sgOverlayClose;?> />
|
1117 |
<span class="dashicons dashicons-info overlayImg sameImageStyle"></span><span class="infoOverlayClose samefontStyle">The popup will be dismissed when user clicks beyond of the popup area.</span><br>
|
1118 |
|
88 |
$jsonData = json_decode($result->getOptions(), true);
|
89 |
$sgEscKey = @$jsonData['escKey'];
|
90 |
$sgScrolling = @$jsonData['scrolling'];
|
91 |
+
$sgScaling = @$jsonData['scaling'];
|
92 |
$sgCloseButton = @$jsonData['closeButton'];
|
93 |
$sgReposition = @$jsonData['reposition'];
|
94 |
$sgOverlayClose = @$jsonData['overlayClose'];
|
106 |
$beforeScrolingPrsent = @$jsonData['beforeScrolingPrsent'];
|
107 |
$duration = @$jsonData['duration'];
|
108 |
$delay = @$jsonData['delay'];
|
109 |
+
$sgTheme3BorderColor = @$jsonData['sgTheme3BorderColor'];
|
110 |
+
$sgTheme3BorderRadius = @$jsonData['sgTheme3BorderRadius'];
|
111 |
$sgThemeCloseText = @$jsonData['theme-close-text'];
|
112 |
$effect =@$jsonData['effect'];
|
113 |
$sgInitialWidth = @$jsonData['initialWidth'];
|
253 |
'escKey'=> true,
|
254 |
'closeButton' => true,
|
255 |
'scrolling'=> true,
|
256 |
+
'scaling'=>false,
|
257 |
'opacity'=>0.8,
|
258 |
'reposition' => true,
|
259 |
'width' => '640px',
|
362 |
$escKey = sgBoolToChecked($sgPopup['escKey']);
|
363 |
$closeButton = sgBoolToChecked($sgPopup['closeButton']);
|
364 |
$scrolling = sgBoolToChecked($sgPopup['scrolling']);
|
365 |
+
$scaling = sgBoolToChecked($sgPopup['scaling']);
|
366 |
$reposition = sgBoolToChecked($sgPopup['reposition']);
|
367 |
$overlayClose = sgBoolToChecked($sgPopup['overlayClose']);
|
368 |
$contentClick = sgBoolToChecked($sgPopup['contentClick']);
|
482 |
$sgOverlayClose = @sgSetChecked($sgOverlayClose, $overlayClose);
|
483 |
$sgReposition = @sgSetChecked($sgReposition, $reposition);
|
484 |
$sgScrolling = @sgSetChecked($sgScrolling, $scrolling);
|
485 |
+
$sgScaling = @sgSetChecked($sgScaling, $scaling);
|
486 |
$sgCountdownAutoclose = @sgSetChecked($sgCountdownAutoclose, $countdownAutoclose);
|
487 |
|
488 |
$sgCloseType = @sgSetChecked($sgCloseType, $closeType);
|
1032 |
<div class="theme3 sg-hide"></div>
|
1033 |
<div class="theme4 sg-hide"></div>
|
1034 |
<div class="theme5 sg-hide"></div>
|
1035 |
+
<div class="sg-popup-theme-3 themes-suboptions sg-hide">
|
1036 |
+
<span class="liquid-width">Border color:</span>
|
1037 |
+
<div id="color-picker"><input class="sgOverlayColor" id="sgOverlayColor" type="text" name="sgTheme3BorderColor" value="<?php echo esc_attr(@$sgTheme3BorderColor); ?>" /></div>
|
1038 |
+
<br><span class="liquid-width">Border radius:</span>
|
1039 |
+
<input class="input-width-percent" type="number" min="0" max="50" name="sgTheme3BorderRadius" value="<?php echo esc_attr(@$sgTheme3BorderRadius); ?>">
|
1040 |
+
<span class="span-percent">%</span>
|
1041 |
+
</div>
|
1042 |
+
<div class="sg-popup-theme-4 themes-suboptions sg-hide">
|
1043 |
<span class="liquid-width">Close button text:</span>
|
1044 |
<input type="text" name="theme-close-text" value="<?php echo esc_attr($sgThemeCloseText);?>">
|
1045 |
</div>
|
1126 |
<span class="liquid-width">Enable reposition:</span><input class="input-width-static" type="checkbox" name="reposition" <?php echo $sgReposition;?> />
|
1127 |
<span class="dashicons dashicons-info repositionImg sameImageStyle"></span><span class="infoReposition samefontStyle">The popup will be resized/repositioned automatically when window is being resized.</span><br>
|
1128 |
|
1129 |
+
<span class="liquid-width">Enable scaling:</span><input class="input-width-static" type="checkbox" name="scaling" <?php echo $sgScaling;?> />
|
1130 |
+
<span class="dashicons dashicons-info scrollingImg sameImageStyle"></span><span class="infoScaling samefontStyle">Resize popup according to screen size</span><br>
|
1131 |
+
|
1132 |
<span class="liquid-width">Dismiss on overlay click:</span><input class="input-width-static" type="checkbox" name="overlayClose" <?php echo $sgOverlayClose;?> />
|
1133 |
<span class="dashicons dashicons-info overlayImg sameImageStyle"></span><span class="infoOverlayClose samefontStyle">The popup will be dismissed when user clicks beyond of the popup area.</span><br>
|
1134 |
|
files/sg_popup_save.php
CHANGED
@@ -175,6 +175,7 @@ function sgPopupSave()
|
|
175 |
'effect' => sgSanitize('effect'),
|
176 |
'escKey' => sgSanitize('escKey'),
|
177 |
'scrolling' => sgSanitize('scrolling'),
|
|
|
178 |
'reposition' => sgSanitize('reposition'),
|
179 |
'overlayClose' => sgSanitize('overlayClose'),
|
180 |
'contentClick' => sgSanitize('contentClick'),
|
@@ -191,6 +192,8 @@ function sgPopupSave()
|
|
191 |
'initialHeight' => sgSanitize('initialHeight'),
|
192 |
'closeButton' => sgSanitize('closeButton'),
|
193 |
'theme' => sgSanitize('theme'),
|
|
|
|
|
194 |
'onScrolling' => sgSanitize('onScrolling'),
|
195 |
'inActivityStatus' => sgSanitize('inActivityStatus'),
|
196 |
'inactivity-timout' => sgSanitize('inactivity-timout'),
|
175 |
'effect' => sgSanitize('effect'),
|
176 |
'escKey' => sgSanitize('escKey'),
|
177 |
'scrolling' => sgSanitize('scrolling'),
|
178 |
+
'scaling' => sgSanitize('scaling'),
|
179 |
'reposition' => sgSanitize('reposition'),
|
180 |
'overlayClose' => sgSanitize('overlayClose'),
|
181 |
'contentClick' => sgSanitize('contentClick'),
|
192 |
'initialHeight' => sgSanitize('initialHeight'),
|
193 |
'closeButton' => sgSanitize('closeButton'),
|
194 |
'theme' => sgSanitize('theme'),
|
195 |
+
'sgTheme3BorderColor'=> sgSanitize("sgTheme3BorderColor"),
|
196 |
+
'sgTheme3BorderRadius'=> sgSanitize("sgTheme3BorderRadius"),
|
197 |
'onScrolling' => sgSanitize('onScrolling'),
|
198 |
'inActivityStatus' => sgSanitize('inActivityStatus'),
|
199 |
'inactivity-timout' => sgSanitize('inactivity-timout'),
|
helpers/SgPopupGetData.php
CHANGED
@@ -24,12 +24,12 @@ class SgPopupGetData {
|
|
24 |
$optionType = strtolower($optionType);
|
25 |
$optionFunctionName = 'get'.ucfirst($optionType).'Options';
|
26 |
$options = self::$optionFunctionName();
|
27 |
-
|
28 |
|
29 |
if(isset($options[$optionName])) {
|
30 |
return $options[$optionName];
|
31 |
}
|
32 |
-
|
33 |
$deafaultValues = self::getDefaultValues();
|
34 |
$deafultSettings = $deafaultValues[$optionType.'Paramas'];
|
35 |
|
@@ -56,7 +56,7 @@ class SgPopupGetData {
|
|
56 |
|
57 |
$options = self::getSettingsOptions();
|
58 |
|
59 |
-
$popupImeZone =
|
60 |
|
61 |
return $popupImeZone;
|
62 |
}
|
@@ -66,7 +66,7 @@ class SgPopupGetData {
|
|
66 |
$cats = get_categories(
|
67 |
array(
|
68 |
"hide_empty" => 0,
|
69 |
-
"type" => "post",
|
70 |
"orderby" => "name",
|
71 |
"order" => "ASC"
|
72 |
)
|
@@ -115,4 +115,4 @@ class SgPopupGetData {
|
|
115 |
$role = $current_user->role[0];
|
116 |
return "sgpb_".$role;
|
117 |
}
|
118 |
-
}
|
24 |
$optionType = strtolower($optionType);
|
25 |
$optionFunctionName = 'get'.ucfirst($optionType).'Options';
|
26 |
$options = self::$optionFunctionName();
|
27 |
+
|
28 |
|
29 |
if(isset($options[$optionName])) {
|
30 |
return $options[$optionName];
|
31 |
}
|
32 |
+
|
33 |
$deafaultValues = self::getDefaultValues();
|
34 |
$deafultSettings = $deafaultValues[$optionType.'Paramas'];
|
35 |
|
56 |
|
57 |
$options = self::getSettingsOptions();
|
58 |
|
59 |
+
$popupImeZone = @$options['sg-popup-time-zone'];
|
60 |
|
61 |
return $popupImeZone;
|
62 |
}
|
66 |
$cats = get_categories(
|
67 |
array(
|
68 |
"hide_empty" => 0,
|
69 |
+
"type" => "post",
|
70 |
"orderby" => "name",
|
71 |
"order" => "ASC"
|
72 |
)
|
115 |
$role = $current_user->role[0];
|
116 |
return "sgpb_".$role;
|
117 |
}
|
118 |
+
}
|
javascript/sg_popup_backend.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
jQuery(document).ready(function($){
|
2 |
this.titleNotEmpty(); /* Check title is Empty */
|
3 |
this.showThemePicture(); /* Show themes pictures */
|
4 |
this.showEffects(); /* Show effect type */
|
5 |
this.pageAcordion(); /* For page acordion divs */
|
6 |
this.fixedPostionSelection(); /* Fuctionality for selected postion */
|
7 |
this.showInfo(); /* Show description options */
|
8 |
this.opasictyRange(); /* Opcity range */
|
9 |
this.subOptionContents();
|
10 |
this.addCountris();
|
11 |
this.showCloseTextFieldForTheme();
|
12 |
this.popupReview();
|
13 |
this.popupTimer();
|
14 |
this.colorPicekr(); /* Color picker */
|
15 |
});
|
|
|
16 |
this.titleNotEmpty(); /* Check title is Empty */
|
17 |
this.showThemePicture(); /* Show themes pictures */
|
18 |
this.showEffects(); /* Show effect type */
|
19 |
this.pageAcordion(); /* For page acordion divs */
|
20 |
this.fixedPostionSelection(); /* Fuctionality for selected postion */
|
21 |
this.showInfo(); /* Show description options */
|
22 |
this.opasictyRange(); /* Opcity range */
|
23 |
this.subOptionContents();
|
24 |
this.addCountries();
|
25 |
this.showCloseTextFieldForTheme();
|
26 |
this.popupReview();
|
27 |
this.popupTimer();
|
28 |
this.colorPicekr(); /* Color picker */
|
29 |
});
|
|
|
1 |
this.titleNotEmpty(); /* Check title is Empty */
|
2 |
this.showThemePicture(); /* Show themes pictures */
|
3 |
this.showEffects(); /* Show effect type */
|
4 |
this.pageAcordion(); /* For page acordion divs */
|
5 |
this.fixedPostionSelection(); /* Fuctionality for selected postion */
|
6 |
this.showInfo(); /* Show description options */
|
7 |
this.opasictyRange(); /* Opcity range */
|
8 |
this.subOptionContents();
|
9 |
this.addCountris();
|
10 |
this.showCloseTextFieldForTheme();
|
11 |
this.popupReview();
|
12 |
this.popupTimer();
|
13 |
this.colorPicekr(); /* Color picker */
|
14 |
});
|
15 |
+
jQuery(document).ready(function($){
|
16 |
this.titleNotEmpty(); /* Check title is Empty */
|
17 |
this.showThemePicture(); /* Show themes pictures */
|
18 |
this.showEffects(); /* Show effect type */
|
19 |
this.pageAcordion(); /* For page acordion divs */
|
20 |
this.fixedPostionSelection(); /* Fuctionality for selected postion */
|
21 |
this.showInfo(); /* Show description options */
|
22 |
this.opasictyRange(); /* Opcity range */
|
23 |
this.subOptionContents();
|
24 |
this.addCountries();
|
25 |
this.showCloseTextFieldForTheme();
|
26 |
this.popupReview();
|
27 |
this.popupTimer();
|
28 |
this.colorPicekr(); /* Color picker */
|
29 |
});
|
javascript/sg_popup_frontend.js
CHANGED
@@ -66,6 +66,20 @@ SGPopup.prototype.init = function() {
|
|
66 |
});
|
67 |
}
|
68 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
69 |
SGPopup.prototype.onCompleate = function() {
|
70 |
|
71 |
jQuery("#sgcolorbox").bind("sgColorboxOnCompleate", function() {
|
@@ -92,6 +106,36 @@ SGPopup.prototype.isolatedScroll = function() {
|
|
92 |
};
|
93 |
}
|
94 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
95 |
SGPopup.prototype.varToBool = function(optionName) {
|
96 |
returnValue = (optionName) ? true : false;
|
97 |
return returnValue;
|
@@ -171,6 +215,7 @@ SGPopup.prototype.sgShowColorboxWithOptions = function() {
|
|
171 |
that.popupContentClick = that.varToBool(that.popupData['contentClick']);
|
172 |
var popupReposition = that.varToBool(that.popupData['reposition']);
|
173 |
var popupScrolling = that.varToBool(that.popupData['scrolling']);
|
|
|
174 |
that.popupEscKey = that.varToBool(that.popupData['escKey']);
|
175 |
that.popupCloseButton = that.varToBool(that.popupData['closeButton']);
|
176 |
var countryStatus = that.varToBool(that.popupData['countryStatus']);
|
@@ -180,7 +225,10 @@ SGPopup.prototype.sgShowColorboxWithOptions = function() {
|
|
180 |
var disablePopupOverlay = that.varToBool(that.popupData['disablePopupOverlay']);
|
181 |
var popupAutoClosePopup = that.varToBool(that.popupData['autoClosePopup']);
|
182 |
popupClosingTimer = that.popupData['popupClosingTimer'];
|
183 |
-
|
|
|
|
|
|
|
184 |
if (popupCantClose) {
|
185 |
that.cantPopupClose();
|
186 |
}
|
@@ -339,8 +387,10 @@ SGPopup.prototype.sgShowColorboxWithOptions = function() {
|
|
339 |
if (popupOverlayColor) {
|
340 |
jQuery("#sgcboxOverlay").css({'background' : 'none', 'background-color' : popupOverlayColor});
|
341 |
}
|
342 |
-
|
343 |
jQuery('#sgcolorbox').trigger("sgColorboxOnOpen", []);
|
|
|
|
|
344 |
},
|
345 |
onLoad: function(){
|
346 |
},
|
@@ -358,6 +408,7 @@ SGPopup.prototype.sgShowColorboxWithOptions = function() {
|
|
358 |
sgpopupInit.overallInit();
|
359 |
/* For specific popup Like Countdown AgeRestcion popups */
|
360 |
sgpopupInit.initByPopupType();
|
|
|
361 |
|
362 |
},
|
363 |
onCleanup: function() {
|
66 |
});
|
67 |
}
|
68 |
|
69 |
+
SGPopup.prototype.sgCustomizeThemes = function(popupId) {
|
70 |
+
|
71 |
+
var popupData = SG_POPUP_DATA[popupId];
|
72 |
+
var borderRadiues = popupData['sg3ThemeBorderRadiues'];
|
73 |
+
|
74 |
+
if(popupData['theme'] == "colorbox3.css") {
|
75 |
+
var borderColor = popupData['sgTheme3BorderColor'];
|
76 |
+
var borderRadiues = popupData['sgTheme3BorderRadius'];
|
77 |
+
jQuery("#sgcboxLoadedContent").css({'border-color': borderColor})
|
78 |
+
jQuery("#sgcboxLoadedContent").css({'border-radius': borderRadiues+"%"})
|
79 |
+
jQuery("#sgcboxContent").css({'border-radius': borderRadiues+"%"})
|
80 |
+
}
|
81 |
+
}
|
82 |
+
|
83 |
SGPopup.prototype.onCompleate = function() {
|
84 |
|
85 |
jQuery("#sgcolorbox").bind("sgColorboxOnCompleate", function() {
|
106 |
};
|
107 |
}
|
108 |
|
109 |
+
SGPopup.prototype.sgPopupScalingDimensions = function() {
|
110 |
+
var popupWrapper = jQuery("#sgcboxWrapper").outerWidth();
|
111 |
+
var screenWidth = jQuery(window).width();
|
112 |
+
/*popupWrapper != 9999 for resizing case when colorbox is calculated popup dimensions*/
|
113 |
+
if(popupWrapper > screenWidth && popupWrapper != 9999) {
|
114 |
+
var scaleDegree = screenWidth/popupWrapper;
|
115 |
+
jQuery("#sgcboxWrapper").css({
|
116 |
+
"transform-origin" : "0 0",
|
117 |
+
'transform': "scale("+scaleDegree+", 1)"
|
118 |
+
})
|
119 |
+
popupWrapper = 0;
|
120 |
+
}
|
121 |
+
else {
|
122 |
+
jQuery("#sgcboxWrapper").css({
|
123 |
+
"transform-origin" : "0 0",
|
124 |
+
'transform': "scale(1, 1)"
|
125 |
+
})
|
126 |
+
}
|
127 |
+
}
|
128 |
+
|
129 |
+
SGPopup.prototype.sgPopupScaling = function() {
|
130 |
+
var that = this;
|
131 |
+
jQuery("#sgcolorbox").bind("sgColorboxOnCompleate", function() {
|
132 |
+
that.sgPopupScalingDimensions();
|
133 |
+
});
|
134 |
+
jQuery(window).resize(function() {
|
135 |
+
setTimeout(function(){ that.sgPopupScalingDimensions(); }, 1000);
|
136 |
+
});
|
137 |
+
}
|
138 |
+
|
139 |
SGPopup.prototype.varToBool = function(optionName) {
|
140 |
returnValue = (optionName) ? true : false;
|
141 |
return returnValue;
|
215 |
that.popupContentClick = that.varToBool(that.popupData['contentClick']);
|
216 |
var popupReposition = that.varToBool(that.popupData['reposition']);
|
217 |
var popupScrolling = that.varToBool(that.popupData['scrolling']);
|
218 |
+
var popupScaling = that.varToBool(that.popupData['scaling']);
|
219 |
that.popupEscKey = that.varToBool(that.popupData['escKey']);
|
220 |
that.popupCloseButton = that.varToBool(that.popupData['closeButton']);
|
221 |
var countryStatus = that.varToBool(that.popupData['countryStatus']);
|
225 |
var disablePopupOverlay = that.varToBool(that.popupData['disablePopupOverlay']);
|
226 |
var popupAutoClosePopup = that.varToBool(that.popupData['autoClosePopup']);
|
227 |
popupClosingTimer = that.popupData['popupClosingTimer'];
|
228 |
+
|
229 |
+
if(popupScaling) {
|
230 |
+
that.sgPopupScaling();
|
231 |
+
}
|
232 |
if (popupCantClose) {
|
233 |
that.cantPopupClose();
|
234 |
}
|
387 |
if (popupOverlayColor) {
|
388 |
jQuery("#sgcboxOverlay").css({'background' : 'none', 'background-color' : popupOverlayColor});
|
389 |
}
|
390 |
+
|
391 |
jQuery('#sgcolorbox').trigger("sgColorboxOnOpen", []);
|
392 |
+
that.sgCustomizeThemes(that.popupData['id']);
|
393 |
+
|
394 |
},
|
395 |
onLoad: function(){
|
396 |
},
|
408 |
sgpopupInit.overallInit();
|
409 |
/* For specific popup Like Countdown AgeRestcion popups */
|
410 |
sgpopupInit.initByPopupType();
|
411 |
+
that.sgCustomizeThemes(that.popupData['id']);
|
412 |
|
413 |
},
|
414 |
onCleanup: function() {
|
popup-builder.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: Popup Builder
|
4 |
* Plugin URI: http://sygnoos.com
|
5 |
* Description: The most complete popup plugin. Html, image, iframe, shortcode, video and many other popup types. Manage popup dimensions, effects, themes and more.
|
6 |
-
* Version: 2.3.
|
7 |
* Author: Sygnoos
|
8 |
* Author URI: http://www.sygnoos.com
|
9 |
* License: GPLv2
|
@@ -168,7 +168,7 @@ function sgShowShortCode($args, $content)
|
|
168 |
/* Free user does not have QUEUE possibility */
|
169 |
if(POPUP_BUILDER_PKG > POPUP_BUILDER_PKG_FREE) {
|
170 |
$page = get_queried_object_id();
|
171 |
-
$popupsId = SgPopupPro::allowPopupInAllPages($page);
|
172 |
|
173 |
/* When have many popups in current page */
|
174 |
if(count($popupsId) > 0) {
|
3 |
* Plugin Name: Popup Builder
|
4 |
* Plugin URI: http://sygnoos.com
|
5 |
* Description: The most complete popup plugin. Html, image, iframe, shortcode, video and many other popup types. Manage popup dimensions, effects, themes and more.
|
6 |
+
* Version: 2.3.7
|
7 |
* Author: Sygnoos
|
8 |
* Author URI: http://www.sygnoos.com
|
9 |
* License: GPLv2
|
168 |
/* Free user does not have QUEUE possibility */
|
169 |
if(POPUP_BUILDER_PKG > POPUP_BUILDER_PKG_FREE) {
|
170 |
$page = get_queried_object_id();
|
171 |
+
$popupsId = SgPopupPro::allowPopupInAllPages($page,'page');
|
172 |
|
173 |
/* When have many popups in current page */
|
174 |
if(count($popupsId) > 0) {
|
readme.txt
CHANGED
@@ -41,6 +41,7 @@ With popup builder plugin you can insert any type of content, right into your Po
|
|
41 |
* Redirect user to another page when he/she clicks on popup content
|
42 |
* Show/Hide Popup for selected User Roles (Admin panel)
|
43 |
* Responsive popup
|
|
|
44 |
* Network/Multisite popup
|
45 |
* On click popup
|
46 |
* Html popup
|
@@ -117,7 +118,7 @@ Thank you for using our popup plugin.
|
|
117 |
</div>
|
118 |
|
119 |
<div>
|
120 |
-
If you think that you found a bug in our Popup Builder plugin or have any questions, please feel free to contact us at <a href="mailto:
|
121 |
### Popup Builder
|
122 |
</div>
|
123 |
</div>
|
@@ -152,6 +153,11 @@ Go to the Popup Builder settings and set your desired options.
|
|
152 |
|
153 |
== Changelog ==
|
154 |
|
|
|
|
|
|
|
|
|
|
|
155 |
= Version 2.3.6 =
|
156 |
* Show/Hide Popup for selected User Roles (Admin panel) (Free)
|
157 |
* Bug fixed connected to 3rd party shortcodes
|
@@ -471,7 +477,7 @@ Live preview is a great option which gives you an opportunity to see all the cha
|
|
471 |
|
472 |
**Something is not working. What do I do?**
|
473 |
|
474 |
-
Contact us! Depending on your server configuration something may go wrong, please don't hesitate on contacting us, we are here to help you! Our support email is:
|
475 |
|
476 |
**Everything works PERFECT. What do I do?**
|
477 |
|
41 |
* Redirect user to another page when he/she clicks on popup content
|
42 |
* Show/Hide Popup for selected User Roles (Admin panel)
|
43 |
* Responsive popup
|
44 |
+
* Scale popup for desktop sizes
|
45 |
* Network/Multisite popup
|
46 |
* On click popup
|
47 |
* Html popup
|
118 |
</div>
|
119 |
|
120 |
<div>
|
121 |
+
If you think that you found a bug in our Popup Builder plugin or have any questions, please feel free to contact us at <a href="mailto:support@popup-builder.com" title="support@popup-builder.com"><strong>support@popup-builder.com</strong></a>.
|
122 |
### Popup Builder
|
123 |
</div>
|
124 |
</div>
|
153 |
|
154 |
== Changelog ==
|
155 |
|
156 |
+
= Version 2.3.7 =
|
157 |
+
* New option: Popup scaling.
|
158 |
+
* New option: Availability to customize 3rd theme. Ex (border-radius, border-color)
|
159 |
+
* Bug fixes and code optimization.
|
160 |
+
|
161 |
= Version 2.3.6 =
|
162 |
* Show/Hide Popup for selected User Roles (Admin panel) (Free)
|
163 |
* Bug fixed connected to 3rd party shortcodes
|
477 |
|
478 |
**Something is not working. What do I do?**
|
479 |
|
480 |
+
Contact us! Depending on your server configuration something may go wrong, please don't hesitate on contacting us, we are here to help you! Our support email is: support@popup-builder.com
|
481 |
|
482 |
**Everything works PERFECT. What do I do?**
|
483 |
|
style/sg_popup_style.css
CHANGED
@@ -7,7 +7,7 @@
|
|
7 |
display: none;
|
8 |
}
|
9 |
|
10 |
-
.sg-margin0 {
|
11 |
margin: 0;
|
12 |
}
|
13 |
|
@@ -1156,7 +1156,7 @@ input[name="theme"] {
|
|
1156 |
|
1157 |
/*Settings tabe style*/
|
1158 |
.sg-settings-wrapper {
|
1159 |
-
width: 50%;
|
1160 |
}
|
1161 |
|
1162 |
.sg-selectbox {
|
@@ -1167,6 +1167,15 @@ input[name="theme"] {
|
|
1167 |
margin-top: 15px;
|
1168 |
}
|
1169 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1170 |
@media only screen and (min-width:800px) {
|
1171 |
.sgmb-container {
|
1172 |
min-width:800px;
|
7 |
display: none;
|
8 |
}
|
9 |
|
10 |
+
.sg-margin0 {
|
11 |
margin: 0;
|
12 |
}
|
13 |
|
1156 |
|
1157 |
/*Settings tabe style*/
|
1158 |
.sg-settings-wrapper {
|
1159 |
+
width: 50%;
|
1160 |
}
|
1161 |
|
1162 |
.sg-selectbox {
|
1167 |
margin-top: 15px;
|
1168 |
}
|
1169 |
|
1170 |
+
.sg-label-div,.sg-options-content-div {
|
1171 |
+
display: inline-block;
|
1172 |
+
height: 200px;
|
1173 |
+
}
|
1174 |
+
|
1175 |
+
.schedule-main-div-content {
|
1176 |
+
margin-bottom: 5px;
|
1177 |
+
}
|
1178 |
+
|
1179 |
@media only screen and (min-width:800px) {
|
1180 |
.sgmb-container {
|
1181 |
min-width:800px;
|