Version Description
- Fixes compatibility issue with PHP5.3
Download this release
Release Info
Developer | spwebguy |
Plugin | Responsive Pricing Table |
Version | 5.0.2 |
Comparing to | |
See all releases |
Code changes from version 5.0.1 to 5.0.2
- inc/css/rpt_style.css +0 -0
- inc/css/rpt_style.min.css +0 -0
- inc/dmb/dmb.css +0 -0
- inc/dmb/dmb.js +2 -2
- inc/dmb/dmb.min.css +0 -0
- inc/dmb/dmb.min.js +42 -42
- inc/img/rpt_recommended.png +0 -0
- inc/js/rpt.js +0 -0
- inc/js/rpt.min.js +0 -0
- inc/rpt-admin-scripts.php +1 -1
- inc/rpt-front-scripts.php +0 -0
- inc/rpt-metaboxes-help.php +0 -0
- inc/rpt-metaboxes-plans.php +3 -5
- inc/rpt-metaboxes-pro.php +0 -0
- inc/rpt-metaboxes-settings.php +6 -4
- inc/rpt-post-type.php +0 -0
- inc/rpt-pro-version-check.php +0 -0
- inc/rpt-save-metaboxes.php +0 -0
- inc/rpt-shortcode-column.php +0 -0
- inc/rpt-shortcode.php +0 -0
- inc/rpt-text-domain.php +0 -0
- lang/dk-pricr-responsive-pricing-table.pot +0 -0
- readme.txt +12 -9
- rpt.php +1 -1
inc/css/rpt_style.css
CHANGED
File without changes
|
inc/css/rpt_style.min.css
CHANGED
File without changes
|
inc/dmb/dmb.css
CHANGED
File without changes
|
inc/dmb/dmb.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
/**
|
2 |
* Responsive Pricing Table Admin JS
|
3 |
-
* Last updated: Nov
|
4 |
*/
|
5 |
|
6 |
;(function($){
|
@@ -619,7 +619,7 @@ $(document).ready(function (){
|
|
619 |
|
620 |
// Attaches the preview to container.
|
621 |
(settings.planCount == 0)
|
622 |
-
? $('#dmb_preview_table').append('<
|
623 |
: $('#dmb_preview_table').append(preview_html);
|
624 |
|
625 |
$('#dmb_preview_table').fadeIn(100);
|
1 |
/**
|
2 |
* Responsive Pricing Table Admin JS
|
3 |
+
* Last updated: Nov 29, 2017
|
4 |
*/
|
5 |
|
6 |
;(function($){
|
619 |
|
620 |
// Attaches the preview to container.
|
621 |
(settings.planCount == 0)
|
622 |
+
? $('#dmb_preview_table').append('<div class="dmb_no_plan_preview_notice">' + objectL10n.noPlan + '</div>')
|
623 |
: $('#dmb_preview_table').append(preview_html);
|
624 |
|
625 |
$('#dmb_preview_table').fadeIn(100);
|
inc/dmb/dmb.min.css
CHANGED
File without changes
|
inc/dmb/dmb.min.js
CHANGED
@@ -1,47 +1,47 @@
|
|
1 |
/**
|
2 |
* Responsive Pricing Table Admin JS (minified)
|
3 |
-
* Last updated: Nov
|
4 |
*/
|
5 |
|
6 |
-
;(function($){$(document).ready(function(){var pluginFolderSlug='dk-pricr-responsive-pricing-table';$('.dmb_color_picker').each(function(i,obj){$(this).wpColorPicker()});function refreshPlanCountRelatedUI(){if($('.dmb_main').not('.dmb_empty_plan').length>0){$('.dmb_no_plan_notice').hide()}else{$('.dmb_no_plan_notice').show()}
|
7 |
-
if($('.dmb_main').not('.dmb_empty_plan').length>4){$('.dmb_add_row, .clone-row').hide()}else{$('.dmb_add_row, .clone-row').show()}}
|
8 |
-
refreshPlanCountRelatedUI();var hexDigits=new Array("0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f");function dmb_rgb2hex(rgb){rgb=rgb.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/);return
|
9 |
-
function dmb_hex(x){return isNaN(x)?"00":hexDigits[(x-x%16)/16]+hexDigits[x%16]}
|
10 |
-
function dmb_strip_tags(input,allowed){allowed=(((allowed||'')+'').toLowerCase().match(/<[a-z][a-z0-9]*>/g)||[]).join('');var tags=/<\/?([a-z][a-z0-9]*)\b[^>]*>/gi,commentsAndPhpTags=/<!--[\s\S]*?-->|<\?(?:php)?[\s\S]*?\?>/gi;return input.replace(commentsAndPhpTags,'').replace(tags,function($0,$1){return allowed.indexOf('<'+$1.toLowerCase()+'>')>-1?$0:''})}
|
11 |
-
$('.dmb_icon_data_url').each(function(i,obj){var imgUrl=$(this).attr("data-icon");if(imgUrl!=''){$(this).siblings('.dmb_icon_field').val(imgUrl);$("<img src='"+imgUrl+"' class='dmb_icon_img'/><div class='dmb_clearfix imgClearfix'></div>").insertAfter($(this).parent().find('.dmb_field_title'));$(this).parent().append('<a class="dmb_remove_icon_btn dmb_small_button_secondary" href="#"><span class="dashicons dashicons-no-alt"></span></a>')}});$('.dmb_main').not('.dmb_empty_plan').each(function(i,obj){var featureDump=$(this).find('.dmb_feature_dump').val();var features=$(this).find('.dmb_features');if(featureDump!=''){featureDump=featureDump+'\n';$.each(featureDump.split("\n").slice(0,-1),function(index,item){cleanedItem=item.replace(')--(',',');features.append('<div class="dmb_feature"><input class="dmb_field dmb_feature_field" type="text" value="" /><a class="dmb_remove_feature_btn" href="#"><span class="dashicons dashicons-no-alt"></span></a></div>');features.find('.dmb_feature_field:last').val(cleanedItem)})}});$('.dmb_remove_icon_btn').live("click",function(e){$(this).parent().find('.dmb_icon_img').remove();$(this).parent().find('.imgClearfix').remove();$(this).parent().find('.dmb_icon_field').val('');$(this).remove();return
|
12 |
-
upload_button.parent().append('<a class="dmb_remove_icon_btn dmb_small_button_secondary" href="#"><span class="dashicons dashicons-no-alt"></span></a>');$("<img src='"+imgUrl+"' class='dmb_icon_img'/><div class='dmb_clearfix imgClearfix'></div>").insertAfter(upload_button.parent().find('.dmb_field_title'));upload_button.siblings('.dmb_icon_field').val(imgUrl);tb_remove()}
|
13 |
-
tb_show('','media-upload.php?type=image&TB_iframe=true');return
|
14 |
-
return
|
15 |
-
return
|
16 |
-
return
|
17 |
-
else if(settings.fontSizeTitle=='tiny'){settings.fontSizeTitle=' rpt_xsm_title'}
|
18 |
-
else{settings.fontSizeTitle=''}
|
19 |
-
if(settings.fontSizeSubtitle=='small'){settings.fontSizeSubtitle=' rpt_sm_subtitle'}
|
20 |
-
else if(settings.fontSizeSubtitle=='tiny'){settings.fontSizeSubtitle=' rpt_xsm_subtitle'}
|
21 |
-
else{settings.fontSizeSubtitle=''}
|
22 |
-
if(settings.fontSizeDescription=='small'){settings.fontSizeDescription=' rpt_sm_description'}
|
23 |
-
else{settings.fontSizeDescription=''}
|
24 |
-
if(settings.fontSizePrice=='small'){settings.fontSizePrice=' rpt_sm_price'}
|
25 |
-
else if(settings.fontSizePrice=='tiny'){settings.fontSizePrice=' rpt_xsm_price'}
|
26 |
-
else if(settings.fontSizePrice=='supertiny'){settings.fontSizePrice=' rpt_xxsm_price'}
|
27 |
-
else{settings.fontSizePrice=''}
|
28 |
-
if(settings.fontSizeRecurrence=='small'){settings.fontSizeRecurrence=' rpt_sm_recurrence'}
|
29 |
-
else{settings.fontSizeRecurrence=''}
|
30 |
-
if(settings.fontSizeFeatures=='small'){settings.fontSizeFeatures=' rpt_sm_features'}
|
31 |
-
else{settings.fontSizeFeatures=''}
|
32 |
-
if(settings.fontSizeButton=='small'){settings.fontSizeButton=' rpt_sm_button'}
|
33 |
-
else{settings.fontSizeButton=''}
|
34 |
var preview_html='';preview_html+='<div id="rpt_pricr" style="margin-top:100px;" class="rpt_plans rpt_'+settings.planCount+'_plans rpt_style_basic">';preview_html+='<div class="'+settings.fontSizeTitle+' '+settings.fontSizeSubtitle+' '+settings.fontSizeDescription+' '+settings.fontSizePrice+' '+settings.fontSizeRecurrence+' '+settings.fontSizeButton+' '+settings.fontSizeFeatures+'">';preview_html+='<style>.rpt_plans .rpt_plan .rpt_foot{line-height:34px;} #rpt_pricr{font-family: "Helvetica Neue", Arial, sans-serif; font-weight: 300; line-height: 27px;}</style>'
|
35 |
-
$('.dmb_main').not('.dmb_empty_plan').each(function(i,obj){var fields={},plan={};fields.title=$(this).find(".dmb_title_of_plan").val();fields.subtitle=$(this).find(".dmb_subtitle_of_plan").val();fields.recurrence=$(this).find(".dmb_recurrence_of_plan").val();fields.price=$(this).find(".dmb_price_of_plan").val();fields.description=$(this).find(".dmb_description_of_plan").val();fields.icon=$(this).find(".dmb_icon_of_plan").attr('data-icon');fields.recommended=$(this).find(".dmb_switch_recommended").find(":selected").val();fields.free=$(this).find(".dmb_switch_free").find(":selected").val();fields.features=$(this).find(".dmb_features_of_plan").val();fields.buttonText=$(this).find(".dmb_button_text_of_plan").val();fields.customButton=$(this).find(".dmb_custom_button_of_plan").val();fields.color=dmb_rgb2hex($(this).find(".wp-color-result").css('backgroundColor'))||'#8dba09';if(fields.recommended&&fields.recommended=='yes'){plan.recoClass='rpt_recommended_plan';plan.recoImg='<img class="rpt_recommended" src="../wp-content/plugins/'+pluginFolderSlug+'/inc/img/rpt_recommended.png"/>'}else{plan.recoImg='';plan.recoClass=''}
|
36 |
-
preview_html+='<div class="rpt_plan rpt_plan_'+i+' '+plan.recoClass+'">';plan.titleStyle='style="text-align:'+settings.fontTitleAlignment+';"';if(fields.title){preview_html+='<div '+plan.titleStyle+' class="rpt_title rpt_title_'+i+'">';if(fields.icon){preview_html+='<img height=30px width=30px src="'+fields.icon+'" class="rpt_icon rpt_icon_'+i+'"/> '}
|
37 |
-
preview_html+=fields.title;preview_html+=plan.recoImg+'</div>'}
|
38 |
-
preview_html+='<div class="rpt_head rpt_head_'+i+'">';if(fields.recurrence){preview_html+='<div class="rpt_recurrence rpt_recurrence_'+i+'">'+fields.recurrence+'</div>'}
|
39 |
-
if(fields.price){preview_html+='<div class="rpt_price rpt_price_'+i+'">';if(fields.free=='yes'||fields.free=='on'){preview_html+='<span class="rpt_currency">';preview_html+='</span>'}else{if(settings.tableCurrency){preview_html+='<span class="rpt_currency">';preview_html+=settings.tableCurrency;preview_html+='</span>'}else{preview_html+='<span class="rpt_currency">';preview_html+='</span>'}}
|
40 |
-
preview_html+=fields.price;preview_html+='</div>'}
|
41 |
-
if(fields.subtitle){preview_html+='<div style="color:'+fields.color+';" class="rpt_subtitle rpt_subtitle_'+i+'">'+fields.subtitle+'</div>'}
|
42 |
-
if(fields.description){preview_html+='<div class="rpt_description rpt_description_'+i+'">'+fields.description+'</div>'}
|
43 |
-
preview_html+='<div style="clear:both;"></div>';preview_html+='</div>';if(fields.features){preview_html+='<div class="rpt_features rpt_features_'+i+'">';plan.features=[];plan.featureString=fields.features;plan.featureStringArray=plan.featureString.split("\n");plan.featureStringArray=plan.featureStringArray.map(function(el){return el.trim()});$.each(plan.featureStringArray,function(index,value){plan.features.push(dmb_strip_tags(value,'<strong></strong><br><br/></br><img><a>'))});$.each(plan.featureStringArray,function(smallKey,feature){if(feature){var check=feature.substr(0,2);if(check=='-n'){feature=feature.substr(2);var checkColor='#bbbbbb'}else{checkColor='black'}
|
44 |
-
preview_html+='<div style="color:'+checkColor+';" class="rpt_feature rpt_feature_'+i+'-'+smallKey+'">';preview_html+=feature;preview_html+='</div>'}});preview_html+='</div>';preview_html+='<div style="clear:both;"></div>'}
|
45 |
-
if(fields.customButton){preview_html+='<div class="rpt_custom_btn" style="background-color:'+fields.color+'">';preview_html+=fields.customButton;preview_html+='</div>'}else{if(fields.buttonText){preview_html+='<a href="#" style="background:'+fields.color+'" class="rpt_foot rpt_foot_'+i+'">';preview_html+=fields.buttonText}else{preview_html+='<a style="background:'+fields.color+'" class="rpt_foot rpt_foot_'+i+'">'}
|
46 |
-
preview_html+='</a>'}
|
47 |
-
preview_html+='</div>'});preview_html+='</div>';preview_html+='</div>';preview_html+='<div style="clear:both;"></div>';preview_html+='<div class="dmb_accuracy_preview_notice">'+objectL10n.previewAccuracy+'</div>';(settings.planCount==0)?$('#dmb_preview_table').append('<
|
1 |
/**
|
2 |
* Responsive Pricing Table Admin JS (minified)
|
3 |
+
* Last updated: Nov 29, 2017
|
4 |
*/
|
5 |
|
6 |
+
;(function($){$(document).ready(function(){var pluginFolderSlug='dk-pricr-responsive-pricing-table';$('.dmb_color_picker').each(function(i,obj){$(this).wpColorPicker();});function refreshPlanCountRelatedUI(){if($('.dmb_main').not('.dmb_empty_plan').length>0){$('.dmb_no_plan_notice').hide();}else{$('.dmb_no_plan_notice').show();}
|
7 |
+
if($('.dmb_main').not('.dmb_empty_plan').length>4){$('.dmb_add_row, .clone-row').hide();}else{$('.dmb_add_row, .clone-row').show();}}
|
8 |
+
refreshPlanCountRelatedUI();var hexDigits=new Array("0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f");function dmb_rgb2hex(rgb){rgb=rgb.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/);return"#"+dmb_hex(rgb[1])+dmb_hex(rgb[2])+dmb_hex(rgb[3]);}
|
9 |
+
function dmb_hex(x){return isNaN(x)?"00":hexDigits[(x-x%16)/ 16]+hexDigits[x%16];}
|
10 |
+
function dmb_strip_tags(input,allowed){allowed=(((allowed||'')+'').toLowerCase().match(/<[a-z][a-z0-9]*>/g)||[]).join('');var tags=/<\/?([a-z][a-z0-9]*)\b[^>]*>/gi,commentsAndPhpTags=/<!--[\s\S]*?-->|<\?(?:php)?[\s\S]*?\?>/gi;return input.replace(commentsAndPhpTags,'').replace(tags,function($0,$1){return allowed.indexOf('<'+$1.toLowerCase()+'>')>-1?$0:'';});}
|
11 |
+
$('.dmb_icon_data_url').each(function(i,obj){var imgUrl=$(this).attr("data-icon");if(imgUrl!=''){$(this).siblings('.dmb_icon_field').val(imgUrl);$("<img src='"+imgUrl+"' class='dmb_icon_img'/><div class='dmb_clearfix imgClearfix'></div>").insertAfter($(this).parent().find('.dmb_field_title'));$(this).parent().append('<a class="dmb_remove_icon_btn dmb_small_button_secondary" href="#"><span class="dashicons dashicons-no-alt"></span></a>');}});$('.dmb_main').not('.dmb_empty_plan').each(function(i,obj){var featureDump=$(this).find('.dmb_feature_dump').val();var features=$(this).find('.dmb_features');if(featureDump!=''){featureDump=featureDump+'\n';$.each(featureDump.split("\n").slice(0,-1),function(index,item){cleanedItem=item.replace(')--(',',');features.append('<div class="dmb_feature"><input class="dmb_field dmb_feature_field" type="text" value="" /><a class="dmb_remove_feature_btn" href="#"><span class="dashicons dashicons-no-alt"></span></a></div>');features.find('.dmb_feature_field:last').val(cleanedItem);});}});$('.dmb_remove_icon_btn').live("click",function(e){$(this).parent().find('.dmb_icon_img').remove();$(this).parent().find('.imgClearfix').remove();$(this).parent().find('.dmb_icon_field').val('');$(this).remove();return false;});$('.dmb_upload_icon_btn').click(function(){upload_button=$(this);isAlreadyImg=$(this).siblings('.dmb_icon_data_url').attr("data-icon");window.send_to_editor=function(html){imgUrl=$(html).attr('src');if(isAlreadyImg){upload_button.parent().find('.dmb_icon_img').remove();upload_button.parent().find('.dmb_remove_icon_btn').remove();}
|
12 |
+
upload_button.parent().append('<a class="dmb_remove_icon_btn dmb_small_button_secondary" href="#"><span class="dashicons dashicons-no-alt"></span></a>');$("<img src='"+imgUrl+"' class='dmb_icon_img'/><div class='dmb_clearfix imgClearfix'></div>").insertAfter(upload_button.parent().find('.dmb_field_title'));upload_button.siblings('.dmb_icon_field').val(imgUrl);tb_remove();}
|
13 |
+
tb_show('','media-upload.php?type=image&TB_iframe=true');return false;});$('.dmb_remove_feature_btn').click(function(e){removeButton=$(this);removedFeature=$(this).closest('.dmb_feature').find('.dmb_feature_field');removedFeature.remove();featureList=removeButton.closest('.dmb_main').find('.dmb_feature_field');remainingFeatures=[];featureDump=$(this).closest('.dmb_main').find('.dmb_feature_dump');if(featureList.length==0){featureDump.val('');removeButton.parent().remove();return false;}else{featureList.each(function(i,obj){if($(this).val()){var cleanFeature=$(this).val().split(',').join(')--(');remainingFeatures.push(cleanFeature);var newFeatures=remainingFeatures.toString().split(',').join("\n").split(')--(').join(',');featureDump.val(newFeatures);}});removeButton.parent().remove();return false;}});$('.dmb_add_feature').on('click',function(){var lastFeature=$(this).siblings('.dmb_features').find('.dmb_feature:last .dmb_feature_field');if(lastFeature.val()!=''){var feature=$('.empty-feature').clone(true);feature.removeClass('empty-feature').show();$(this).siblings('.dmb_features').append(feature);feature.find('.dmb_feature_field').focus();return false;}else{lastFeature.focus();}
|
14 |
+
return false;});$('.dmb_feature_field').live("keyup",function(e){featureUpdated=$(this);featuresUpdated=$(this).parent().parent().siblings('.dmb_feature_dump');var featuresList=featureUpdated.parent().parent().find('.dmb_feature_field'),features=[];if(featuresList.length<1){featuresUpdated.val('');}else{featuresList.each(function(i,obj){if($(this).val()){var cleanFeature=$(this).val().split(',').join(')--(');features.push(cleanFeature);var newFeatures=features.toString().split(',').join("\n").split(')--(').join(',');featuresUpdated.val(newFeatures);}});}});$('.dmb_add_row').on('click',function(){var row=$('.dmb_empty_plan').clone(true);row.removeClass('dmb_empty_plan').addClass('dmb_main').show();row.find('.emptyDump').removeClass('emptyDump').addClass('dmb_feature_dump');row.insertBefore($('.dmb_empty_plan'));row.find('.dmb_title_of_plan').focus();row.find('.dmb_color_picker_ready').removeClass('.dmb_color_picker_ready').addClass('.dmb_color_picker').wpColorPicker().css({'padding':'3px'});row.find('.dmb_handle_title').html(objectL10n.untitled);refreshPlanCountRelatedUI();return false;});$('.dmb_remove_row_btn').click(function(e){$(this).closest('.dmb_main').remove();refreshPlanCountRelatedUI();return false;});$('.dmb_handle').click(function(e){$(this).siblings('.dmb_inner').slideToggle(50);($(this).hasClass('closed'))?$(this).removeClass('closed'):$(this).addClass('closed');return false;});$('.dmb_collapse_plans').click(function(e){$('.dmb_handle').each(function(i,obj){if(!$(this).closest('.dmb_empty_plan').length){if($(this).hasClass('closed')){}else{$(this).siblings('.dmb_inner').slideToggle(50);$(this).addClass('closed');}}});return false;});$('.dmb_expand_plans').click(function(e){$('.dmb_handle').each(function(i,obj){if($(this).hasClass('closed')){$(this).siblings('.dmb_inner').slideToggle(50);$(this).removeClass('closed');}});return false;});$('.dmb_move_row_down').click(function(e){if($(this).closest('.dmb_main').next().hasClass('dmb_main')){var movingPlan=$(this).closest('.dmb_main').clone(true);movingPlan.insertAfter($(this).closest('.dmb_main').next());var rgbColorToMove=movingPlan.find('.wp-color-result').css('backgroundColor');movingPlan.find('.wp-picker-container').remove();movingPlan.find('.dmb_color_box').append('<input class="dmb_color_picker dmb_field" name="plan_colors[]" type="text" value="'+dmb_rgb2hex(rgbColorToMove)+'" />');movingPlan.find('.dmb_color_picker').wpColorPicker();$(this).closest('.dmb_main').remove();}
|
15 |
+
return false;});$('.dmb_move_row_up').click(function(e){if($(this).closest('.dmb_main').prev().hasClass('dmb_main')){var movingPlan=$(this).closest('.dmb_main').clone(true);movingPlan.insertBefore($(this).closest('.dmb_main').prev());var rgbColorToMove=movingPlan.find('.wp-color-result').css('backgroundColor');movingPlan.find('.wp-picker-container').remove();movingPlan.find('.dmb_color_box').append('<input class="dmb_color_picker dmb_field" name="plan_colors[]" type="text" value="'+dmb_rgb2hex(rgbColorToMove)+'" />');movingPlan.find('.dmb_color_picker').wpColorPicker();$(this).closest('.dmb_main').remove();}
|
16 |
+
return false;});$('.dmb_clone_row').click(function(e){var clone=$(this).closest('.dmb_main').clone(true);clone.insertAfter($(this).closest('.dmb_main'));clone.find('.dmb_handle_title').html(clone.find('.dmb_title_of_plan').val()+' ('+objectL10n.copy+')');clone.find('.dmb_title_of_plan').focus();var rgbColorToMove=$(this).closest('.dmb_main').find('.wp-color-result').css('backgroundColor');clone.find('.wp-picker-container').remove();clone.find('.dmb_color_box').append('<input class="dmb_color_picker dmb_field" name="plan_colors[]" type="text" value="'+dmb_rgb2hex(rgbColorToMove)+'" />');clone.find('.dmb_color_picker').wpColorPicker();refreshPlanCountRelatedUI();return false;});$('.dmb_title_of_plan').each(function(i,obj){if($(this).val()!=''){var handleTitle=$(this).closest('.dmb_main').find('.dmb_handle_title');handleTitle.html($(this).val());}});$('.dmb_title_of_plan').live("keyup",function(e){var titleField=$(this);var handleTitle=titleField.closest('.dmb_main').find('.dmb_handle_title');(titleField.val()!='')?handleTitle.html(titleField.val()):handleTitle.html(objectL10n.untitled);});$('.dmb_text_settings_box_show').click(function(){$('.dmb_text_settings_box').toggle();});$('.dmb_show_preview_table').click(function(){var settings={};settings.planCount=$('.dmb_main').not('.dmb_empty_plan').size();settings.tableCurrency=$("input[name='table_currency']").val();settings.fontTitleAlignment=$("select[name='font_title_alignment'] option:selected").val();settings.fontSizeTitle=$("select[name='font_size_title'] option:selected").val();settings.fontSizeSubtitle=$("select[name='font_size_subtitle'] option:selected").val();settings.fontSizeDescription=$("select[name='font_size_description'] option:selected").val();settings.fontSizePrice=$("select[name='font_size_price'] option:selected").val();settings.fontSizeRecurrence=$("select[name='font_size_recurrence'] option:selected").val();settings.fontSizeButton=$("select[name='font_size_button'] option:selected").val();settings.fontSizeFeatures=$("select[name='font_size_features'] option:selected").val();if(settings.fontSizeTitle=='small'){settings.fontSizeTitle=' rpt_sm_title';}
|
17 |
+
else if(settings.fontSizeTitle=='tiny'){settings.fontSizeTitle=' rpt_xsm_title';}
|
18 |
+
else{settings.fontSizeTitle='';}
|
19 |
+
if(settings.fontSizeSubtitle=='small'){settings.fontSizeSubtitle=' rpt_sm_subtitle';}
|
20 |
+
else if(settings.fontSizeSubtitle=='tiny'){settings.fontSizeSubtitle=' rpt_xsm_subtitle';}
|
21 |
+
else{settings.fontSizeSubtitle='';}
|
22 |
+
if(settings.fontSizeDescription=='small'){settings.fontSizeDescription=' rpt_sm_description';}
|
23 |
+
else{settings.fontSizeDescription='';}
|
24 |
+
if(settings.fontSizePrice=='small'){settings.fontSizePrice=' rpt_sm_price';}
|
25 |
+
else if(settings.fontSizePrice=='tiny'){settings.fontSizePrice=' rpt_xsm_price';}
|
26 |
+
else if(settings.fontSizePrice=='supertiny'){settings.fontSizePrice=' rpt_xxsm_price';}
|
27 |
+
else{settings.fontSizePrice='';}
|
28 |
+
if(settings.fontSizeRecurrence=='small'){settings.fontSizeRecurrence=' rpt_sm_recurrence';}
|
29 |
+
else{settings.fontSizeRecurrence='';}
|
30 |
+
if(settings.fontSizeFeatures=='small'){settings.fontSizeFeatures=' rpt_sm_features';}
|
31 |
+
else{settings.fontSizeFeatures='';}
|
32 |
+
if(settings.fontSizeButton=='small'){settings.fontSizeButton=' rpt_sm_button';}
|
33 |
+
else{settings.fontSizeButton='';}
|
34 |
var preview_html='';preview_html+='<div id="rpt_pricr" style="margin-top:100px;" class="rpt_plans rpt_'+settings.planCount+'_plans rpt_style_basic">';preview_html+='<div class="'+settings.fontSizeTitle+' '+settings.fontSizeSubtitle+' '+settings.fontSizeDescription+' '+settings.fontSizePrice+' '+settings.fontSizeRecurrence+' '+settings.fontSizeButton+' '+settings.fontSizeFeatures+'">';preview_html+='<style>.rpt_plans .rpt_plan .rpt_foot{line-height:34px;} #rpt_pricr{font-family: "Helvetica Neue", Arial, sans-serif; font-weight: 300; line-height: 27px;}</style>'
|
35 |
+
$('.dmb_main').not('.dmb_empty_plan').each(function(i,obj){var fields={},plan={};fields.title=$(this).find(".dmb_title_of_plan").val();fields.subtitle=$(this).find(".dmb_subtitle_of_plan").val();fields.recurrence=$(this).find(".dmb_recurrence_of_plan").val();fields.price=$(this).find(".dmb_price_of_plan").val();fields.description=$(this).find(".dmb_description_of_plan").val();fields.icon=$(this).find(".dmb_icon_of_plan").attr('data-icon');fields.recommended=$(this).find(".dmb_switch_recommended").find(":selected").val();fields.free=$(this).find(".dmb_switch_free").find(":selected").val();fields.features=$(this).find(".dmb_features_of_plan").val();fields.buttonText=$(this).find(".dmb_button_text_of_plan").val();fields.customButton=$(this).find(".dmb_custom_button_of_plan").val();fields.color=dmb_rgb2hex($(this).find(".wp-color-result").css('backgroundColor'))||'#8dba09';if(fields.recommended&&fields.recommended=='yes'){plan.recoClass='rpt_recommended_plan';plan.recoImg='<img class="rpt_recommended" src="../wp-content/plugins/'+pluginFolderSlug+'/inc/img/rpt_recommended.png"/>';}else{plan.recoImg='';plan.recoClass='';}
|
36 |
+
preview_html+='<div class="rpt_plan rpt_plan_'+i+' '+plan.recoClass+'">';plan.titleStyle='style="text-align:'+settings.fontTitleAlignment+';"';if(fields.title){preview_html+='<div '+plan.titleStyle+' class="rpt_title rpt_title_'+i+'">';if(fields.icon){preview_html+='<img height=30px width=30px src="'+fields.icon+'" class="rpt_icon rpt_icon_'+i+'"/> ';}
|
37 |
+
preview_html+=fields.title;preview_html+=plan.recoImg+'</div>';}
|
38 |
+
preview_html+='<div class="rpt_head rpt_head_'+i+'">';if(fields.recurrence){preview_html+='<div class="rpt_recurrence rpt_recurrence_'+i+'">'+fields.recurrence+'</div>';}
|
39 |
+
if(fields.price){preview_html+='<div class="rpt_price rpt_price_'+i+'">';if(fields.free=='yes'||fields.free=='on'){preview_html+='<span class="rpt_currency">';preview_html+='</span>';}else{if(settings.tableCurrency){preview_html+='<span class="rpt_currency">';preview_html+=settings.tableCurrency;preview_html+='</span>';}else{preview_html+='<span class="rpt_currency">';preview_html+='</span>';}}
|
40 |
+
preview_html+=fields.price;preview_html+='</div>';}
|
41 |
+
if(fields.subtitle){preview_html+='<div style="color:'+fields.color+';" class="rpt_subtitle rpt_subtitle_'+i+'">'+fields.subtitle+'</div>';}
|
42 |
+
if(fields.description){preview_html+='<div class="rpt_description rpt_description_'+i+'">'+fields.description+'</div>';}
|
43 |
+
preview_html+='<div style="clear:both;"></div>';preview_html+='</div>';if(fields.features){preview_html+='<div class="rpt_features rpt_features_'+i+'">';plan.features=[];plan.featureString=fields.features;plan.featureStringArray=plan.featureString.split("\n");plan.featureStringArray=plan.featureStringArray.map(function(el){return el.trim();});$.each(plan.featureStringArray,function(index,value){plan.features.push(dmb_strip_tags(value,'<strong></strong><br><br/></br><img><a>'));});$.each(plan.featureStringArray,function(smallKey,feature){if(feature){var check=feature.substr(0,2);if(check=='-n'){feature=feature.substr(2);var checkColor='#bbbbbb';}else{checkColor='black';}
|
44 |
+
preview_html+='<div style="color:'+checkColor+';" class="rpt_feature rpt_feature_'+i+'-'+smallKey+'">';preview_html+=feature;preview_html+='</div>';}});preview_html+='</div>';preview_html+='<div style="clear:both;"></div>';}
|
45 |
+
if(fields.customButton){preview_html+='<div class="rpt_custom_btn" style="background-color:'+fields.color+'">';preview_html+=fields.customButton;preview_html+='</div>';}else{if(fields.buttonText){preview_html+='<a href="#" style="background:'+fields.color+'" class="rpt_foot rpt_foot_'+i+'">';preview_html+=fields.buttonText;}else{preview_html+='<a style="background:'+fields.color+'" class="rpt_foot rpt_foot_'+i+'">';}
|
46 |
+
preview_html+='</a>';}
|
47 |
+
preview_html+='</div>';});preview_html+='</div>';preview_html+='</div>';preview_html+='<div style="clear:both;"></div>';preview_html+='<div class="dmb_accuracy_preview_notice">'+objectL10n.previewAccuracy+'</div>';(settings.planCount==0)?$('#dmb_preview_table').append('<div class="dmb_no_plan_preview_notice">'+objectL10n.noPlan+'</div>'):$('#dmb_preview_table').append(preview_html);$('#dmb_preview_table').fadeIn(100);});$('.dmb_preview_table_close').click(function(){$('#dmb_preview_table #rpt_pricr, .dmb_accuracy_preview_notice, .dmb_no_plan_preview_notice').remove();$('#dmb_preview_table').fadeOut(100);});});})(jQuery);
|
inc/img/rpt_recommended.png
CHANGED
File without changes
|
inc/js/rpt.js
CHANGED
File without changes
|
inc/js/rpt.min.js
CHANGED
File without changes
|
inc/rpt-admin-scripts.php
CHANGED
@@ -17,7 +17,7 @@ function add_admin_rpt_style() {
|
|
17 |
wp_enqueue_style( 'wp-color-picker' );
|
18 |
|
19 |
/* JS for metaboxes. */
|
20 |
-
wp_enqueue_script( 'rpt', plugins_url('dmb/dmb.js', __FILE__), array( 'jquery', 'thickbox', 'wp-color-picker' ));
|
21 |
wp_localize_script( 'rpt', 'objectL10n', array(
|
22 |
'untitled' => __( 'Untitled', RPT_TXTDM ),
|
23 |
'copy' => __( 'copy', RPT_TXTDM ),
|
17 |
wp_enqueue_style( 'wp-color-picker' );
|
18 |
|
19 |
/* JS for metaboxes. */
|
20 |
+
wp_enqueue_script( 'rpt', plugins_url('dmb/dmb.min.js', __FILE__), array( 'jquery', 'thickbox', 'wp-color-picker' ));
|
21 |
wp_localize_script( 'rpt', 'objectL10n', array(
|
22 |
'untitled' => __( 'Untitled', RPT_TXTDM ),
|
23 |
'copy' => __( 'copy', RPT_TXTDM ),
|
inc/rpt-front-scripts.php
CHANGED
File without changes
|
inc/rpt-metaboxes-help.php
CHANGED
File without changes
|
inc/rpt-metaboxes-plans.php
CHANGED
@@ -36,7 +36,7 @@ function dmb_rpts_plan_display() {
|
|
36 |
/* Gets plan data. */
|
37 |
$pricing_table = get_post_meta( $post->ID, '_rpt_plan_group', true );
|
38 |
|
39 |
-
$fields_to_process =
|
40 |
'_rpt_title',
|
41 |
'_rpt_subtitle',
|
42 |
'_rpt_recurrence',
|
@@ -51,7 +51,7 @@ function dmb_rpts_plan_display() {
|
|
51 |
'_rpt_btn_custom_btn',
|
52 |
'_rpt_custom_classes',
|
53 |
'_rpt_color'
|
54 |
-
|
55 |
|
56 |
/* Retrieves select options. */
|
57 |
$is_highlight_plan_options = dmb_rpts_is_highlight_plan_options();
|
@@ -81,10 +81,8 @@ function dmb_rpts_plan_display() {
|
|
81 |
/* Loops through plans. */
|
82 |
foreach ( $pricing_table as $pricing_plan ) {
|
83 |
|
84 |
-
/* Current plan. */
|
85 |
-
$plan = array();
|
86 |
-
|
87 |
/* Retrieves each field for current plan. */
|
|
|
88 |
foreach ( $fields_to_process as $field) {
|
89 |
switch ($field) {
|
90 |
case '_rpt_recommended':
|
36 |
/* Gets plan data. */
|
37 |
$pricing_table = get_post_meta( $post->ID, '_rpt_plan_group', true );
|
38 |
|
39 |
+
$fields_to_process = array(
|
40 |
'_rpt_title',
|
41 |
'_rpt_subtitle',
|
42 |
'_rpt_recurrence',
|
51 |
'_rpt_btn_custom_btn',
|
52 |
'_rpt_custom_classes',
|
53 |
'_rpt_color'
|
54 |
+
);
|
55 |
|
56 |
/* Retrieves select options. */
|
57 |
$is_highlight_plan_options = dmb_rpts_is_highlight_plan_options();
|
81 |
/* Loops through plans. */
|
82 |
foreach ( $pricing_table as $pricing_plan ) {
|
83 |
|
|
|
|
|
|
|
84 |
/* Retrieves each field for current plan. */
|
85 |
+
$plan = array();
|
86 |
foreach ( $fields_to_process as $field) {
|
87 |
switch ($field) {
|
88 |
case '_rpt_recommended':
|
inc/rpt-metaboxes-pro.php
CHANGED
File without changes
|
inc/rpt-metaboxes-settings.php
CHANGED
@@ -135,14 +135,15 @@ function dmb_rpts_settings_display() {
|
|
135 |
$btn_size = dmb_rpts_btn_size_options();
|
136 |
$features_size = dmb_rpts_features_size_options();
|
137 |
|
138 |
-
$settings_to_process =
|
139 |
'_rpt_currency',
|
140 |
'_rpt_open_newwindow',
|
141 |
'_rpt_original_font',
|
142 |
'_rpt_title_alignment',
|
143 |
-
|
144 |
|
145 |
/* Processes retrieved fields. */
|
|
|
146 |
foreach ( $settings_to_process as $setting) {
|
147 |
switch ($setting) {
|
148 |
case '_rpt_original_font':
|
@@ -154,7 +155,7 @@ function dmb_rpts_settings_display() {
|
|
154 |
}
|
155 |
}
|
156 |
|
157 |
-
$font_sizes_to_process =
|
158 |
'_rpt_title_fontsize',
|
159 |
'_rpt_subtitle_fontsize',
|
160 |
'_rpt_description_fontsize',
|
@@ -162,9 +163,10 @@ function dmb_rpts_settings_display() {
|
|
162 |
'_rpt_recurrence_fontsize',
|
163 |
'_rpt_button_fontsize',
|
164 |
'_rpt_features_fontsize'
|
165 |
-
|
166 |
|
167 |
/* Processes retrieved fields. */
|
|
|
168 |
foreach ( $font_sizes_to_process as $font) {
|
169 |
$fonts[$font] = ( get_post_meta( $post->ID, $font, true ) ) ? get_post_meta( $post->ID, $font, true ) : 'normal';
|
170 |
}
|
135 |
$btn_size = dmb_rpts_btn_size_options();
|
136 |
$features_size = dmb_rpts_features_size_options();
|
137 |
|
138 |
+
$settings_to_process = array(
|
139 |
'_rpt_currency',
|
140 |
'_rpt_open_newwindow',
|
141 |
'_rpt_original_font',
|
142 |
'_rpt_title_alignment',
|
143 |
+
);
|
144 |
|
145 |
/* Processes retrieved fields. */
|
146 |
+
$settings = array();
|
147 |
foreach ( $settings_to_process as $setting) {
|
148 |
switch ($setting) {
|
149 |
case '_rpt_original_font':
|
155 |
}
|
156 |
}
|
157 |
|
158 |
+
$font_sizes_to_process = array(
|
159 |
'_rpt_title_fontsize',
|
160 |
'_rpt_subtitle_fontsize',
|
161 |
'_rpt_description_fontsize',
|
163 |
'_rpt_recurrence_fontsize',
|
164 |
'_rpt_button_fontsize',
|
165 |
'_rpt_features_fontsize'
|
166 |
+
);
|
167 |
|
168 |
/* Processes retrieved fields. */
|
169 |
+
$fonts = array();
|
170 |
foreach ( $font_sizes_to_process as $font) {
|
171 |
$fonts[$font] = ( get_post_meta( $post->ID, $font, true ) ) ? get_post_meta( $post->ID, $font, true ) : 'normal';
|
172 |
}
|
inc/rpt-post-type.php
CHANGED
File without changes
|
inc/rpt-pro-version-check.php
CHANGED
File without changes
|
inc/rpt-save-metaboxes.php
CHANGED
File without changes
|
inc/rpt-shortcode-column.php
CHANGED
File without changes
|
inc/rpt-shortcode.php
CHANGED
File without changes
|
inc/rpt-text-domain.php
CHANGED
File without changes
|
lang/dk-pricr-responsive-pricing-table.pot
CHANGED
File without changes
|
readme.txt
CHANGED
@@ -39,11 +39,11 @@ The [PRO version](https://wpdarko.com/items/responsive-pricing-table-pro) adds n
|
|
39 |
* Title alignment
|
40 |
* Font size presets
|
41 |
|
42 |
-
= Usage =
|
43 |
Go to [the plugin's documentation](https://wpdarko.com/docs/guide-responsive-pricing-table) if you need more information on how to use this plugin.
|
44 |
|
45 |
= Support =
|
46 |
-
Find help
|
47 |
|
48 |
== Installation ==
|
49 |
|
@@ -53,23 +53,23 @@ Find help in [our forums](https://wpdarko.com/ask-for-support) for this plugin (
|
|
53 |
3. Alternatively, download the plugin and upload the contents of responsive-pricing-table.zip to your plugins directory, which usually is /wp-content/plugins/
|
54 |
4. Activate the plugin
|
55 |
|
56 |
-
= Usage =
|
57 |
-
Go to [the plugin's documentation](https://wpdarko.com/docs/guide-responsive-pricing-table)
|
58 |
|
59 |
= Support =
|
60 |
-
Find help
|
61 |
|
62 |
== Frequently Asked Questions ==
|
63 |
= No limitation for the Free version =
|
64 |
-
The
|
65 |
|
66 |
The [PRO version](https://wpdarko.com/items/responsive-pricing-table-pro) adds new features: **skins**, **tooltips** and **equalizer**. Skins are new designs for your pricing tables, tooltips are “info bubbles” that you can easily add to your features. The plan equalizer automatically evens out your plans' height.
|
67 |
|
68 |
-
= Usage =
|
69 |
-
Go to [the plugin's documentation](https://wpdarko.com/docs/guide-responsive-pricing-table)
|
70 |
|
71 |
= Support =
|
72 |
-
Find help
|
73 |
|
74 |
== Screenshots ==
|
75 |
1. Displaying the pricing table (front view)
|
@@ -80,6 +80,9 @@ Find help in [our forums](https://wpdarko.com/ask-for-support) for this plugin (
|
|
80 |
6. Finding the shortcode (admin view)
|
81 |
|
82 |
== Changelog ==
|
|
|
|
|
|
|
83 |
= 5.0.1 =
|
84 |
* Fixes custom button saving issue
|
85 |
|
39 |
* Title alignment
|
40 |
* Font size presets
|
41 |
|
42 |
+
= Usage/Video tutorial =
|
43 |
Go to [the plugin's documentation](https://wpdarko.com/docs/guide-responsive-pricing-table) if you need more information on how to use this plugin.
|
44 |
|
45 |
= Support =
|
46 |
+
Find help on [our website](https://wpdarko.com/ask-for-support) for this plugin (we’ll answer you fast, promise).
|
47 |
|
48 |
== Installation ==
|
49 |
|
53 |
3. Alternatively, download the plugin and upload the contents of responsive-pricing-table.zip to your plugins directory, which usually is /wp-content/plugins/
|
54 |
4. Activate the plugin
|
55 |
|
56 |
+
= Usage/Video tutorial =
|
57 |
+
Go to [the plugin's documentation](https://wpdarko.com/docs/guide-responsive-pricing-table) if you need more information on how to use this plugin.
|
58 |
|
59 |
= Support =
|
60 |
+
Find help on [our website](https://wpdarko.com/ask-for-support) for this plugin (we’ll answer you fast, promise).
|
61 |
|
62 |
== Frequently Asked Questions ==
|
63 |
= No limitation for the Free version =
|
64 |
+
The Free version of the Responsive Pricing Table plugin is **not limited**.
|
65 |
|
66 |
The [PRO version](https://wpdarko.com/items/responsive-pricing-table-pro) adds new features: **skins**, **tooltips** and **equalizer**. Skins are new designs for your pricing tables, tooltips are “info bubbles” that you can easily add to your features. The plan equalizer automatically evens out your plans' height.
|
67 |
|
68 |
+
= Usage/Video tutorial =
|
69 |
+
Go to [the plugin's documentation](https://wpdarko.com/docs/guide-responsive-pricing-table) if you need more information on how to use this plugin.
|
70 |
|
71 |
= Support =
|
72 |
+
Find help on [our website](https://wpdarko.com/ask-for-support) for this plugin (we’ll answer you fast, promise).
|
73 |
|
74 |
== Screenshots ==
|
75 |
1. Displaying the pricing table (front view)
|
80 |
6. Finding the shortcode (admin view)
|
81 |
|
82 |
== Changelog ==
|
83 |
+
= 5.0.2 =
|
84 |
+
* Fixes compatibility issue with PHP5.3
|
85 |
+
|
86 |
= 5.0.1 =
|
87 |
* Fixes custom button saving issue
|
88 |
|
rpt.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
* Plugin Name: Responsive Pricing Table
|
5 |
* Plugin URI: https://wpdarko.com/items/responsive-pricing-table-pro/
|
6 |
* Description: A responsive, easy and elegant way to present your offer to your visitors. Just create a new pricing table (custom type) and copy-paste the shortcode into your posts/pages. Find help and information on our <a href="https://wpdarko.com/ask-for-support/">support site</a>. This free version is NOT limited and does not contain any ad. Check out the <a href='http://wpdarko.com/items/responsive-pricing-table-pro/'>PRO version</a> for more great features.
|
7 |
-
* Version: 5.0.
|
8 |
* Author: WP Darko
|
9 |
* Author URI: https://wpdarko.com
|
10 |
* Text Domain: dk-pricr-responsive-pricing-table
|
4 |
* Plugin Name: Responsive Pricing Table
|
5 |
* Plugin URI: https://wpdarko.com/items/responsive-pricing-table-pro/
|
6 |
* Description: A responsive, easy and elegant way to present your offer to your visitors. Just create a new pricing table (custom type) and copy-paste the shortcode into your posts/pages. Find help and information on our <a href="https://wpdarko.com/ask-for-support/">support site</a>. This free version is NOT limited and does not contain any ad. Check out the <a href='http://wpdarko.com/items/responsive-pricing-table-pro/'>PRO version</a> for more great features.
|
7 |
+
* Version: 5.0.2
|
8 |
* Author: WP Darko
|
9 |
* Author URI: https://wpdarko.com
|
10 |
* Text Domain: dk-pricr-responsive-pricing-table
|