Page Builder: PageLayer – Drag and Drop website builder - Version 1.1.3

Version Description

(May 19, 2020) = * [Premium-Feature] Added new Timeline widget for our Pro users. You can now create beautiful timelines of your work by just dragging the widget ! * [Premium-Feature] Added option to add custom attributes for the element in options property bar. * [Premium-Feature] Added file option in contact form item. Now user can add file upload option in contact form. * [Improvement] Group property has been further improved. Now user can sort the group items. * [Improvement] The update button UI has been improved. * [Improvement] The "Progress Bar" widget has been improved. Added background color, border-radius, prefix and sufix options. * [Bug-Fix] In the premium audio widget the width was not working properly. This is fixed. * [Bug-Fix] In the Author box widget, the custome biography set was not visible. This is fixed.

Download this release

Release Info

Developer pagelayer
Plugin Icon 128x128 Page Builder: PageLayer – Drag and Drop website builder
Version 1.1.3
Comparing to
See all releases

Code changes from version 1.1.2 to 1.1.3

css/pagelayer-editor.css CHANGED
@@ -289,6 +289,7 @@ bottom:100%;
289
color:#fff;
290
background-color: #3e8ef7;
291
display:none;
292
}
293
294
.pagelayer-leftbar-toggle-h{
@@ -828,7 +829,7 @@ text-transform: unset;
828
border: 1px solid #00A0D2;
829
font-weight: unset;
830
font-size: 12px;
831
- padding: 12px 10px;
832
min-height: unset;
833
background-color: #00A0D2;
834
color: #fff;
@@ -1869,6 +1870,10 @@ position:relative;
1869
border-radius: 2px !important;
1870
}
1871
1872
.pagelayer-elp-select-div,
1873
.pagelayer-elp-spinner-div{
1874
width: 140px;
@@ -1970,6 +1975,10 @@ display:inline-block;
1970
color:#bdbdbd;
1971
}
1972
1973
.pagelayer-elp-group-item-title{
1974
flex-grow: 100;
1975
white-space: nowrap;
@@ -3105,6 +3114,9 @@ width: 8em
3105
#pagelayer-loader-wrapper .pagelayer-animation-section .pagelayer-txt-loading {
3106
font: bold 3.5em Poppins, sans-serif
3107
}
3108
}
3109
@media screen and (max-width: 500px) {
3110
#pagelayer-loader-wrapper .pagelayer-animation-section .pagelayer-loader {
@@ -3114,9 +3126,51 @@ width: 7em
3114
#pagelayer-loader-wrapper .pagelayer-animation-section .pagelayer-txt-loading {
3115
font: bold 2em Poppins, sans-serif
3116
}
3117
}
3118
3119
/* Pre-Loading animaiton classes end*/
3120
/* Property modal start*/
3121
.pagelayer-elp-modal-wrapper{
3122
position: fixed;
289
color:#fff;
290
background-color: #3e8ef7;
291
display:none;
292
+ z-index:1;
293
}
294
295
.pagelayer-leftbar-toggle-h{
829
border: 1px solid #00A0D2;
830
font-weight: unset;
831
font-size: 12px;
832
+ margin:5px;
833
min-height: unset;
834
background-color: #00A0D2;
835
color: #fff;
1870
border-radius: 2px !important;
1871
}
1872
1873
+ .pagelayer-elp-text{
1874
+ padding-left:5px;
1875
+ }
1876
+
1877
.pagelayer-elp-select-div,
1878
.pagelayer-elp-spinner-div{
1879
width: 140px;
1975
color:#bdbdbd;
1976
}
1977
1978
+ .pagelayer-elp-group-item-head .pagelayer-elp-group-item-drag:hover {
1979
+ cursor:all-scroll;
1980
+ }
1981
+
1982
.pagelayer-elp-group-item-title{
1983
flex-grow: 100;
1984
white-space: nowrap;
3114
#pagelayer-loader-wrapper .pagelayer-animation-section .pagelayer-txt-loading {
3115
font: bold 3.5em Poppins, sans-serif
3116
}
3117
+ .pagelayer-loader .pagelayer-percent-parent .pagelayer-percent{
3118
+ font-size:20px;
3119
+ }
3120
}
3121
@media screen and (max-width: 500px) {
3122
#pagelayer-loader-wrapper .pagelayer-animation-section .pagelayer-loader {
3126
#pagelayer-loader-wrapper .pagelayer-animation-section .pagelayer-txt-loading {
3127
font: bold 2em Poppins, sans-serif
3128
}
3129
+ .pagelayer-loader .pagelayer-percent-parent .pagelayer-percent{
3130
+ font-size:15px;
3131
+ }
3132
}
3133
3134
/* Pre-Loading animaiton classes end*/
3135
+
3136
+ /* Update Loading animation class start */
3137
+
3138
+ .pagelayer-update-button{
3139
+ width:58px;
3140
+ height:24px;
3141
+ }
3142
+
3143
+ .pagelayer-update-loader{
3144
+ display:none;
3145
+ padding:2px;
3146
+ }
3147
+
3148
+ .pagelayer-update-loader span{
3149
+ width:8px;
3150
+ height:8px;
3151
+ margin: 0 2px;
3152
+ background-color: #ededede0;
3153
+ border-radius: 50%;
3154
+ display:inline-block;
3155
+ animation: dots 0.9s ease-in-out infinite;
3156
+ }
3157
+
3158
+ .pagelayer-update-loader span:nth-child(2){
3159
+ animation-delay: 0.3s;
3160
+ }
3161
+
3162
+ .pagelayer-update-loader span:nth-child(3){
3163
+ animation-delay: 0.6s;
3164
+ }
3165
+
3166
+ @keyframes dots{
3167
+ 50%{
3168
+ opacity:0;
3169
+ }
3170
+ }
3171
+
3172
+ /* Update Loading animation class end */
3173
+
3174
/* Property modal start*/
3175
.pagelayer-elp-modal-wrapper{
3176
position: fixed;
css/pagelayer-frontend.css CHANGED
@@ -1831,7 +1831,7 @@ text-align: center
1831
padding: 0 3px;
1832
}
1833
1834
- .pagelayer-audio-container audio{
1835
width:100%;
1836
}
1837
@@ -1903,6 +1903,10 @@ font-size: 12px;
1903
/* Testimonial End */
1904
1905
/* Progress bar */
1906
.pagelayer-progress-container{
1907
background-color:#eeeeee;
1908
}
@@ -2754,6 +2758,7 @@ display:block;
2754
.pagelayer-text-holder *{
2755
padding: 0;
2756
margin: 0;
2757
}
2758
2759
/* animation */
1831
padding: 0 3px;
1832
}
1833
1834
+ .pagelayer-audio-container, .pagelayer-audio-container audio{
1835
width:100%;
1836
}
1837
1903
/* Testimonial End */
1904
1905
/* Progress bar */
1906
+ .pagelayer-progress-goal{
1907
+ margin-top: 10px;
1908
+ }
1909
+
1910
.pagelayer-progress-container{
1911
background-color:#eeeeee;
1912
}
2758
.pagelayer-text-holder *{
2759
padding: 0;
2760
margin: 0;
2761
+ overflow-wrap: break-word;
2762
}
2763
2764
/* animation */
css/pagelayer-icons.css CHANGED
@@ -322,6 +322,10 @@ content: "\e915";
322
.pagelayer-pl_anim_heading:before{
323
content: "\e902";
324
}
325
.pli-social-facebook-circular:before,
326
.pagelayer-pl_fb_comments:before{
327
content: "\e918";
322
.pagelayer-pl_anim_heading:before{
323
content: "\e902";
324
}
325
+ .pagelayer-pl_btn_anim:before{
326
+ content: "\f1b2";
327
+ font-weight: 600;
328
+ }
329
.pli-social-facebook-circular:before,
330
.pagelayer-pl_fb_comments:before{
331
content: "\e918";
init.php CHANGED
@@ -5,7 +5,7 @@ if (!defined('ABSPATH')) exit;
5
6
define('PAGELAYER_BASE', plugin_basename(PAGELAYER_FILE));
7
define('PAGELAYER_PRO_BASE', 'pagelayer-pro/pagelayer-pro.php');
8
- define('PAGELAYER_VERSION', '1.1.2');
9
define('PAGELAYER_DIR', dirname(PAGELAYER_FILE));
10
define('PAGELAYER_SLUG', 'pagelayer');
11
define('PAGELAYER_URL', plugins_url('', PAGELAYER_FILE));
5
6
define('PAGELAYER_BASE', plugin_basename(PAGELAYER_FILE));
7
define('PAGELAYER_PRO_BASE', 'pagelayer-pro/pagelayer-pro.php');
8
+ define('PAGELAYER_VERSION', '1.1.3');
9
define('PAGELAYER_DIR', dirname(PAGELAYER_FILE));
10
define('PAGELAYER_SLUG', 'pagelayer');
11
define('PAGELAYER_URL', plugins_url('', PAGELAYER_FILE));
js/pagelayer-editor.js CHANGED
@@ -2759,6 +2759,10 @@ function pagelayer_get_contact_templates(){
2759
// Save the post
2760
function pagelayer_save(){
2761
2762
pagelayer_trigger_action('pagelayer_save');
2763
2764
var pagelayerajaxurl = pagelayer_ajax_url+'&action=pagelayer_save_content&postID='+pagelayer_postID;
@@ -2799,6 +2803,10 @@ function pagelayer_save(){
2799
},
2800
error: function(errorThrown){
2801
console.log(errorThrown);
2802
}
2803
});
2804
@@ -3433,7 +3441,7 @@ function pagelayer_history_setup(force){
3433
});
3434
}
3435
3436
- // Get evisions Handler
3437
function pagelayer_get_revision(){
3438
3439
jQuery.ajax({
@@ -3677,7 +3685,14 @@ function pagelayer_bottombar(){
3677
var holder = pagelayer.$('.pagelayer-bottombar-holder');
3678
var html = '<div class="pagelayer-bottombar">'+
3679
'<div class="pagelayer-bottombar-rightbuttons">'+
3680
- '<button data-tlite="Save Changes" class="pagelayer-update-button pagelayer-success-btn">Update</button>'+
3681
'<button data-tlite="Close and Return to Admin Panel" class="pagelayer-close-button">Close</button>'+
3682
'<div class="pagelayer-mode-wrapper">'+
3683
'<div class="pagelayer-mode-buttons-wrapper">'+
2759
// Save the post
2760
function pagelayer_save(){
2761
2762
+ // hiding and showing loading animation
2763
+ pagelayer.$('.pagelayer-update-text').hide();
2764
+ pagelayer.$('.pagelayer-update-loader').show();
2765
+
2766
pagelayer_trigger_action('pagelayer_save');
2767
2768
var pagelayerajaxurl = pagelayer_ajax_url+'&action=pagelayer_save_content&postID='+pagelayer_postID;
2803
},
2804
error: function(errorThrown){
2805
console.log(errorThrown);
2806
+ },
2807
+ complete: function(xhr,status){
2808
+ pagelayer.$('.pagelayer-update-text').show();
2809
+ pagelayer.$('.pagelayer-update-loader').hide();
2810
}
2811
});
2812
3441
});
3442
}
3443
3444
+ // Get revisions Handler
3445
function pagelayer_get_revision(){
3446
3447
jQuery.ajax({
3685
var holder = pagelayer.$('.pagelayer-bottombar-holder');
3686
var html = '<div class="pagelayer-bottombar">'+
3687
'<div class="pagelayer-bottombar-rightbuttons">'+
3688
+ '<button data-tlite="Save Changes" class="pagelayer-update-button pagelayer-success-btn">'+
3689
+ '<span class="pagelayer-update-loader">'+
3690
+ '<span></span>'+
3691
+ '<span></span>'+
3692
+ '<span></span>'+
3693
+ '</span>'+
3694
+ '<span class="pagelayer-update-text">Update</span>'+
3695
+ '</button>'+
3696
'<button data-tlite="Close and Return to Admin Panel" class="pagelayer-close-button">Close</button>'+
3697
'<div class="pagelayer-mode-wrapper">'+
3698
'<div class="pagelayer-mode-buttons-wrapper">'+
js/pagelayer-frontend.js CHANGED
@@ -679,6 +679,9 @@ function pagelayer_fetch_dataAttrs(ele, prefix){
679
0:{items: 1},
680
500:{items: options['items']}
681
}
682
// If we are in editor don't loop the Owl items
683
if (window.location.href.indexOf('pagelayer-live=1') > -1) {
684
//console.log('here');
@@ -698,7 +701,12 @@ function pagelayer_owl_init(jEle, ul, options){
698
return true;
699
}
700
701
- ul.pagelayerOwlCarousel(options);
702
703
// Set that we have setup everything
704
jEle.attr('pagelayer-setup', 1);
679
0:{items: 1},
680
500:{items: options['items']}
681
}
682
+
683
+ options['responsiveRefreshRate'] = 1000;
684
+
685
// If we are in editor don't loop the Owl items
686
if (window.location.href.indexOf('pagelayer-live=1') > -1) {
687
//console.log('here');
701
return true;
702
}
703
704
+ var owlCar = ul.pagelayerOwlCarousel(options);
705
+
706
+ // Refreshing Image slider after first load of page.
707
+ setTimeout(function(){
708
+ owlCar.trigger('refresh.owl.carousel');
709
+ },700);
710
711
// Set that we have setup everything
712
jEle.attr('pagelayer-setup', 1);
js/properties.js CHANGED
@@ -2285,6 +2285,28 @@ function pagelayer_elp_group(row, prop){
2285
});
2286
2287
};
2288
2289
// Handle click of the group
2290
row.find('.pagelayer-elp-button').on('click', function(){
@@ -2299,6 +2321,28 @@ function pagelayer_elp_group(row, prop){
2299
});
2300
};
2301
2302
// The Datetime Property
2303
function pagelayer_elp_datetime(row, prop){
2304
2285
});
2286
2287
};
2288
+
2289
+ // Setup the drag
2290
+ pagelayer.$(".pagelayer-elp-group-div").sortable({
2291
+ axis: 'y',
2292
+ nested : false,
2293
+ vertical : true,
2294
+ handle : ".pagelayer-elp-group-item-drag",
2295
+ start : function(event, ui) {
2296
+ var start_pos = ui.item.index();
2297
+ ui.item.data('start_pos', start_pos);
2298
+ },
2299
+ stop : function(event, ui){
2300
+ var end_pos = ui.item.index();
2301
+ var id = jQuery(ui.item).closest('[pagelayer-group-item-id]').attr('pagelayer-group-item-id');
2302
+ var jEle = jQuery('[pagelayer-id="'+id+'"]');
2303
+ pagelayer_moving_element(jEle, ui.item.data('start_pos'), end_pos);
2304
+ var par = pagelayer_get_parent(jEle);
2305
+ if(par){
2306
+ pagelayer_sc_render(pagelayer_ele_by_id(par));
2307
+ }
2308
+ }
2309
+ });
2310
2311
// Handle click of the group
2312
row.find('.pagelayer-elp-button').on('click', function(){
2321
});
2322
};
2323
2324
+ // Moving an element
2325
+ function pagelayer_moving_element(jEle, start_pos, end_pos){
2326
+ if(start_pos==end_pos){
2327
+ return;
2328
+ }
2329
+
2330
+ var id = pagelayer_assign_id(jEle);
2331
+
2332
+ // Is there a wrap
2333
+ var wrap = pagelayer_wrap_by_id(id);
2334
+
2335
+ var par = wrap.parent();
2336
+ var children = par.children("div");
2337
+
2338
+ var element = children.eq(start_pos).detach();
2339
+ if(end_pos < start_pos){
2340
+ children.eq(end_pos).before(element);
2341
+ }else{
2342
+ children.eq(end_pos).after(element);
2343
+ }
2344
+ }
2345
+
2346
// The Datetime Property
2347
function pagelayer_elp_datetime(row, prop){
2348
languages/en.json CHANGED
@@ -202,9 +202,9 @@
202
"ribbion_display": "Display",
203
"ribbion_text": "Text",
204
"currency_color": "Currency Color",
205
- "currency_size": "Currency Size",
206
- "price_size": "Price Size",
207
- "old_price_size": "Old Price Size",
208
"price_state": "State",
209
"Hover": "Hover",
210
"price_line_height": "Line Height",
@@ -231,7 +231,7 @@
231
"btn_border_width": "Border Width",
232
"btn_border_radius": "Border Radius",
233
"btn_padding": "Padding",
234
- "ribbon_text_size": "Size",
235
"addition_info" : "Additional Information",
236
"currency_style": "Currency",
237
"price_style": "Price",
@@ -1704,5 +1704,25 @@
1704
"create_mail_templ" : "Create Mail Template",
1705
"use_html" : "Use HTML",
1706
"custom_templ" : "Use Custom Template",
1707
- "technology" : "Technology"
1708
}
202
"ribbion_display": "Display",
203
"ribbion_text": "Text",
204
"currency_color": "Currency Color",
205
+ "currency_size": "Currency Font Style",
206
+ "price_size": "Price Font Style",
207
+ "old_price_size": "Old Price Font Style",
208
"price_state": "State",
209
"Hover": "Hover",
210
"price_line_height": "Line Height",
231
"btn_border_width": "Border Width",
232
"btn_border_radius": "Border Radius",
233
"btn_padding": "Padding",
234
+ "ribbon_text_size": "Ribbon Font Style",
235
"addition_info" : "Additional Information",
236
"currency_style": "Currency",
237
"price_style": "Price",
1704
"create_mail_templ" : "Create Mail Template",
1705
"use_html" : "Use HTML",
1706
"custom_templ" : "Use Custom Template",
1707
+ "technology" : "Technology",
1708
+ "row_data_padding" : "Row Data Padding",
1709
+ "timeline_item" : "Timeline Item",
1710
+ "add_timeline_item" : "Add Timeline Item",
1711
+ "side" : "Side",
1712
+ "both" : "Both",
1713
+ "radius" : "Radius",
1714
+ "icon_size" : "Icon Size",
1715
+ "heading_color" : "Heading Color",
1716
+ "image_hover" : "Image Hover",
1717
+ "timeline_center_circle" : "Timeline Center Circle",
1718
+ "bio_color" : "Bio Color",
1719
+ "bio_typo" : "Bio Typography",
1720
+ "bio_gap" : "Bio Gap",
1721
+ "input_hover_delay_label" : "Hover Speed",
1722
+ "normal_button" : "Normal",
1723
+ "glow_button" : "Glow",
1724
+ "thin_button" : "Thin",
1725
+ "slide_button" : "Slide",
1726
+ "btn_anim" : "Hover Me",
1727
+ "file" : "File"
1728
}
main/ajax.php CHANGED
@@ -850,8 +850,10 @@ function pagelayer_contact_submit(){
850
// Some AJAX security
851
check_ajax_referer('pagelayer_global', 'pagelayer_nonce');
852
853
- $fdata = $_POST['form_data'];
854
- parse_str($fdata, $formdata);
855
856
$to_mail = get_option('pagelayer_cf_to_email');
857
$from_mail = get_option('pagelayer_cf_from_email');
@@ -909,7 +911,7 @@ function pagelayer_contact_submit(){
909
$headers .= "From: $from_mail\n";
910
}
911
912
- if ( empty($additional_headers) ) {
913
$headers .= $additional_headers . "\n";
914
}
915
@@ -930,11 +932,16 @@ function pagelayer_contact_submit(){
930
931
}
932
933
// Do parse a variables
934
$to_mail = pagelayer_replace_vars($to_mail, $formdata, '#x27;);
935
$from_mail = pagelayer_replace_vars($from_mail, $formdata, '#x27;);
936
$subject = pagelayer_replace_vars($subject, $formdata, '#x27;);
937
- $additional_headers = pagelayer_replace_vars($additional_headers, $formdata, '#x27;);
938
$body = pagelayer_replace_vars($body, $formdata, '#x27;);
939
940
if ( $use_html && ! preg_match( '%<html[>\s].*</html>%is', $body ) ) {
850
// Some AJAX security
851
check_ajax_referer('pagelayer_global', 'pagelayer_nonce');
852
853
+ $formdata = $_POST;
854
+
855
+ // Unset the nonce
856
+ unset($formdata['pagelayer_nonce']);
857
858
$to_mail = get_option('pagelayer_cf_to_email');
859
$from_mail = get_option('pagelayer_cf_from_email');
911
$headers .= "From: $from_mail\n";
912
}
913
914
+ if ( !empty($additional_headers) ) {
915
$headers .= $additional_headers . "\n";
916
}
917
932
933
}
934
935
+ // Add attachment
936
+ if(!empty($_FILES)){
937
+ add_action('phpmailer_init', 'pagelayer_cf_email_attachment', 10, 1);
938
+ }
939
+
940
// Do parse a variables
941
$to_mail = pagelayer_replace_vars($to_mail, $formdata, '#x27;);
942
$from_mail = pagelayer_replace_vars($from_mail, $formdata, '#x27;);
943
$subject = pagelayer_replace_vars($subject, $formdata, '#x27;);
944
+ $headers = pagelayer_replace_vars($headers, $formdata, '#x27;);
945
$body = pagelayer_replace_vars($body, $formdata, '#x27;);
946
947
if ( $use_html && ! preg_match( '%<html[>\s].*</html>%is', $body ) ) {
main/functions.php CHANGED
@@ -537,7 +537,7 @@ function pagelayer_memory_limit($mb){
537
// Loads the shortcodes
538
function pagelayer_load_shortcodes(){
539
540
- pagelayer_memory_limit(64);
541
542
include_once(PAGELAYER_DIR.'/main/shortcode_functions.php');
543
if(defined('PAGELAYER_PREMIUM')){
@@ -596,6 +596,7 @@ function pagelayer_add_shortcode($tag, $params = array()){
596
'animation_styles' => __pl('animation_styles'),
597
'motion_effects' => __pl('Motion Effects'),
598
'responsive_styles' => __pl('responsive_styles'),
599
'custom_styles' => __pl('custom_styles'),
600
];
601
@@ -2029,4 +2030,24 @@ function pagelayer_replace_vars( $string, $array, $pre = '', $suf = ''){
2029
$string = str_replace($pre.$kk.$suf, $vv, $string);
2030
}
2031
return $string;
2032
}
537
// Loads the shortcodes
538
function pagelayer_load_shortcodes(){
539
540
+ pagelayer_memory_limit(128);
541
542
include_once(PAGELAYER_DIR.'/main/shortcode_functions.php');
543
if(defined('PAGELAYER_PREMIUM')){
596
'animation_styles' => __pl('animation_styles'),
597
'motion_effects' => __pl('Motion Effects'),
598
'responsive_styles' => __pl('responsive_styles'),
599
+ 'attributes' => __pl('Attributes'),
600
'custom_styles' => __pl('custom_styles'),
601
];
602
2030
$string = str_replace($pre.$kk.$suf, $vv, $string);
2031
}
2032
return $string;
2033
+ }
2034
+
2035
+ // Add Attachment to the contact the email
2036
+ function pagelayer_cf_email_attachment( &$phpmailer) {
2037
+
2038
+ if ( ! empty( $_FILES ) ) {
2039
+ foreach ( $_FILES as $attachment ) {
2040
+
2041
+ if(empty($attachment['name'])){
2042
+ continue;
2043
+ }
2044
+
2045
+ try {
2046
+ $phpmailer->addAttachment($attachment['tmp_name'], $attachment['name'], $encoding = 'base64', $attachment['type'], $disposition = 'attachment');
2047
+ } catch ( phpmailerException $e ) {
2048
+ continue;
2049
+ }
2050
+ }
2051
+ }
2052
+
2053
}
main/settings.php CHANGED
@@ -155,85 +155,60 @@ echo '
155
156
function pagelayer_settings_page(){
157
158
- $option_name = 'pl_gen_setting' ;
159
- $new_value = '';
160
-
161
- if(isset($_REQUEST['submit'])){
162
- check_admin_referer('pagelayer-options');
163
- }
164
165
- if(isset($_REQUEST['pl_gen_setting'])){
166
- $new_value = $_REQUEST['pl_gen_setting'];
167
168
- if ( get_option( $option_name ) !== false ) {
169
-
170
- // The option already exists, so we just update it.
171
- update_option( $option_name, $new_value );
172
-
173
- } else {
174
-
175
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
176
- $deprecated = null;
177
- $autoload = 'no';
178
- add_option( $option_name, $new_value, $deprecated, $autoload );
179
}
180
181
}
182
183
if(isset($_REQUEST['pl_support_ept'])){
184
185
$pl_support_ept = $_REQUEST['pl_support_ept'];
186
187
- if ( get_option( 'pl_support_ept' ) !== false ) {
188
-
189
- // The option already exists, so we just update it.
190
- update_option( 'pl_support_ept', $pl_support_ept );
191
-
192
- } else {
193
-
194
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
195
- $deprecated = null;
196
- $autoload = 'no';
197
- $pl_support_ept = ['post', 'page'];
198
- add_option( 'pl_support_ept', $pl_support_ept, $deprecated, $autoload );
199
}
200
}
201
202
203
-
204
if(isset($_REQUEST['pagelayer_icons_set'])){
205
$pagelayer_icons_set = $_REQUEST['pagelayer_icons_set'];
206
207
- if ( get_option( 'pagelayer_icons_set' ) !== false ) {
208
-
209
- // The option already exists, so we just update it.
210
- update_option( 'pagelayer_icons_set', $pagelayer_icons_set);
211
-
212
- } else {
213
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
214
- $deprecated = null;
215
- $autoload = 'no';
216
- //$pagelayer_icons_set = [];
217
- add_option( 'pagelayer_icons_set', $pagelayer_icons_set, $deprecated, $autoload );
218
- }
219
}
220
221
if(isset($_REQUEST['pagelayer_content_width'])){
222
223
$content_width = $_REQUEST['pagelayer_content_width'];
224
225
- if ( get_option( 'pagelayer_content_width' ) !== false ) {
226
-
227
- // The option already exists, so we just update it.
228
- update_option( 'pagelayer_content_width', $content_width );
229
-
230
- } else {
231
-
232
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
233
- $deprecated = null;
234
- $autoload = 'no';
235
- add_option( 'pagelayer_content_width', $content_width, $deprecated, $autoload );
236
- }
237
}
238
239
// Tablet breakpoint
@@ -241,18 +216,8 @@ function pagelayer_settings_page(){
241
242
$tablet_breakpoint = $_REQUEST['pagelayer_tablet_breakpoint'];
243
244
- if ( get_option( 'pagelayer_tablet_breakpoint' ) !== false ) {
245
-
246
- // The option already exists, so we just update it.
247
- update_option( 'pagelayer_tablet_breakpoint', $tablet_breakpoint );
248
-
249
- } else {
250
-
251
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
252
- $deprecated = null;
253
- $autoload = 'no';
254
- add_option( 'pagelayer_tablet_breakpoint', $tablet_breakpoint, $deprecated, $autoload );
255
- }
256
}
257
258
@@ -261,54 +226,24 @@ function pagelayer_settings_page(){
261
262
$tablet_breakpoint = $_REQUEST['pagelayer_mobile_breakpoint'];
263
264
- if ( get_option( 'pagelayer_mobile_breakpoint' ) !== false ) {
265
-
266
- // The option already exists, so we just update it.
267
- update_option( 'pagelayer_mobile_breakpoint', $tablet_breakpoint );
268
-
269
- } else {
270
-
271
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
272
- $deprecated = null;
273
- $autoload = 'no';
274
- add_option( 'pagelayer_mobile_breakpoint', $tablet_breakpoint, $deprecated, $autoload );
275
- }
276
}
277
278
if(isset($_REQUEST['pagelayer_between_widgets'])){
279
280
$space_widgets = $_REQUEST['pagelayer_between_widgets'];
281
282
- if ( get_option( 'pagelayer_between_widgets' ) !== false ) {
283
-
284
- // The option already exists, so we just update it.
285
- update_option( 'pagelayer_between_widgets', $space_widgets );
286
-
287
- } else {
288
-
289
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
290
- $deprecated = null;
291
- $autoload = 'no';
292
- add_option( 'pagelayer_between_widgets', $space_widgets, $deprecated, $autoload );
293
- }
294
}
295
296
if(isset($_REQUEST['pagelayer_body_font'])){
297
298
$body_font = $_REQUEST['pagelayer_body_font'];
299
300
- if ( get_option( 'pagelayer_body_font' ) !== false ) {
301
-
302
- // The option already exists, so we just update it.
303
- update_option( 'pagelayer_body_font', $body_font );
304
-
305
- } else {
306
-
307
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
308
- $deprecated = null;
309
- $autoload = 'no';
310
- add_option( 'pagelayer_body_font', $body_font, $deprecated, $autoload );
311
- }
312
}
313
314
$socials = ['pagelayer-facebook-url','pagelayer-twitter-url','pagelayer-instagram-url','pagelayer-linkedin-url','pagelayer-youtube-url','pagelayer-gplus-url','pagelayer-copyright','pagelayer-phone','pagelayer-address'];
@@ -324,18 +259,8 @@ function pagelayer_settings_page(){
324
325
$to_email = $_REQUEST['pagelayer_cf_to_email'];
326
327
- if ( get_option( 'pagelayer_cf_to_email' ) !== false ) {
328
-
329
- // The option already exists, so we just update it.
330
- update_option( 'pagelayer_cf_to_email', $to_email );
331
-
332
- } else {
333
-
334
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
335
- $deprecated = null;
336
- $autoload = 'no';
337
- add_option( 'pagelayer_cf_to_email', $to_email, $deprecated, $autoload );
338
- }
339
}
340
341
if(defined('PAGELAYER_PREMIUM')){
@@ -344,108 +269,48 @@ function pagelayer_settings_page(){
344
345
$subject = $_REQUEST['pagelayer_cf_subject'];
346
347
- if ( get_option( 'pagelayer_cf_subject' ) !== false ) {
348
-
349
- // The option already exists, so we just update it.
350
- update_option( 'pagelayer_cf_subject', $subject );
351
-
352
- } else {
353
-
354
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
355
- $deprecated = null;
356
- $autoload = 'no';
357
- add_option( 'pagelayer_cf_subject', $subject, $deprecated, $autoload );
358
- }
359
}
360
361
if(isset($_REQUEST['pagelayer_cf_headers'])){
362
363
$subject = $_REQUEST['pagelayer_cf_headers'];
364
365
- if ( get_option( 'pagelayer_cf_headers' ) !== false ) {
366
-
367
- // The option already exists, so we just update it.
368
- update_option( 'pagelayer_cf_headers', $subject );
369
-
370
- } else {
371
-
372
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
373
- $deprecated = null;
374
- $autoload = 'no';
375
- add_option( 'pagelayer_cf_headers', $subject, $deprecated, $autoload );
376
- }
377
}
378
379
if(isset($_REQUEST['pagelayer_cf_from_email'])){
380
381
$subject = $_REQUEST['pagelayer_cf_from_email'];
382
383
- if ( get_option( 'pagelayer_cf_from_email' ) !== false ) {
384
-
385
- // The option already exists, so we just update it.
386
- update_option( 'pagelayer_cf_from_email', $subject );
387
-
388
- } else {
389
-
390
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
391
- $deprecated = null;
392
- $autoload = 'no';
393
- add_option( 'pagelayer_cf_from_email', $subject, $deprecated, $autoload );
394
- }
395
}
396
397
if(isset($_REQUEST['pagelayer_cf_success'])){
398
399
$success = $_REQUEST['pagelayer_cf_success'];
400
401
- if ( get_option( 'pagelayer_cf_success' ) !== false ) {
402
-
403
- // The option already exists, so we just update it.
404
- update_option( 'pagelayer_cf_success', $success );
405
-
406
- } else {
407
-
408
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
409
- $deprecated = null;
410
- $autoload = 'no';
411
- add_option( 'pagelayer_cf_success', $success, $deprecated, $autoload );
412
- }
413
}
414
415
if(isset($_REQUEST['pagelayer_cf_failed'])){
416
417
$failed = $_REQUEST['pagelayer_cf_failed'];
418
419
- if ( get_option( 'pagelayer_cf_failed' ) !== false ) {
420
-
421
- // The option already exists, so we just update it.
422
- update_option( 'pagelayer_cf_failed', $failed );
423
-
424
- } else {
425
-
426
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
427
- $deprecated = null;
428
- $autoload = 'no';
429
- add_option( 'pagelayer_cf_failed', $failed, $deprecated, $autoload );
430
- }
431
}
432
433
if(isset($_REQUEST['pagelayer_google_captcha'])){
434
435
$captcha = $_REQUEST['pagelayer_google_captcha'];
436
437
- if ( get_option( 'pagelayer_google_captcha' ) !== false ) {
438
-
439
- // The option already exists, so we just update it.
440
- update_option( 'pagelayer_google_captcha', $captcha );
441
-
442
- } else {
443
-
444
- // The option hasn't been added yet. We'll add it with $autoload set to 'no'.
445
- $deprecated = null;
446
- $autoload = 'no';
447
- add_option( 'pagelayer_google_captcha', $captcha, $deprecated, $autoload );
448
- }
449
}
450
451
// Facebook APP ID
@@ -467,13 +332,6 @@ function pagelayer_settings_page(){
467
}
468
}
469
470
- $post_type = array('post', 'page', 'product');
471
-
472
- $support_ept = get_option( 'pl_support_ept', ['post', 'page']);
473
- foreach ( $support_ept as $support_pl ) {
474
- add_post_type_support( $support_pl, 'pagelayer' );
475
- }
476
-
477
pagelayer_page_header('Pagelayer Settings');
478
479
?>
@@ -501,9 +359,8 @@ function pagelayer_settings_page(){
501
<td>
502
<label>
503
<?php
504
- foreach($post_type as $type){
505
-
506
- echo '<input type="checkbox" name="pl_support_ept[]" value="'.$type.'" '. (in_array($type, $support_ept) ? "checked" : "") .'/>'.$type.'</br>';
507
}
508
?>
509
</label>
155
156
function pagelayer_settings_page(){
157
158
+ $post_type = array();
159
+ $exclude = [ 'attachment', 'pagelayer-template' ];
160
+ $pt_objects = get_post_types(['public' => true,], 'objects');
161
162
+ foreach ( $pt_objects as $pt_slug => $type ) {
163
164
+ if ( in_array( $pt_slug, $exclude ) ) {
165
+ continue;
166
}
167
+
168
+ $post_type[$pt_slug] = $type->labels->name;
169
+ }
170
+
171
+ $support_ept = get_option( 'pl_support_ept', ['post', 'page']);
172
173
+ $option_name = 'pl_gen_setting';
174
+ $new_value = '';
175
+
176
+ if(isset($_REQUEST['submit'])){
177
+ check_admin_referer('pagelayer-options');
178
}
179
180
if(isset($_REQUEST['pl_support_ept'])){
181
182
$pl_support_ept = $_REQUEST['pl_support_ept'];
183
184
+ foreach($pl_support_ept as $k => $v){
185
+ if(empty($post_type[$v])){
186
+ unset($pl_support_ept[$k]);
187
+ }
188
}
189
+
190
+ // Update it
191
+ update_option('pl_support_ept', $pl_support_ept );
192
+
193
+ $support_ept = get_option( 'pl_support_ept');
194
+
195
}
196
197
198
if(isset($_REQUEST['pagelayer_icons_set'])){
199
$pagelayer_icons_set = $_REQUEST['pagelayer_icons_set'];
200
201
+ // Update it
202
+ update_option('pagelayer_icons_set', $pagelayer_icons_set);
203
}
204
205
+
206
if(isset($_REQUEST['pagelayer_content_width'])){
207
208
$content_width = $_REQUEST['pagelayer_content_width'];
209
210
+ // Update it
211
+ update_option( 'pagelayer_content_width', $content_width );
212
}
213
214
// Tablet breakpoint
216
217
$tablet_breakpoint = $_REQUEST['pagelayer_tablet_breakpoint'];
218
219
+ update_option( 'pagelayer_tablet_breakpoint', $tablet_breakpoint );
220
+
221
}
222
223
226
227
$tablet_breakpoint = $_REQUEST['pagelayer_mobile_breakpoint'];
228
229
+ update_option( 'pagelayer_mobile_breakpoint', $tablet_breakpoint );
230
}
231
232
+
233
if(isset($_REQUEST['pagelayer_between_widgets'])){
234
235
$space_widgets = $_REQUEST['pagelayer_between_widgets'];
236
237
+ update_option( 'pagelayer_between_widgets', $space_widgets );
238
}
239
240
+
241
if(isset($_REQUEST['pagelayer_body_font'])){
242
243
$body_font = $_REQUEST['pagelayer_body_font'];
244
245
+ update_option( 'pagelayer_body_font', $body_font );
246
+
247
}
248
249
$socials = ['pagelayer-facebook-url','pagelayer-twitter-url','pagelayer-instagram-url','pagelayer-linkedin-url','pagelayer-youtube-url','pagelayer-gplus-url','pagelayer-copyright','pagelayer-phone','pagelayer-address'];
259
260
$to_email = $_REQUEST['pagelayer_cf_to_email'];
261
262
+ update_option( 'pagelayer_cf_to_email', $to_email );
263
+
264
}
265
266
if(defined('PAGELAYER_PREMIUM')){
269
270
$subject = $_REQUEST['pagelayer_cf_subject'];
271
272
+ update_option('pagelayer_cf_subject', $subject, 'no');
273
+
274
}
275
276
if(isset($_REQUEST['pagelayer_cf_headers'])){
277
278
$subject = $_REQUEST['pagelayer_cf_headers'];
279
280
+ update_option('pagelayer_cf_headers', $subject, 'no');
281
+
282
}
283
284
if(isset($_REQUEST['pagelayer_cf_from_email'])){
285
286
$subject = $_REQUEST['pagelayer_cf_from_email'];
287
288
+ update_option('pagelayer_cf_from_email', $subject, 'no');
289
+
290
}
291
292
if(isset($_REQUEST['pagelayer_cf_success'])){
293
294
$success = $_REQUEST['pagelayer_cf_success'];
295
296
+ update_option( 'pagelayer_cf_success', $success, 'no');
297
+
298
}
299
300
if(isset($_REQUEST['pagelayer_cf_failed'])){
301
302
$failed = $_REQUEST['pagelayer_cf_failed'];
303
304
+ update_option( 'pagelayer_cf_failed', $failed, 'no');
305
+
306
}
307
308
if(isset($_REQUEST['pagelayer_google_captcha'])){
309
310
$captcha = $_REQUEST['pagelayer_google_captcha'];
311
312
+ update_option( 'pagelayer_google_captcha', $captcha );
313
+
314
}
315
316
// Facebook APP ID
332
}
333
}
334
335
pagelayer_page_header('Pagelayer Settings');
336
337
?>
359
<td>
360
<label>
361
<?php
362
+ foreach($post_type as $type => $name){
363
+ echo '<input type="checkbox" name="pl_support_ept[]" value="'.$type.'" '. (in_array($type, $support_ept) ? "checked" : "") .'/>'.$name.'</br>';
364
}
365
?>
366
</label>
main/shortcode_functions.php CHANGED
@@ -109,7 +109,7 @@ function pagelayer_render_shortcode($atts, $content = '', $tag = ''){
109
$set = true;
110
111
foreach($param['req'] as $rk => $reqval){
112
- $except = $rk{0} == '!' ? true : false;
113
$rk = $except ? substr($rk, 1) : $rk;
114
$val = @$el['atts'][$rk];
115
@@ -218,7 +218,7 @@ function pagelayer_render_shortcode($atts, $content = '', $tag = ''){
218
219
}
220
221
- // Handle the AddClasses
222
if(!empty($param['addAttr']) && !empty($el['atts'][$prop])){
223
224
// Convert to an array
@@ -399,7 +399,7 @@ function pagelayer_render_shortcode($atts, $content = '', $tag = ''){
399
$div .= '</div>';
400
401
// Add classes and attributes
402
- if(!empty($el['classes']) || !empty($el['attr'])){
403
404
// Create the HTML object
405
$node = pQuery::parseStr($div);
@@ -469,6 +469,19 @@ function pagelayer_render_shortcode($atts, $content = '', $tag = ''){
469
}
470
471
}
472
473
$div = $node->html();
474
//die($div);
109
$set = true;
110
111
foreach($param['req'] as $rk => $reqval){
112
+ $except = $rk[0] == '!' ? true : false;
113
$rk = $except ? substr($rk, 1) : $rk;
114
$val = @$el['atts'][$rk];
115
218
219
}
220
221
+ // Handle the AddAttributes
222
if(!empty($param['addAttr']) && !empty($el['atts'][$prop])){
223
224
// Convert to an array
399
$div .= '</div>';
400
401
// Add classes and attributes
402
+ if(!empty($el['classes']) || !empty($el['attr']) || !empty($el['atts']['ele_attributes'])){
403
404
// Create the HTML object
405
$node = pQuery::parseStr($div);
469
}
470
471
}
472
+
473
+ // Adding Custom Attributes
474
+ if(!empty($el['atts']['ele_attributes'])){
475
+
476
+ $val = explode(';', $el['atts']['ele_attributes']);
477
+ foreach($val as $value){
478
+ if(strpos($value, '=')){
479
+ $att = explode('=', $value);
480
+ $node->query($el['selector'])->attr($att[0], $att[1]);
481
+ }
482
+ }
483
+
484
+ }
485
486
$div = $node->html();
487
//die($div);
main/shortcodes.php CHANGED
@@ -1674,6 +1674,17 @@ $pagelayer->styles['responsive_styles'] = [
1674
],
1675
];
1676
1677
// Custom stuff
1678
$pagelayer->styles['custom_styles'] = [
1679
'ele_id' => [
1674
],
1675
];
1676
1677
+ // Custom attributes
1678
+ $pagelayer->styles['attributes'] = [
1679
+ 'ele_attributes' => [
1680
+ 'type' => 'textarea',
1681
+ 'label' => __pl('Attribute'),
1682
+ 'rows' => 5,
1683
+ 'pro' => 1,
1684
+ 'desc' => 'like key="value", Syntax - key1=value1;key2=value2;'
1685
+ ],
1686
+ ];
1687
+
1688
// Custom stuff
1689
$pagelayer->styles['custom_styles'] = [
1690
'ele_id' => [
pagelayer.php CHANGED
@@ -3,7 +3,7 @@
3
Plugin Name: PageLayer
4
Plugin URI: http://wordpress.org/plugins/pagelayer/
5
Description: PageLayer is a WordPress page builder plugin. Its very easy to use and very light on the browser.
6
- Version: 1.1.2
7
Author: Pagelayer Team
8
Author URI: https://pagelayer.com/
9
License: LGPL v2.1
3
Plugin Name: PageLayer
4
Plugin URI: http://wordpress.org/plugins/pagelayer/
5
Description: PageLayer is a WordPress page builder plugin. Its very easy to use and very light on the browser.
6
+ Version: 1.1.3
7
Author: Pagelayer Team
8
Author URI: https://pagelayer.com/
9
License: LGPL v2.1
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: page builder, editor, landing page, drag-and-drop, pagelayer, form-builder
4
Requires at least: 4.7
5
Tested up to: 5.4
6
Requires PHP: 5.5
7
- Stable tag: 1.1.2
8
License: LGPL v2.1
9
License URI: http://www.gnu.org/licenses/lgpl-2.1.html
10
@@ -109,6 +109,16 @@ Do you have questions related to PageLayer ? Use the following links :
109
110
== Changelog ==
111
112
= 1.1.2 (May 6, 2020) =
113
* [Security] For security reasons, we have changed the nonce names for the editor and for non-editor tasks. We urge all users to update to Pagelayer 1.1.2 as soon as possible.
114
4
Requires at least: 4.7
5
Tested up to: 5.4
6
Requires PHP: 5.5
7
+ Stable tag: 1.1.3
8
License: LGPL v2.1
9
License URI: http://www.gnu.org/licenses/lgpl-2.1.html
10
109
110
== Changelog ==
111
112
+ = 1.1.3 (May 19, 2020) =
113
+ * [Premium-Feature] Added new Timeline widget for our Pro users. You can now create beautiful timelines of your work by just dragging the widget !
114
+ * [Premium-Feature] Added option to add custom attributes for the element in options property bar.
115
+ * [Premium-Feature] Added file option in contact form item. Now user can add file upload option in contact form.
116
+ * [Improvement] Group property has been further improved. Now user can sort the group items.
117
+ * [Improvement] The update button UI has been improved.
118
+ * [Improvement] The "Progress Bar" widget has been improved. Added background color, border-radius, prefix and sufix options.
119
+ * [Bug-Fix] In the premium audio widget the width was not working properly. This is fixed.
120
+ * [Bug-Fix] In the Author box widget, the custome biography set was not visible. This is fixed.
121
+
122
= 1.1.2 (May 6, 2020) =
123
* [Security] For security reasons, we have changed the nonce names for the editor and for non-editor tasks. We urge all users to update to Pagelayer 1.1.2 as soon as possible.
124