diff --git a/admin/class-courses.php b/admin/class-courses.php index bb61ce0..74df417 100644 --- a/admin/class-courses.php +++ b/admin/class-courses.php @@ -110,7 +110,7 @@ public static function header_columns( $columns ) { /** * Paid column is needed? */ - if ( ! BrainPress_Helper_Integration_PSeCommerce::$is_active && ! BrainPress_Helper_Integration_WooCommerce::$is_active ) { + if ( ! BrainPress_Helper_Integration_MarketPress::$is_active && ! BrainPress_Helper_Integration_WooCommerce::$is_active ) { unset( $columns['paid'] ); } diff --git a/admin/class-edit.php b/admin/class-edit.php index 8d0ea0f..a7fdde7 100644 --- a/admin/class-edit.php +++ b/admin/class-edit.php @@ -583,14 +583,14 @@ public static function step_6() { */ $is_payment_available = false; $filters_to_check = array( - 'brainpress_is_psecommerce_active', + 'brainpress_is_marketpress_active', 'brainpress_is_woocommerce_active', ); foreach ( $filters_to_check as $filter ) { if ( $is_payment_available ) { continue; } - $is_payment_available = apply_filters( 'brainpress_is_psecommerce_active', $is_payment_available ); + $is_payment_available = apply_filters( 'brainpress_is_marketpress_active', $is_payment_available ); } if ( ! $is_payment_available ) { $disable_payment = false; @@ -600,7 +600,7 @@ public static function step_6() { $is_paid_course = ! empty( self::$settings['payment_paid_course'] ); //$data_course = new BrainPress_Data_Course(); $data_instructor = new BrainPress_Data_Instructor(); - $mp_class = new Brainpress_Helper_Extension_PSeCommerce(); + $mp_class = new Brainpress_Helper_Extension_MarketPress(); $utility_class = new BrainPress_Helper_Utility(); $install_url = add_query_arg( @@ -615,25 +615,25 @@ public static function step_6() { array( 'post_type' => self::$post_type, 'page' => 'brainpress_settings', - 'tab' => 'psecommerce', + 'tab' => 'marketpress', ), admin_url( 'edit.php' ) ); - $install_message = __( 'Bitte wende Dich an Deinen Administrator, um PSeCommerce für Deine Seite zu aktivieren.', 'brainpress' ); + $install_message = __( 'Bitte wende Dich an Deinen Administrator, um MarketPress für Deine Seite zu aktivieren.', 'brainpress' ); $install_message2 = ''; $installed = $mp_class->installed(); if ( current_user_can( 'install_plugins' ) || current_user_can( 'activate_plugins ' ) ) { - $install_message = __( 'Um mit dem Verkauf Deines Kurses zu beginnen, bitte Installiere und aktiviere PSeCommerce.', 'brainpress' ); + $install_message = __( 'Um mit dem Verkauf Deines Kurses zu beginnen, bitte Installiere und aktiviere MarketPress.', 'brainpress' ); if ( $installed && $mp_class->activated() ) { - $install_message = __( 'Um mit dem Verkauf Deines Kurses zu beginnen, bitte Setup komplettieren für PSeCommerce.', 'brainpress' ); + $install_message = __( 'Um mit dem Verkauf Deines Kurses zu beginnen, bitte Setup komplettieren für MarketPress.', 'brainpress' ); $install_url = $mp_url; } if ( false === $installed ) { - $install_message2 = __( 'Die Vollversion von PSeCommerce wurde mit BrainPress gebündelt.', 'brainpress' ); + $install_message2 = __( 'Die Vollversion von MarketPress wurde mit BrainPress gebündelt.', 'brainpress' ); } } $install_message = sprintf( $install_message, esc_url_raw( $install_url ) ); @@ -644,7 +644,7 @@ public static function step_6() { $payment_message = sprintf( '

%2$s

%3$s%4$s

%5$s: WooCommerce

', esc_attr( $is_paid_course ? '' : 'hidden' ), - __( 'Verkaufe Deine Kurse online mit PSeCommerce.', 'brainpress' ), + __( 'Verkaufe Deine Kurse online mit MarketPress.', 'brainpress' ), ! empty( $install_message2 ) ? sprintf( '

%s

', $install_message2 ) : '', ! empty( $install_message ) ? sprintf( '

%s

', $install_message ) : '', __( 'Andere unterstützte Plugins', 'brainpress' ) diff --git a/admin/class-settings.php b/admin/class-settings.php index f11e087..c86877d 100644 --- a/admin/class-settings.php +++ b/admin/class-settings.php @@ -11,7 +11,7 @@ class BrainPress_Admin_Settings extends BrainPress_Admin_Controller_Menu { 'BasicCertificate', 'Shortcodes', 'Extensions', - 'PSeCommerce', + 'MarketPress', 'WooCommerce', 'Setup', ); diff --git a/asset/js/brainpress-front.js b/asset/js/brainpress-front.js index 41ec865..51bda62 100644 --- a/asset/js/brainpress-front.js +++ b/asset/js/brainpress-front.js @@ -828,7 +828,7 @@ var BrainPress = BrainPress || {}; //$( '.view-response' ).link_popup( { link_text: '' }); $( '.workbook-table .view-response' ).link_popup( { link_text: '', offset_x: -160 }); $( '.workbook-table .feedback' ).link_popup( { link_text: '' }); - bind_psecommerce_add_to_cart_button(); + bind_marketpress_add_to_cart_button(); /** * close message @@ -1020,8 +1020,8 @@ var BrainPress = BrainPress || {}; /** * MP add to cart */ - function bind_psecommerce_add_to_cart_button() { - if ( undefined === _brainpress.psecommerce_is_used || 'no' === _brainpress.psecommerce_is_used ) { + function bind_marketpress_add_to_cart_button() { + if ( undefined === _brainpress.marketpress_is_used || 'no' === _brainpress.marketpress_is_used ) { return; } $('body.single-course button.mp_button-addcart').on( 'click', function() { @@ -1034,8 +1034,8 @@ var BrainPress = BrainPress || {}; cart_action: 'add_item' } }).done( function(data) { - if ( data.success && undefined !== _brainpress.psecommerce_cart_url ) { - window.location.assign( _brainpress.psecommerce_cart_url ); + if ( data.success && undefined !== _brainpress.marketpress_cart_url ) { + window.location.assign( _brainpress.marketpress_cart_url ); } }); return false; diff --git a/asset/js/brainpress-front.min.js b/asset/js/brainpress-front.min.js index 424b031..6511638 100644 --- a/asset/js/brainpress-front.min.js +++ b/asset/js/brainpress-front.min.js @@ -1,4 +1,4 @@ /*! BrainPress - v2.2.2 * https://github.com/cp-psourcepiestingtal_source/ps-brainpress-classicpress-lms-online-akademie-plugin/ * Copyright (c) 2019; * Licensed GPLv2+ */ -var BrainPress=BrainPress||{};!function(a){function b(){var b=a('[data-type="modal-step"]');void 0!==b&&b.length&&(BrainPress.Enrollment.Modal=Backbone.Modal.extend({template:_.template(a("#modal-template").html()),viewContainer:".enrollment-modal-container",submitEl:".done",cancelEl:".cancel",options:"meh",views:function(){var c={};return a.each(b,function(b,d){var e=b+1,f=a(d).attr("id");void 0!==f&&(c["click #step"+e]={view:_.template(a("#"+f).html()),onActive:"setActive"})}),c}(),events:{"click .previous":"previousStep","click .next":"nextStep","click .cancel-link":"closeDialog"},previousStep:function(a){a.preventDefault(),this.previous(),"function"==typeof this.onPrevious&&this.onPrevious()},nextStep:function(a){a.preventDefault(),this.next(),"function"==typeof this.onNext&&this.onNext()},closeDialog:function(){a(".enrolment-container-div").detach()},setActive:function(a){this.trigger("modal:updated",{view:this,options:a})},cancel:function(){a(".enrolment-container-div").detach()}}),BrainPress.Enrollment.dialog=new BrainPress.Enrollment.Modal,BrainPress.Enrollment.dialog.beforeSubmit=function(){var b=this.currentIndex;return d(b),b===BrainPress.Enrollment.dialog.views.length-1&&a(".enrolment-container-div").addClass("hidden"),!1},BrainPress.Enrollment.dialog.openAtAction=function(b){var c=a('[data-type="modal-step"]');a.each(c,function(c,d){var e=a(d).attr("data-modal-action");void 0!==e&&b===e&&BrainPress.Enrollment.dialog.openAt(c)})},BrainPress.Enrollment.dialog.on("modal:updated",function(){}),BrainPress.Enrollment.dialog.handle_signup_return=function(b){var c=b.signup_errors,d=a('[data-type="modal-step"]');if(0===c.length&&!0===b.user_data.logged_in)_brainpress.invitation_data?BrainPress.Enrollment.dialog.add_instructor(b):a.each(d,function(c,d){var e=a(d).attr("data-modal-action");"yes"===_brainpress.current_course_is_paid&&"paid_enrollment"===e?BrainPress.Enrollment.dialog.openAt(c):"enrolled"===e&&(b.already_enrolled?location.href=_brainpress.course_url:BrainPress.Enrollment.dialog.attempt_enroll(b))});else if(c.length>0){a(".bbm-wrapper #error-messages").html("");var e="",a(".bbm-wrapper #error-messages").html(e),a("input[name=password]").val(""),a("input[name=password_confirmation]").val("")}else a.each(d,function(a,b){"login"===b.attr("data-modal-action")&&BrainPress.Enrollment.dialog.openAt(a)})},BrainPress.Enrollment.dialog.handle_login_return=function(b){var c=b.signup_errors,d=a('[data-type="modal-step"]');if(0===c.length&&!0===b.logged_in)_brainpress.invitation_data?BrainPress.Enrollment.dialog.add_instructor(b):a.each(d,function(c,d){var e=a(d).attr("data-modal-action");"yes"===_brainpress.current_course_is_paid&&"paid_enrollment"===e?BrainPress.Enrollment.dialog.openAt(c):"enrolled"===e&&(b.already_enrolled?location.href=_brainpress.course_url:BrainPress.Enrollment.dialog.attempt_enroll(b))});else if(c.length>0){a(".bbm-wrapper #error-messages").html("");var e="",a(".bbm-wrapper #error-messages").html(e),a("input[name=password]").val("")}},BrainPress.Enrollment.dialog.handle_enroll_student_return=function(b){var c=a('[data-type="modal-step"]');!0===b.success&&a.each(c,function(b,c){var d=a(c).attr("data-modal-action");"yes"===_brainpress.current_course_is_paid&&"paid_enrollment"===d?BrainPress.Enrollment.dialog.openAt(b):"enrolled"===d&&BrainPress.Enrollment.dialog.openAt(b)}),a(".enrolment-container-div").removeClass("hidden")},BrainPress.Enrollment.dialog.signup_validation=function(){var b=!0;a(".bbm-wrapper #error-messages").html("");var c=[];""!==a("input[name=first_name]").val().trim()&&""!==a("input[name=last_name]").val().trim()&&""!==a("input[name=username]").val().trim()&&""!==a("input[name=email]").val().trim()&&""!==a("input[name=password]").val().trim()&&""!==a("input[name=password_confirmation]").val().trim()||(b=!1,c.push(_brainpress.signup_errors.all_fields));var d=BrainPress.utility.checkPasswordStrength(a("input[name=password]"),a("input[name=password_confirmation]"),a("#password-strength"),!1,[]);if(d<=2&&(b=!1,c.push(_brainpress.signup_errors.weak_password)),5===d&&(b=!1,c.push(_brainpress.signup_errors.mismatch_password)),c.length>0){var e="",a(".bbm-wrapper #error-messages").html(e)}return b},BrainPress.Enrollment.dialog.login_validation=function(){var b=!0;return a(".bbm-wrapper #error-messages").html(""),""!==a("input[name=log]").val().trim()&&""!==a("input[name=pwd]").val().trim()||(b=!1),b},BrainPress.Enrollment.dialog.signup_data=function(b){return b.first_name=a("input[name=first_name]").val(),b.last_name=a("input[name=last_name]").val(),b.username=a("input[name=username]").val(),b.email=a("input[name=email]").val(),b.password=a("input[name=password]").val(),b.nonce=a(".bbm-modal-nonce.signup").attr("data-nonce"),b},BrainPress.Enrollment.dialog.login_data=function(b){var c=a(".enrollment-modal-container.bbm-modal__views").attr("data-course");return b.username=a("input[name=log]").val(),b.password=a("input[name=pwd]").val(),b.course_id=c,b.nonce=a(".bbm-modal-nonce.login").attr("data-nonce"),b},BrainPress.Enrollment.dialog.attempt_enroll=function(b){var c=a(".enrollment-modal-container.bbm-modal__views").attr("data-nonce"),d=a(".enrollment-modal-container.bbm-modal__views").attr("data-course");if(void 0===c||void 0===d){var e=a(document.createElement("div"));e.html(_.template(a("#modal-template").html())()),e=a(e).find(".enrollment-modal-container")[0],c=a(e).attr("data-nonce"),d=a(e).attr("data-course")}BrainPress.Post.prepare("course_enrollment","enrollment:"),BrainPress.Post.set("action","enroll_student");var f={nonce:c,student_id:b.user_data.ID,course_id:d,step:""};BrainPress.Post.set("data",f),BrainPress.Post.save(),BrainPress.Post.off("brainpress:enrollment:enroll_student_success"),BrainPress.Post.on("brainpress:enrollment:enroll_student_success",function(b){if(a(".enrollment-modal-container.bbm-modal__views").attr("data-nonce",b.nonce),void 0!==b.callback){var c=BrainPress.Enrollment.dialog[b.callback];if("function"==typeof c)return void c(b)}})},BrainPress.Enrollment.dialog.new_nonce=function(a,b){BrainPress.Post.prepare("course_enrollment","enrollment:"),BrainPress.Post.set("action","get_nonce");var c={action:"get_nonce",nonce:a,step:""};BrainPress.Post.set("data",c),BrainPress.Post.save(),BrainPress.Post.off("brainpress:enrollment:get_nonce_success"),BrainPress.Post.on("brainpress:enrollment:get_nonce_success",b)},BrainPress.Enrollment.dialog.add_instructor=function(a){BrainPress.Enrollment.dialog.new_nonce("brainpress_add_instructor",function(b){var c=_brainpress.invitation_data.course_id;BrainPress.Post.prepare("course_enrollment","enrollment:"),BrainPress.Post.set("action","add_instructor");var d={action:"add_instructor",nonce:b.nonce,course_id:c,invite_code:_brainpress.invitation_data.code,instructor_id:a.user_data.ID,step:""};BrainPress.Post.set("data",d),BrainPress.Post.save(),BrainPress.Post.off("brainpress:enrollment:add_instructor_success"),BrainPress.Post.on("brainpress:enrollment:add_instructor_success",function(){BrainPress.Enrollment.dialog.openAtAction("instructor-verified")}),BrainPress.Post.off("brainpress:enrollment:add_instructor_error"),BrainPress.Post.on("brainpress:enrollment:add_instructor_error",function(){BrainPress.Enrollment.dialog.openAtAction("verification-failed")})})},a("body").on("keyup","input[name=password], input[name=password_confirmation]",function(){BrainPress.utility.checkPasswordStrength(a("input[name=password]"),a("input[name=password_confirmation]"),a("#password-strength"),!1,[])}))}function c(){var b=a(document.createElement("div"));if(a("body").append(b),a(b).addClass("enrolment-container-div"),_brainpress.current_student>0)if("yes"===_brainpress.current_course_is_paid)a(b).html(BrainPress.Enrollment.dialog.render().el),BrainPress.Enrollment.dialog.openAtAction("paid_enrollment");else{a(b).addClass("hidden");var c={user_data:{ID:parseInt(_brainpress.current_student)}};BrainPress.Enrollment.dialog.attempt_enroll(c),a(b).html(BrainPress.Enrollment.dialog.render().el)}else a(b).html(BrainPress.Enrollment.dialog.render().el)}function d(b){if(void 0===b)return!1;var c,d=a(a('[data-type="modal-step"]')[b]).attr("data-modal-action"),e=a(".enrollment-modal-container.bbm-modal__views").attr("data-nonce");if(BrainPress.Post.prepare("course_enrollment","enrollment:"),BrainPress.Post.set("action",d),!("signup"===d&&"function"==typeof(c=BrainPress.Enrollment.dialog.signup_validation)&&!0!==c()||"login"===d&&"function"==typeof(c=BrainPress.Enrollment.dialog.login_validation)&&!0!==c())){var f={nonce:e,step:b};c=BrainPress.Enrollment.dialog[d+"_data"],"function"==typeof c&&(f=c(f)),BrainPress.Post.set("data",f),BrainPress.Post.save(),BrainPress.Post.on("brainpress:enrollment:"+d+"_success",function(b){if(a(".enrollment-modal-container.bbm-modal__views").attr("data-nonce",b.nonce),void 0!==b.callback&&"function"==typeof(c=BrainPress.Enrollment.dialog[b.callback]))return void c(b);void 0!==b.last_step&&parseInt(b.last_step)0&&(window.location.href=b+"#"+c)}),a(".unit-archive-list-wrapper .module-title").on("click",function(){var b=a(a(a(this).parents(".unit-archive-single")[0]).find("a.unit-archive-single-title")[0]).attr("href"),c="module-"+a(this).attr("data-id");if(a(this).find("a.unit-archive-single-title").length>0&&(window.location.href=b+"#"+c),"focus"==a(".unit-archive-list-wrapper").data("view-mode")){var d=a("a",a(this)).attr("href").split("#"),b=a(a(a(this).parents(".unit-archive-single")[0]).find("a.unit-archive-single-title")[0]).attr("href")+"#"+d[1];window.location.href=b}}),a(".apply-button.signup, .apply-button.enroll").on("click",function(a){a=a||window.event,a.preventDefault(),a.stopPropagation(),a.stopImmediatePropagation(),c()}),a(".apply-button").on("click",function(b){var c=b.currentTarget;a(c).attr("data-link")&&(window.location.href=a(c).attr("data-link"))}),a("button").on("click",function(b){var c=b.currentTarget;a(c).attr("data-link")&&(window.location.href=a(c).attr("data-link"))}),a(".course_list_box_item.clickable").on("click",function(b){var c=b.currentTarget;a(c).attr("data-link")&&(window.location.href=a(c).attr("data-link"))}),a(".li-locked-unit a").on("click",function(a){a.stopImmediatePropagation(),a.preventDefault()}),a(".workbook-table .view-response").link_popup({link_text:'',offset_x:-160}),a(".workbook-table .feedback").link_popup({link_text:''}),g(),a(".course-message-container .course-message-close").on("click",function(){a(this).parent().slideUp()}),a(".unit-archive-single .fold").on("click",function(){var b=a(">ul",a(this).parent()),c=a(".unit-archive-single-title",a(this).parent()),d=a(".unit-archive-module-wrapper",a(this).parent()),e=a(this);return e.hasClass("folded")?b.slideDown(function(){e.removeClass("folded"),e.closest("li").removeClass("folded").addClass("unfolded"),c.attr("href",c.data("original-href")),c.off("click")}):b.slideUp(function(){if(e.addClass("folded"),e.closest("li").removeClass("unfolded").addClass("folded"),void 0===c.data("href")){var b=a(".module-seen",d).last();if(b.length&&(b=a(".module-title",b),b.length))return c.attr("href",c.attr("href")+"#module-"+b.data("id")),!1;var f=a(".section-seen",d).last();if(f.length&&(f=a(".section-title",f),f.length))return c.attr("href",c.attr("href")+"#section-"+f.data("id")),!1}}),!1}),a(".course-structure .unit .fold").on("click",function(){var b=a(this),c=b.parents("li").first(),d=c.find(".unit-structure-modules");c.is(".folded")?(c.removeClass("folded").addClass("unfolded"),b.removeClass("folded"),d.slideDown()):(c.removeClass("unfolded").addClass("folded"),b.addClass("folded"),d.slideUp())}),a(".brainpress-focus-view #commentform #submit").unbind("click").on("click",function(){var b,c=a(this).closest("form");if(""==a("#comment",c).val())return alert(_brainpress.comments.require_valid_comment),!1;a("#respond #cancel-comment-reply-link").hide(),c.append('
'),b=a(".mask",c),b.css({width:c.width()+"px",height:c.height()+"px"}),a("span",b).css({marginTop:c.height()/2-20+"px"});var d=new BrainPress.Models.CourseFront;return d.set("action","comment_add_new"),d.set("comment_parent",a("#comment_parent",c).val()),d.set("comment_post_ID",a("#comment_post_ID",c).val()),d.set("comment_content",a("#comment",c).val()),d.set("brainpress_subscribe",a("[name=brainpress_subscribe]",c).val()),d.set("nonce",a("#brainpress-add-commment-nonce",c).val()),d.save(),d.off("brainpress:comment_add_new_success"),d.on("brainpress:comment_add_new_success",function(b){var d=a(".focus-nav-next.module-is-not-done");if("single-comment"==b.answer_mode){if(0==b.data.comment_parent){0'),a(".children",comment_parent).first().append(b.data.html),a(".comments-list").before(a("#respond"));a("#comment").val(""),a("#comment_parent").val(0);var e,g=a("#comment-"+b.data.comment_id);0'+_brainpress.invalid_upload_message+f+""),i.closest("form").removeClass("is-valid-file"))}),a(".module-submit-action").on("click",function(){return})}function i(){var b=a("ul.units-archive-list a").css("color"),c=a("body").css("color").replace("rgb(","").replace(")","").split(","),d="rgba("+c[0]+", "+c[1]+", "+c[2]+", 1)";a(".course-progress-disc").each(function(){var c=a(this).data(),e=b,f="center",g=4.5,h=!0,i={duration:1200,easing:"circleProgressEase"};c.knobFgColor&&(b=c.knobFgColor),c.knobEmptyColor&&(d=c.knobEmptyColor),c.knobTextColor&&(e=c.knobTextColor),c.knobTextAlign&&(f=c.knobTextAlign),c.knobTextDenominator&&(g=c.knobTextDenominator),void 0!==c.knobTextShow&&(h=c.knobTextShow),void 0!==c.knobAnimation&&(i=c.knobAnimation);var j={color:b};a(this).circleProgress({fill:j,emptyFill:d,animation:i});a(this).parents("ul")[0];a(this).on("circle-animation-progress",function(b,c){var d=a(this).data("circle-progress"),i=d.ctx,j=d.size,k=(100*c).toFixed(),l=(100*d.value).toFixed();k=100-k,k'+n+"%")})}function j(){a(".course-discussion-content.new .button-links .submit-discussion").on("click",function(){a(this).parents("form").submit()})}function k(){var b=a(".brainpress-focus-view");void 0!==b&&b.length>0&&BrainPress.FocusMode.init_focus_mode()}BrainPress.Models=BrainPress.Models||{},BrainPress.UI=BrainPress.UI||{},BrainPress.utility=BrainPress.utility||{},BrainPress.Events=BrainPress.Events||{},BrainPress.utility.timer_validate=function(a,b){return"ref_"+(BrainPress.utility.hashcode(""+a)+"").split("").reverse().join("")===b},BrainPress.utility.checkPasswordStrength=function(a,b,c,d,e){var f=a.val(),g=b.val();d&&d.attr("disabled","disabled"),c.removeClass("short bad good strong"),e=e.concat(wp.passwordStrength.userInputBlacklist());var h=wp.passwordStrength.meter(f,e,g);switch(h){case 2:c.addClass("bad").html(pwsL10n.bad);break;case 3:c.addClass("good").html(pwsL10n.good);break;case 4:c.addClass("strong").html(pwsL10n.strong);break;case 5:c.addClass("short").html(pwsL10n.mismatch);break;default:c.addClass("short").html(pwsL10n.short)}return d&&20&&(BrainPress.actions[a].forEach(function(a){c[a.priority]=c[a.priority]||[],c[a.priority].push(a.callback)}),c.forEach(function(a){a.forEach(function(a){a(b)})}))},BrainPress.apply_filters=function(a,b,c){var d=[];return void 0!==BrainPress.filters[a]&&BrainPress.filters[a].length>0&&(BrainPress.filters[a].forEach(function(a){d[a.priority]=d[a.priority]||[],d[a.priority].push(a.callback)}),d.forEach(function(a){a.forEach(function(a){b=a(b,c)})})),b},BrainPress.Models.CourseFront=Backbone.Model.extend({url:_brainpress._ajax_url+"?action=course_front",parse:function(a){!0===a.success?(this.set("response_data",a.data),this.trigger("brainpress:"+a.data.action+"_success",a.data)):(this.set("response_data",{}),a.data&&this.trigger("brainpress:"+a.data.action+"_error",a.data))},defaults:{}}),BrainPress.Models.Post=BrainPress.Models.Post||Backbone.Model.extend({url:_brainpress._ajax_url+"?action=",parse:function(a){var b=this.get("context");if(!0===a.success){void 0===a.data&&(a.data={}),this.set("response_data",a.data);var c="brainpress:"+b+a.data.action+"_success";this.trigger(c,a.data)}else 0!==a&&(this.set("response_data",{}),this.trigger("brainpress:"+b+a.data.action+"_error",a.data));BrainPress.Post.set("action","")},prepare:function(a,b){this.url=this.get("base_url")+a,void 0!==b&&this.set("context",b)},defaults:{base_url:_brainpress._ajax_url+"?action=",context:"response:"}}),BrainPress.Post=new BrainPress.Models.Post,BrainPress.Enrollment=BrainPress.Enrollment||{},BrainPress.Page=BrainPress.Page||{},BrainPress.Enrollment.dialog=BrainPress.Enrollment.dialog||{},BrainPress.FocusMode=BrainPress.FocusMode||{},BrainPress.FocusMode.bind_focus_nav=function(){a(".brainpress-focus-view .focus-nav-prev").off("click"),a(".brainpress-focus-view .focus-nav-next").off("click"),a(".brainpress-focus-view .focus-nav-reload").off("click"),a(".brainpress-focus-view a.breadcrumb-course-unit-section.crumb").off("click"),a(".brainpress-focus-view a.nav-go-back-link").off("click"),a(".brainpress-focus-view a.nav-go-back-link").on("click",function(b){b.preventDefault();var c=a(this).attr("href");return window.location.href=c,window.location.reload(),!1}),a(".brainpress-focus-view .focus-nav-prev, .brainpress-focus-view .focus-nav-next, .brainpress-focus-view .focus-nav-reload").on("click",function(){if(a(this).hasClass("module-is-not-done")){b();var c=a(document.createElement("div"));return a("body").append(c),a(c).addClass("enrolment-container-div"),a(c).html(BrainPress.Enrollment.dialog.render().el),BrainPress.Enrollment.dialog.openAtAction("mandatory"),!1}var d=a(".brainpress-focus-view"),e=a(this).attr("data-type"),f=a(this).attr("data-id"),g=a(this).attr("data-unit"),h=d.attr("data-unit"),i=a(this).attr("data-url"),j=0;if(e||f){if(a(".brainpress-focus-view .loader").removeClass("hidden"),a(".brainpress-focus-view .focus-main").hide("fast"),g&&g.length&&i&&h&&g!==h)return a("body,html").animate({scrollTop:j,duration:100}),window.location.href=i,!1;i&&i.length&&d.attr("data-url",i),j=a(".entry-title").length>0?a(".entry-title").offset().top-32:32,j=BrainPress.apply_filters("brainpress_focus_top_offset",j),a("body,html").animate({scrollTop:j,duration:100}),BrainPress.FocusMode.load_focus_item(e,f)}}),a("a.breadcrumb-course-unit-section.crumb, a.breadcrumb-course-unit.crumb").on("click",function(){var b="section",c=a(this).attr("data-id");a(".brainpress-focus-view .loader").removeClass("hidden"),a(".brainpress-focus-view .focus-main").hide("fast");var d=0;d=a(".entry-title").length>0?a(".entry-title").offset().top-32:32,d=BrainPress.apply_filters("brainpress_focus_top_offset",d),a("body,html").animate({scrollTop:d,duration:100}),BrainPress.FocusMode.load_focus_item(b,c)})},BrainPress.FocusMode.load_focus_item=function(b,c){function d(){BrainPress.FocusMode.bind_focus_nav(),BrainPress.Page.init(),a("audio").css("visibility","visible"),a("audio").css("outline","none"),a(".quiz_timer").brainpress_timer({toggle_element:a(".quiz_timer").siblings(".module-quiz-questions"),seconds:parseInt(a(".quiz_timer").attr("data-time")),action:"none",running:!1}),a(".quiz_timer").on("timer_started",function(){}),a(".quiz_timer").on("timer_ended",function(){}),null!==location.hash.match(/^#comment-/)&&a("html, body").animate({scrollTop:a(location.hash).offset().top},0);var b=a(".course-structure-block ul.tree");b.length&&(a(".module",b).removeClass("current-module"),a(".module-"+f.item_id,b).addClass("current-module"));var c=a(".course-redirect-data");if(c.length&&"unit-not-available"==c.data("redirect")){var d=_brainpress.course_url_unit_nor_available;d+="&type="+c.data("type"),d+="&id="+c.data("id")}}BrainPress.Post.prepare("course_front","focus:"),BrainPress.Post.set("action","get_unit_"+b),void 0!==c&&0!==c.length||(c=1);var e=a(".brainpress-focus-view"),f={course_id:e.attr("data-course"),unit_id:e.attr("data-unit"),type:b,item_id:c},g=e.attr("data-url");g&&g.length&&(g=g.replace("http://","//").replace("https://","//"),window.history.replaceState("","BrainPress",g)),a(".brainpress-focus-view").load(_brainpress.home_url+"/brainpress_focus/"+f.course_id+"/"+f.unit_id+"/"+f.type+"/"+f.item_id,d)};var l=function(){var b=a(".course-structure-block");if(b.length>0){var c=b.data("nonce"),d=b.data(),e=d.course,f=window.location,g={data:d,course_id:e,nonce:c};a.get(f,g,function(a){b.replaceWith(a)})}};BrainPress.Events.on("brainpress:module_change",l),BrainPress.FocusMode.init_focus_mode=function(){var b,c=null!==location.hash.match(/^#module-/),d=null!==location.hash.match(/^#section-/),e=null!==location.hash.match(/^#comment-/);if(c||d||e||(d=!0),c&&(b=location.hash.replace("#module-",""),BrainPress.FocusMode.load_focus_item("module",b)),d){if(void 0===(b=location.hash)||0===b.length){var f=a(".brainpress-focus-view");b=a(f).attr("data-page")}b=b.replace("#section-",""),BrainPress.FocusMode.load_focus_item("section",b)}e&&(b=location.hash.replace("#comment-",""),BrainPress.FocusMode.load_focus_item("comment",b))},BrainPress.Page.init=function(){var b=a(".brainpress-focus-view").length>0;f(),h(),j(),i(),b||(a(".quiz_timer").brainpress_timer(),a(".quiz_timer").on("timer_started",function(){}),a(".quiz_timer").on("timer_ended",function(){}))},BrainPress.toggleModule=function(){var b=a(this),c=b.data("module"),d=a("#cp-element-"+c);return a("#cp-response-"+c).addClass("hide"),d.removeClass("hide"),!1},a(document).ready(function(){BrainPress.Page.init(),b(),k(),e(),a("#cp-unsubscribe-message").length>0&&(a('
').html(BrainPress.Enrollment.dialog.render().el).appendTo("body"),BrainPress.Enrollment.dialog.openAtAction("unsubscribe"))}).on("click",".cp .button-reload-module",BrainPress.toggleModule),a(document).on('keydown',function(b){if(!(b.ctrlKey||b.altKey||b.shiftKey||b.metaKey)){var c=a(":focus");if(00&&a(".focus-nav .focus-nav-prev a").trigger("click");break;case 39:a(".focus-nav .focus-nav-next a").length>0&&a(".focus-nav .focus-nav-next a").trigger("click")}}})}(jQuery),BrainPress.current=BrainPress.current||{}; \ No newline at end of file +var BrainPress=BrainPress||{};!function(a){function b(){var b=a('[data-type="modal-step"]');void 0!==b&&b.length&&(BrainPress.Enrollment.Modal=Backbone.Modal.extend({template:_.template(a("#modal-template").html()),viewContainer:".enrollment-modal-container",submitEl:".done",cancelEl:".cancel",options:"meh",views:function(){var c={};return a.each(b,function(b,d){var e=b+1,f=a(d).attr("id");void 0!==f&&(c["click #step"+e]={view:_.template(a("#"+f).html()),onActive:"setActive"})}),c}(),events:{"click .previous":"previousStep","click .next":"nextStep","click .cancel-link":"closeDialog"},previousStep:function(a){a.preventDefault(),this.previous(),"function"==typeof this.onPrevious&&this.onPrevious()},nextStep:function(a){a.preventDefault(),this.next(),"function"==typeof this.onNext&&this.onNext()},closeDialog:function(){a(".enrolment-container-div").detach()},setActive:function(a){this.trigger("modal:updated",{view:this,options:a})},cancel:function(){a(".enrolment-container-div").detach()}}),BrainPress.Enrollment.dialog=new BrainPress.Enrollment.Modal,BrainPress.Enrollment.dialog.beforeSubmit=function(){var b=this.currentIndex;return d(b),b===BrainPress.Enrollment.dialog.views.length-1&&a(".enrolment-container-div").addClass("hidden"),!1},BrainPress.Enrollment.dialog.openAtAction=function(b){var c=a('[data-type="modal-step"]');a.each(c,function(c,d){var e=a(d).attr("data-modal-action");void 0!==e&&b===e&&BrainPress.Enrollment.dialog.openAt(c)})},BrainPress.Enrollment.dialog.on("modal:updated",function(){}),BrainPress.Enrollment.dialog.handle_signup_return=function(b){var c=b.signup_errors,d=a('[data-type="modal-step"]');if(0===c.length&&!0===b.user_data.logged_in)_brainpress.invitation_data?BrainPress.Enrollment.dialog.add_instructor(b):a.each(d,function(c,d){var e=a(d).attr("data-modal-action");"yes"===_brainpress.current_course_is_paid&&"paid_enrollment"===e?BrainPress.Enrollment.dialog.openAt(c):"enrolled"===e&&(b.already_enrolled?location.href=_brainpress.course_url:BrainPress.Enrollment.dialog.attempt_enroll(b))});else if(c.length>0){a(".bbm-wrapper #error-messages").html("");var e="
    ";c.forEach(function(a){e+="
  • "+a+"
  • "}),e+="
",a(".bbm-wrapper #error-messages").html(e),a("input[name=password]").val(""),a("input[name=password_confirmation]").val("")}else a.each(d,function(a,b){"login"===b.attr("data-modal-action")&&BrainPress.Enrollment.dialog.openAt(a)})},BrainPress.Enrollment.dialog.handle_login_return=function(b){var c=b.signup_errors,d=a('[data-type="modal-step"]');if(0===c.length&&!0===b.logged_in)_brainpress.invitation_data?BrainPress.Enrollment.dialog.add_instructor(b):a.each(d,function(c,d){var e=a(d).attr("data-modal-action");"yes"===_brainpress.current_course_is_paid&&"paid_enrollment"===e?BrainPress.Enrollment.dialog.openAt(c):"enrolled"===e&&(b.already_enrolled?location.href=_brainpress.course_url:BrainPress.Enrollment.dialog.attempt_enroll(b))});else if(c.length>0){a(".bbm-wrapper #error-messages").html("");var e="
    ";c.forEach(function(a){e+="
  • "+a+"
  • "}),e+="
",a(".bbm-wrapper #error-messages").html(e),a("input[name=password]").val("")}},BrainPress.Enrollment.dialog.handle_enroll_student_return=function(b){var c=a('[data-type="modal-step"]');!0===b.success&&a.each(c,function(b,c){var d=a(c).attr("data-modal-action");"yes"===_brainpress.current_course_is_paid&&"paid_enrollment"===d?BrainPress.Enrollment.dialog.openAt(b):"enrolled"===d&&BrainPress.Enrollment.dialog.openAt(b)}),a(".enrolment-container-div").removeClass("hidden")},BrainPress.Enrollment.dialog.signup_validation=function(){var b=!0;a(".bbm-wrapper #error-messages").html("");var c=[];""!==a("input[name=first_name]").val().trim()&&""!==a("input[name=last_name]").val().trim()&&""!==a("input[name=username]").val().trim()&&""!==a("input[name=email]").val().trim()&&""!==a("input[name=password]").val().trim()&&""!==a("input[name=password_confirmation]").val().trim()||(b=!1,c.push(_brainpress.signup_errors.all_fields));var d=BrainPress.utility.checkPasswordStrength(a("input[name=password]"),a("input[name=password_confirmation]"),a("#password-strength"),!1,[]);if(d<=2&&(b=!1,c.push(_brainpress.signup_errors.weak_password)),5===d&&(b=!1,c.push(_brainpress.signup_errors.mismatch_password)),c.length>0){var e="
    ";c.forEach(function(a){e+="
  • "+a+"
  • "}),e+="
",a(".bbm-wrapper #error-messages").html(e)}return b},BrainPress.Enrollment.dialog.login_validation=function(){var b=!0;return a(".bbm-wrapper #error-messages").html(""),""!==a("input[name=log]").val().trim()&&""!==a("input[name=pwd]").val().trim()||(b=!1),b},BrainPress.Enrollment.dialog.signup_data=function(b){return b.first_name=a("input[name=first_name]").val(),b.last_name=a("input[name=last_name]").val(),b.username=a("input[name=username]").val(),b.email=a("input[name=email]").val(),b.password=a("input[name=password]").val(),b.nonce=a(".bbm-modal-nonce.signup").attr("data-nonce"),b},BrainPress.Enrollment.dialog.login_data=function(b){var c=a(".enrollment-modal-container.bbm-modal__views").attr("data-course");return b.username=a("input[name=log]").val(),b.password=a("input[name=pwd]").val(),b.course_id=c,b.nonce=a(".bbm-modal-nonce.login").attr("data-nonce"),b},BrainPress.Enrollment.dialog.attempt_enroll=function(b){var c=a(".enrollment-modal-container.bbm-modal__views").attr("data-nonce"),d=a(".enrollment-modal-container.bbm-modal__views").attr("data-course");if(void 0===c||void 0===d){var e=a(document.createElement("div"));e.html(_.template(a("#modal-template").html())()),e=a(e).find(".enrollment-modal-container")[0],c=a(e).attr("data-nonce"),d=a(e).attr("data-course")}BrainPress.Post.prepare("course_enrollment","enrollment:"),BrainPress.Post.set("action","enroll_student");var f={nonce:c,student_id:b.user_data.ID,course_id:d,step:""};BrainPress.Post.set("data",f),BrainPress.Post.save(),BrainPress.Post.off("brainpress:enrollment:enroll_student_success"),BrainPress.Post.on("brainpress:enrollment:enroll_student_success",function(b){if(a(".enrollment-modal-container.bbm-modal__views").attr("data-nonce",b.nonce),void 0!==b.callback){var c=BrainPress.Enrollment.dialog[b.callback];if("function"==typeof c)return void c(b)}})},BrainPress.Enrollment.dialog.new_nonce=function(a,b){BrainPress.Post.prepare("course_enrollment","enrollment:"),BrainPress.Post.set("action","get_nonce");var c={action:"get_nonce",nonce:a,step:""};BrainPress.Post.set("data",c),BrainPress.Post.save(),BrainPress.Post.off("brainpress:enrollment:get_nonce_success"),BrainPress.Post.on("brainpress:enrollment:get_nonce_success",b)},BrainPress.Enrollment.dialog.add_instructor=function(a){BrainPress.Enrollment.dialog.new_nonce("brainpress_add_instructor",function(b){var c=_brainpress.invitation_data.course_id;BrainPress.Post.prepare("course_enrollment","enrollment:"),BrainPress.Post.set("action","add_instructor");var d={action:"add_instructor",nonce:b.nonce,course_id:c,invite_code:_brainpress.invitation_data.code,instructor_id:a.user_data.ID,step:""};BrainPress.Post.set("data",d),BrainPress.Post.save(),BrainPress.Post.off("brainpress:enrollment:add_instructor_success"),BrainPress.Post.on("brainpress:enrollment:add_instructor_success",function(){BrainPress.Enrollment.dialog.openAtAction("instructor-verified")}),BrainPress.Post.off("brainpress:enrollment:add_instructor_error"),BrainPress.Post.on("brainpress:enrollment:add_instructor_error",function(){BrainPress.Enrollment.dialog.openAtAction("verification-failed")})})},a("body").on("keyup","input[name=password], input[name=password_confirmation]",function(){BrainPress.utility.checkPasswordStrength(a("input[name=password]"),a("input[name=password_confirmation]"),a("#password-strength"),!1,[])}))}function c(){var b=a(document.createElement("div"));if(a("body").append(b),a(b).addClass("enrolment-container-div"),_brainpress.current_student>0)if("yes"===_brainpress.current_course_is_paid)a(b).html(BrainPress.Enrollment.dialog.render().el),BrainPress.Enrollment.dialog.openAtAction("paid_enrollment");else{a(b).addClass("hidden");var c={user_data:{ID:parseInt(_brainpress.current_student)}};BrainPress.Enrollment.dialog.attempt_enroll(c),a(b).html(BrainPress.Enrollment.dialog.render().el)}else a(b).html(BrainPress.Enrollment.dialog.render().el)}function d(b){if(void 0===b)return!1;var c,d=a(a('[data-type="modal-step"]')[b]).attr("data-modal-action"),e=a(".enrollment-modal-container.bbm-modal__views").attr("data-nonce");if(BrainPress.Post.prepare("course_enrollment","enrollment:"),BrainPress.Post.set("action",d),!("signup"===d&&"function"==typeof(c=BrainPress.Enrollment.dialog.signup_validation)&&!0!==c()||"login"===d&&"function"==typeof(c=BrainPress.Enrollment.dialog.login_validation)&&!0!==c())){var f={nonce:e,step:b};c=BrainPress.Enrollment.dialog[d+"_data"],"function"==typeof c&&(f=c(f)),BrainPress.Post.set("data",f),BrainPress.Post.save(),BrainPress.Post.on("brainpress:enrollment:"+d+"_success",function(b){if(a(".enrollment-modal-container.bbm-modal__views").attr("data-nonce",b.nonce),void 0!==b.callback&&"function"==typeof(c=BrainPress.Enrollment.dialog[b.callback]))return void c(b);void 0!==b.last_step&&parseInt(b.last_step)0&&(window.location.href=b+"#"+c)}),a(".unit-archive-list-wrapper .module-title").on("click",function(){var b=a(a(a(this).parents(".unit-archive-single")[0]).find("a.unit-archive-single-title")[0]).attr("href"),c="module-"+a(this).attr("data-id");if(a(this).find("a.unit-archive-single-title").length>0&&(window.location.href=b+"#"+c),"focus"==a(".unit-archive-list-wrapper").data("view-mode")){var d=a("a",a(this)).attr("href").split("#"),b=a(a(a(this).parents(".unit-archive-single")[0]).find("a.unit-archive-single-title")[0]).attr("href")+"#"+d[1];window.location.href=b}}),a(".apply-button.signup, .apply-button.enroll").on("click",function(a){a=a||window.event,a.preventDefault(),a.stopPropagation(),a.stopImmediatePropagation(),c()}),a(".apply-button").on("click",function(b){var c=b.currentTarget;a(c).attr("data-link")&&(window.location.href=a(c).attr("data-link"))}),a("button").on("click",function(b){var c=b.currentTarget;a(c).attr("data-link")&&(window.location.href=a(c).attr("data-link"))}),a(".course_list_box_item.clickable").on("click",function(b){var c=b.currentTarget;a(c).attr("data-link")&&(window.location.href=a(c).attr("data-link"))}),a(".li-locked-unit a").on("click",function(a){a.stopImmediatePropagation(),a.preventDefault()}),a(".workbook-table .view-response").link_popup({link_text:'',offset_x:-160}),a(".workbook-table .feedback").link_popup({link_text:''}),g(),a(".course-message-container .course-message-close").on("click",function(){a(this).parent().slideUp()}),a(".unit-archive-single .fold").on("click",function(){var b=a(">ul",a(this).parent()),c=a(".unit-archive-single-title",a(this).parent()),d=a(".unit-archive-module-wrapper",a(this).parent()),e=a(this);return e.hasClass("folded")?b.slideDown(function(){e.removeClass("folded"),e.closest("li").removeClass("folded").addClass("unfolded"),c.attr("href",c.data("original-href")),c.off("click")}):b.slideUp(function(){if(e.addClass("folded"),e.closest("li").removeClass("unfolded").addClass("folded"),void 0===c.data("href")){var b=a(".module-seen",d).last();if(b.length&&(b=a(".module-title",b),b.length))return c.attr("href",c.attr("href")+"#module-"+b.data("id")),!1;var f=a(".section-seen",d).last();if(f.length&&(f=a(".section-title",f),f.length))return c.attr("href",c.attr("href")+"#section-"+f.data("id")),!1}}),!1}),a(".course-structure .unit .fold").on("click",function(){var b=a(this),c=b.parents("li").first(),d=c.find(".unit-structure-modules");c.is(".folded")?(c.removeClass("folded").addClass("unfolded"),b.removeClass("folded"),d.slideDown()):(c.removeClass("unfolded").addClass("folded"),b.addClass("folded"),d.slideUp())}),a(".brainpress-focus-view #commentform #submit").unbind("click").on("click",function(){var b,c=a(this).closest("form");if(""==a("#comment",c).val())return alert(_brainpress.comments.require_valid_comment),!1;a("#respond #cancel-comment-reply-link").hide(),c.append('
'),b=a(".mask",c),b.css({width:c.width()+"px",height:c.height()+"px"}),a("span",b).css({marginTop:c.height()/2-20+"px"});var d=new BrainPress.Models.CourseFront;return d.set("action","comment_add_new"),d.set("comment_parent",a("#comment_parent",c).val()),d.set("comment_post_ID",a("#comment_post_ID",c).val()),d.set("comment_content",a("#comment",c).val()),d.set("brainpress_subscribe",a("[name=brainpress_subscribe]",c).val()),d.set("nonce",a("#brainpress-add-commment-nonce",c).val()),d.save(),d.off("brainpress:comment_add_new_success"),d.on("brainpress:comment_add_new_success",function(b){var d=a(".focus-nav-next.module-is-not-done");if("single-comment"==b.answer_mode){if(0==b.data.comment_parent){0'),a(".children",comment_parent).first().append(b.data.html),a(".comments-list").before(a("#respond"));a("#comment").val(""),a("#comment_parent").val(0);var e,g=a("#comment-"+b.data.comment_id);0'+_brainpress.invalid_upload_message+f+""),i.closest("form").removeClass("is-valid-file"))}),a(".module-submit-action").on("click",function(){return})}function i(){var b=a("ul.units-archive-list a").css("color"),c=a("body").css("color").replace("rgb(","").replace(")","").split(","),d="rgba("+c[0]+", "+c[1]+", "+c[2]+", 1)";a(".course-progress-disc").each(function(){var c=a(this).data(),e=b,f="center",g=4.5,h=!0,i={duration:1200,easing:"circleProgressEase"};c.knobFgColor&&(b=c.knobFgColor),c.knobEmptyColor&&(d=c.knobEmptyColor),c.knobTextColor&&(e=c.knobTextColor),c.knobTextAlign&&(f=c.knobTextAlign),c.knobTextDenominator&&(g=c.knobTextDenominator),void 0!==c.knobTextShow&&(h=c.knobTextShow),void 0!==c.knobAnimation&&(i=c.knobAnimation);var j={color:b};a(this).circleProgress({fill:j,emptyFill:d,animation:i});a(this).parents("ul")[0];a(this).on("circle-animation-progress",function(b,c){var d=a(this).data("circle-progress"),i=d.ctx,j=d.size,k=(100*c).toFixed(),l=(100*d.value).toFixed();k=100-k,k'+n+"%")})}function j(){a(".course-discussion-content.new .button-links .submit-discussion").on("click",function(){a(this).parents("form").submit()})}function k(){var b=a(".brainpress-focus-view");void 0!==b&&b.length>0&&BrainPress.FocusMode.init_focus_mode()}BrainPress.Models=BrainPress.Models||{},BrainPress.UI=BrainPress.UI||{},BrainPress.utility=BrainPress.utility||{},BrainPress.Events=BrainPress.Events||{},BrainPress.utility.timer_validate=function(a,b){return"ref_"+(BrainPress.utility.hashcode(""+a)+"").split("").reverse().join("")===b},BrainPress.utility.checkPasswordStrength=function(a,b,c,d,e){var f=a.val(),g=b.val();d&&d.attr("disabled","disabled"),c.removeClass("short bad good strong"),e=e.concat(wp.passwordStrength.userInputBlacklist());var h=wp.passwordStrength.meter(f,e,g);switch(h){case 2:c.addClass("bad").html(pwsL10n.bad);break;case 3:c.addClass("good").html(pwsL10n.good);break;case 4:c.addClass("strong").html(pwsL10n.strong);break;case 5:c.addClass("short").html(pwsL10n.mismatch);break;default:c.addClass("short").html(pwsL10n.short)}return d&&20&&(BrainPress.actions[a].forEach(function(a){c[a.priority]=c[a.priority]||[],c[a.priority].push(a.callback)}),c.forEach(function(a){a.forEach(function(a){a(b)})}))},BrainPress.apply_filters=function(a,b,c){var d=[];return void 0!==BrainPress.filters[a]&&BrainPress.filters[a].length>0&&(BrainPress.filters[a].forEach(function(a){d[a.priority]=d[a.priority]||[],d[a.priority].push(a.callback)}),d.forEach(function(a){a.forEach(function(a){b=a(b,c)})})),b},BrainPress.Models.CourseFront=Backbone.Model.extend({url:_brainpress._ajax_url+"?action=course_front",parse:function(a){!0===a.success?(this.set("response_data",a.data),this.trigger("brainpress:"+a.data.action+"_success",a.data)):(this.set("response_data",{}),a.data&&this.trigger("brainpress:"+a.data.action+"_error",a.data))},defaults:{}}),BrainPress.Models.Post=BrainPress.Models.Post||Backbone.Model.extend({url:_brainpress._ajax_url+"?action=",parse:function(a){var b=this.get("context");if(!0===a.success){void 0===a.data&&(a.data={}),this.set("response_data",a.data);var c="brainpress:"+b+a.data.action+"_success";this.trigger(c,a.data)}else 0!==a&&(this.set("response_data",{}),this.trigger("brainpress:"+b+a.data.action+"_error",a.data));BrainPress.Post.set("action","")},prepare:function(a,b){this.url=this.get("base_url")+a,void 0!==b&&this.set("context",b)},defaults:{base_url:_brainpress._ajax_url+"?action=",context:"response:"}}),BrainPress.Post=new BrainPress.Models.Post,BrainPress.Enrollment=BrainPress.Enrollment||{},BrainPress.Page=BrainPress.Page||{},BrainPress.Enrollment.dialog=BrainPress.Enrollment.dialog||{},BrainPress.FocusMode=BrainPress.FocusMode||{},BrainPress.FocusMode.bind_focus_nav=function(){a(".brainpress-focus-view .focus-nav-prev").off("click"),a(".brainpress-focus-view .focus-nav-next").off("click"),a(".brainpress-focus-view .focus-nav-reload").off("click"),a(".brainpress-focus-view a.breadcrumb-course-unit-section.crumb").off("click"),a(".brainpress-focus-view a.nav-go-back-link").off("click"),a(".brainpress-focus-view a.nav-go-back-link").on("click",function(b){b.preventDefault();var c=a(this).attr("href");return window.location.href=c,window.location.reload(),!1}),a(".brainpress-focus-view .focus-nav-prev, .brainpress-focus-view .focus-nav-next, .brainpress-focus-view .focus-nav-reload").on("click",function(){if(a(this).hasClass("module-is-not-done")){b();var c=a(document.createElement("div"));return a("body").append(c),a(c).addClass("enrolment-container-div"),a(c).html(BrainPress.Enrollment.dialog.render().el),BrainPress.Enrollment.dialog.openAtAction("mandatory"),!1}var d=a(".brainpress-focus-view"),e=a(this).attr("data-type"),f=a(this).attr("data-id"),g=a(this).attr("data-unit"),h=d.attr("data-unit"),i=a(this).attr("data-url"),j=0;if(e||f){if(a(".brainpress-focus-view .loader").removeClass("hidden"),a(".brainpress-focus-view .focus-main").hide("fast"),g&&g.length&&i&&h&&g!==h)return a("body,html").animate({scrollTop:j,duration:100}),window.location.href=i,!1;i&&i.length&&d.attr("data-url",i),j=a(".entry-title").length>0?a(".entry-title").offset().top-32:32,j=BrainPress.apply_filters("brainpress_focus_top_offset",j),a("body,html").animate({scrollTop:j,duration:100}),BrainPress.FocusMode.load_focus_item(e,f)}}),a("a.breadcrumb-course-unit-section.crumb, a.breadcrumb-course-unit.crumb").on("click",function(){var b="section",c=a(this).attr("data-id");a(".brainpress-focus-view .loader").removeClass("hidden"),a(".brainpress-focus-view .focus-main").hide("fast");var d=0;d=a(".entry-title").length>0?a(".entry-title").offset().top-32:32,d=BrainPress.apply_filters("brainpress_focus_top_offset",d),a("body,html").animate({scrollTop:d,duration:100}),BrainPress.FocusMode.load_focus_item(b,c)})},BrainPress.FocusMode.load_focus_item=function(b,c){function d(){BrainPress.FocusMode.bind_focus_nav(),BrainPress.Page.init(),a("audio").css("visibility","visible"),a("audio").css("outline","none"),a(".quiz_timer").brainpress_timer({toggle_element:a(".quiz_timer").siblings(".module-quiz-questions"),seconds:parseInt(a(".quiz_timer").attr("data-time")),action:"none",running:!1}),a(".quiz_timer").on("timer_started",function(){}),a(".quiz_timer").on("timer_ended",function(){}),null!==location.hash.match(/^#comment-/)&&a("html, body").animate({scrollTop:a(location.hash).offset().top},0);var b=a(".course-structure-block ul.tree");b.length&&(a(".module",b).removeClass("current-module"),a(".module-"+f.item_id,b).addClass("current-module"));var c=a(".course-redirect-data");if(c.length&&"unit-not-available"==c.data("redirect")){var d=_brainpress.course_url_unit_nor_available;d+="&type="+c.data("type"),d+="&id="+c.data("id")}}BrainPress.Post.prepare("course_front","focus:"),BrainPress.Post.set("action","get_unit_"+b),void 0!==c&&0!==c.length||(c=1);var e=a(".brainpress-focus-view"),f={course_id:e.attr("data-course"),unit_id:e.attr("data-unit"),type:b,item_id:c},g=e.attr("data-url");g&&g.length&&(g=g.replace("http://","//").replace("https://","//"),window.history.replaceState("","BrainPress",g)),a(".brainpress-focus-view").load(_brainpress.home_url+"/brainpress_focus/"+f.course_id+"/"+f.unit_id+"/"+f.type+"/"+f.item_id,d)};var l=function(){var b=a(".course-structure-block");if(b.length>0){var c=b.data("nonce"),d=b.data(),e=d.course,f=window.location,g={data:d,course_id:e,nonce:c};a.get(f,g,function(a){b.replaceWith(a)})}};BrainPress.Events.on("brainpress:module_change",l),BrainPress.FocusMode.init_focus_mode=function(){var b,c=null!==location.hash.match(/^#module-/),d=null!==location.hash.match(/^#section-/),e=null!==location.hash.match(/^#comment-/);if(c||d||e||(d=!0),c&&(b=location.hash.replace("#module-",""),BrainPress.FocusMode.load_focus_item("module",b)),d){if(void 0===(b=location.hash)||0===b.length){var f=a(".brainpress-focus-view");b=a(f).attr("data-page")}b=b.replace("#section-",""),BrainPress.FocusMode.load_focus_item("section",b)}e&&(b=location.hash.replace("#comment-",""),BrainPress.FocusMode.load_focus_item("comment",b))},BrainPress.Page.init=function(){var b=a(".brainpress-focus-view").length>0;f(),h(),j(),i(),b||(a(".quiz_timer").brainpress_timer(),a(".quiz_timer").on("timer_started",function(){}),a(".quiz_timer").on("timer_ended",function(){}))},BrainPress.toggleModule=function(){var b=a(this),c=b.data("module"),d=a("#cp-element-"+c);return a("#cp-response-"+c).addClass("hide"),d.removeClass("hide"),!1},a(document).ready(function(){BrainPress.Page.init(),b(),k(),e(),a("#cp-unsubscribe-message").length>0&&(a('
').html(BrainPress.Enrollment.dialog.render().el).appendTo("body"),BrainPress.Enrollment.dialog.openAtAction("unsubscribe"))}).on("click",".cp .button-reload-module",BrainPress.toggleModule),a(document).on('keydown',function(b){if(!(b.ctrlKey||b.altKey||b.shiftKey||b.metaKey)){var c=a(":focus");if(00&&a(".focus-nav .focus-nav-prev a").trigger("click");break;case 39:a(".focus-nav .focus-nav-next a").length>0&&a(".focus-nav .focus-nav-next a").trigger("click")}}})}(jQuery),BrainPress.current=BrainPress.current||{}; \ No newline at end of file diff --git a/docs/README.md b/docs/README.md index 6a85048..2722ab7 100644 --- a/docs/README.md +++ b/docs/README.md @@ -30,11 +30,11 @@ BrainPress wird mit einem eigenen Theme geliefert – gestaltet und sofort einsa ![Bild](https://github.com/cp-psourcewp-content/uploads/2024/01/cp-features-735x470.jpg) - Durch die Integration von PSeCommerce und WooCommerce kannst Du Deine Kurse über jedes der über 100 Zahlungsgateways verkaufen. + Durch die Integration von MarketPress und WooCommerce kannst Du Deine Kurse über jedes der über 100 Zahlungsgateways verkaufen. -### PSeCommerce & WooCommerce +### MarketPress & WooCommerce -Erstelle und verwalte die nächste große Academy, Tuts+ oder Lynda mit integriertem PSeCommerce und WooCommerce. Beginne mit der Annahme von Zahlungen mit einer der über 100 verfügbaren Zahlungsoptionen. +Erstelle und verwalte die nächste große Academy, Tuts+ oder Lynda mit integriertem MarketPress und WooCommerce. Beginne mit der Annahme von Zahlungen mit einer der über 100 verfügbaren Zahlungsoptionen. @@ -173,17 +173,17 @@ Beginnen wir mit dem Hinzufügen eines Kurses. Gehe zu _BrainPress > Neuer Kurs_ ![BrainPress - New Course - Enrollment](https://premium.wpmudev.org/wp-content/uploads/2014/09/BrainPress-New-Course-Enrollment.png) - Tick the '_This is a Paid Course_' option to display payment options. For payments, BrainPress Pro integrates with both [PSeCommerce](https://premium.wpmudev.org/project/e-commerce/ "PSeCommerce ClassicPress e-Commerce") and [WooCommerce](https://wordpress.org/plugins/woocommerce/). Please note that currently, only one of them (either PSeCommerce or WooCommerce) should be activated, activating both at the same time may cause conflicts. For PSeCommerce integration, the first time the above payment option is selected, you'll be presented with a message about PSeCommerce, like so: + Tick the '_This is a Paid Course_' option to display payment options. For payments, BrainPress Pro integrates with both [MarketPress](https://premium.wpmudev.org/project/e-commerce/ "MarketPress ClassicPress e-Commerce") and [WooCommerce](https://wordpress.org/plugins/woocommerce/). Please note that currently, only one of them (either MarketPress or WooCommerce) should be activated, activating both at the same time may cause conflicts. For MarketPress integration, the first time the above payment option is selected, you'll be presented with a message about MarketPress, like so: -![BrainPress Pro - Activate PSeCommerce](https://premium.wpmudev.org/wp-content/uploads/2014/09/BrainPress-Pro-1.2.5.4-Payment-settings-Activate-PSeCommerce.png) +![BrainPress Pro - Activate MarketPress](https://premium.wpmudev.org/wp-content/uploads/2014/09/BrainPress-Pro-1.2.5.4-Payment-settings-Activate-MarketPress.png) - Click the _Begin Activating PSeCommerce_ link to begin the PSeCommerce activation process and expose the payment options. Or for WooCommerce integration, simply ensure that WooCommerce is installed and activated, then tick the '_Use WooCommerce to sell courses_' setting at _BrainPress Pro > Settings_. You can optionally select to redirect WooCommerce product posts to a parent course as well. + Click the _Begin Activating MarketPress_ link to begin the MarketPress activation process and expose the payment options. Or for WooCommerce integration, simply ensure that WooCommerce is installed and activated, then tick the '_Use WooCommerce to sell courses_' setting at _BrainPress Pro > Settings_. You can optionally select to redirect WooCommerce product posts to a parent course as well. ![BrainPress Pro - Settings - WooCommerce Integration](https://premium.wpmudev.org/wp-content/uploads/2014/09/BrainPress-Pro-1.2.5.4-WooCommerce-Settings.png) WooCommerce settings at BrainPress Pro > Settings -   With either PSeCommerce or WooCommerce installed and activated, and with the settings configured as above, you'll then see payment options for your Course. +   With either MarketPress or WooCommerce installed and activated, and with the settings configured as above, you'll then see payment options for your Course. ![BrainPress - New Course - Enrollment - This is a paid course](https://premium.wpmudev.org/wp-content/uploads/2014/09/BrainPress-New-Course-Enrollment-This-is-a-paid-course.png) @@ -191,7 +191,7 @@ Beginnen wir mit dem Hinzufügen eines Kurses. Gehe zu _BrainPress > Neuer Kurs_ * Enter the _Price_. * Tick the '_Enabled Sale Price_' option to specify that this course on sale. * Enter a _Sale Price_ to be used with the above option. -* If you're using PSeCommerce, you'll have an option to _Edit Payment Gateways_ where you'll be presented with a pop-up dialog and will be able to select and configure the payment gateways. +* If you're using MarketPress, you'll have an option to _Edit Payment Gateways_ where you'll be presented with a pop-up dialog and will be able to select and configure the payment gateways. ![BrainPress Pro - Payment Gateways](https://premium.wpmudev.org/wp-content/uploads/2014/09/BrainPress-Pro-1.2.1.9-Payment-Gateways.png) diff --git a/include/brainpress/class-hooks.php b/include/brainpress/class-hooks.php index 4dca6e6..86d2013 100644 --- a/include/brainpress/class-hooks.php +++ b/include/brainpress/class-hooks.php @@ -69,7 +69,7 @@ public static function init() { add_action( 'wp_ajax_update_discussion', array( 'BrainPress_Data_Discussion', 'ajax_update' ) ); // MP Notice - add_action( 'admin_notices', array( 'BrainPress_Helper_Extension_PSeCommerce', 'mp_notice' ) ); + add_action( 'admin_notices', array( 'BrainPress_Helper_Extension_MarketPress', 'mp_notice' ) ); // Admin class add_filter( 'admin_body_class', array( __CLASS__, 'admin_classes' ) ); diff --git a/include/brainpress/class-upgrade.php b/include/brainpress/class-upgrade.php index 078676c..3a6bbd5 100644 --- a/include/brainpress/class-upgrade.php +++ b/include/brainpress/class-upgrade.php @@ -186,10 +186,10 @@ private static function _2p0() { $settings = BrainPress_Helper_Utility::set_array_value( $settings, 'email/new_order/content', $value ); // MP - $value = is_plugin_active( 'psecommerce/psecommerce.php' ); - $settings = BrainPress_Helper_Utility::set_array_value( $settings, 'psecommerce/enabled', $value ); + $value = is_plugin_active( 'marketpress/marketpress.php' ); + $settings = BrainPress_Helper_Utility::set_array_value( $settings, 'marketpress/enabled', $value ); $value = get_option( 'redirect_mp_to_course', false ); - $settings = BrainPress_Helper_Utility::set_array_value( $settings, 'psecommerce/redirect', $value ); + $settings = BrainPress_Helper_Utility::set_array_value( $settings, 'marketpress/redirect', $value ); // WooCommerce Integration $settings = BrainPress_Helper_Utility::set_array_value( $settings, 'woocommerce/enabled', get_option( 'use_woo', 0 ) ); diff --git a/include/brainpress/data/class-course.php b/include/brainpress/data/class-course.php index 239a707..04d9a11 100644 --- a/include/brainpress/data/class-course.php +++ b/include/brainpress/data/class-course.php @@ -1211,11 +1211,11 @@ public static function is_paid_course( $course_id ) { $is_paid = cp_is_true( $is_paid ); } /** - * Check for supported integration: PSeCommerce + * Check for supported integration: MarketPress */ - if ( $is_paid && class_exists( 'BrainPress_Helper_Integration_PSeCommerce' ) ) { + if ( $is_paid && class_exists( 'BrainPress_Helper_Integration_MarketPress' ) ) { if ( defined( 'MP_VERSION' ) && MP_VERSION ) { - $is_paid = BrainPress_Helper_Integration_PSeCommerce::$is_active; + $is_paid = BrainPress_Helper_Integration_MarketPress::$is_active; $is_paid = cp_is_true( $is_paid ); return $is_paid; } diff --git a/include/brainpress/helper/class-extension.php b/include/brainpress/helper/class-extension.php index 3b24124..3f61eb6 100644 --- a/include/brainpress/helper/class-extension.php +++ b/include/brainpress/helper/class-extension.php @@ -5,7 +5,7 @@ class BrainPress_Helper_Extension { private static $plugins = array(); public static function init() { - $plugins = array( 'PSeCommerce', 'CP_TCPDF' ); + $plugins = array( 'MarketPress', 'CP_TCPDF' ); foreach ( $plugins as $plugin ) { if ( method_exists( 'BrainPress_Helper_Extension_' . $plugin, 'init' ) ) { call_user_func( 'BrainPress_Helper_Extension_' . $plugin . '::init' ); diff --git a/include/brainpress/helper/class-integration.php b/include/brainpress/helper/class-integration.php index 3a1e293..7fe74d4 100644 --- a/include/brainpress/helper/class-integration.php +++ b/include/brainpress/helper/class-integration.php @@ -45,8 +45,8 @@ public static function init() { public static function get_plugins() { if ( null === self::$plugins ) { self::$plugins = array(); - self::$plugins['psecommerce'] = array( - 'class' => 'BrainPress_Helper_Integration_PSeCommerce', + self::$plugins['marketpress'] = array( + 'class' => 'BrainPress_Helper_Integration_MarketPress', 'method' => 'init', ); diff --git a/include/brainpress/helper/extension/class-psecommerce.php b/include/brainpress/helper/extension/class-marketpress.php similarity index 84% rename from include/brainpress/helper/extension/class-psecommerce.php rename to include/brainpress/helper/extension/class-marketpress.php index a34d00a..3589954 100644 --- a/include/brainpress/helper/extension/class-psecommerce.php +++ b/include/brainpress/helper/extension/class-marketpress.php @@ -1,14 +1,14 @@ 'psecommerce/psecommerce.php', - 'free' => 'psecommerce/psecommerce.php', + 'pro' => 'marketpress/marketpress.php', + 'free' => 'marketpress/marketpress.php', ); public static function init() { @@ -21,8 +21,8 @@ public static function init() { } public static function add_to_extensions_list( $plugins ) { - $download_source = 'n3rds.work\/wp-update-server\/?action=download&slug=psecommerce'; - $external_url = 'https://github.com/cp-psourcepiestingtal_source/psecommerce-shopsystem/'; + $download_source = 'n3rds.work\/wp-update-server\/?action=download&slug=marketpress'; + $external_url = 'https://github.com/cp-psourcepiestingtal_source/marketpress-shopsystem/'; $source_message = __( 'PSource Server', 'brainpress' ); $is_link = false; $base_path = self::$base_path['free']; @@ -34,7 +34,7 @@ public static function add_to_extensions_list( $plugins ) { $source_message = 'PSource Server'; $external_url = ''; $is_link = true; - $download_source = 'n3rds.work\/wp-update-server\/?action=download&slug=psecommerce'; + $download_source = 'n3rds.work\/wp-update-server\/?action=download&slug=marketpress'; $base_path = self::$base_path['pro']; if ( is_plugin_active( 'psource-updates/update-notifications.php' ) ) { @@ -45,8 +45,8 @@ public static function add_to_extensions_list( $plugins ) { } $plugins[] = array( - 'name' => 'PSeCommerce', - 'slug' => 'psecommerce', + 'name' => 'MarketPress', + 'slug' => 'marketpress', 'base_path' => $base_path, 'source' => $download_source, 'source_message' => $source_message, @@ -105,7 +105,7 @@ public static function mp_notice() { * check user meta */ $user_id = get_current_user_id(); - $show = get_user_option( 'psecommerce-run-notice' ); + $show = get_user_option( 'marketpress-run-notice' ); if ( 'hide' == $show ) { return; } @@ -127,16 +127,16 @@ public static function mp_notice() { ), admin_url( 'edit.php' ) ); - $message = sprintf( '%s ', __( 'Installiere das PSeCommerce-Plugin, um Kurse zu verkaufen.', 'brainpress' ) ); - $message .= sprintf( '%s', $mp_settings_url, __( 'Installiere PSeCommerce', 'brainpress' ) ); + $message = sprintf( '%s ', __( 'Installiere das MarketPress-Plugin, um Kurse zu verkaufen.', 'brainpress' ) ); + $message .= sprintf( '%s', $mp_settings_url, __( 'Installiere MarketPress', 'brainpress' ) ); } elseif ( ! self::activated() ) { - $mp_link = sprintf( '%s', admin_url( 'plugins.php' ), __( 'PSeCommerce', 'brainpress' ) ); + $mp_link = sprintf( '%s', admin_url( 'plugins.php' ), __( 'MarketPress', 'brainpress' ) ); $message = sprintf( __( 'Aktiviere %s um mit den Verkauf von Kursen zu beginnen.', 'brainpress' ), $mp_link ); } elseif ( self::activated() ) { if ( defined( 'MP_VERSION' ) ) { if ( version_compare( MP_VERSION, '1.5.2' ) < 0 ) { $plugin_url = admin_url( 'plugins.php' ); - $mp = sprintf( '%s', $plugin_url, 'PSeCommerce' ); + $mp = sprintf( '%s', $plugin_url, 'MarketPress' ); $cp = defined( 'CP_IS_PREMIUM' ) && CP_IS_PREMIUM ? 'BrainPress' : 'BrainPress'; $cp = sprintf( '%s', $plugin_url, $cp ); $message = __( 'Wenn Du eine ältere Version des %s-Plugins verwendest, benötigst Du aus Kompatibilitätsgründen die neueste Version.', 'brainpress' ); @@ -149,11 +149,11 @@ public static function mp_notice() { if ( ! empty( $message ) ) { $data = array( 'dismissible' => true, - 'option-name' => 'psecommerce-run-notice', - 'nonce' => wp_create_nonce( 'psecommerce-run-notice'.$user_id ), + 'option-name' => 'marketpress-run-notice', + 'nonce' => wp_create_nonce( 'marketpress-run-notice'.$user_id ), 'user_id' => $user_id, ); - echo BrainPress_Helper_UI::admin_notice( $message, 'warning', 'psecommerce-run-notice', $data ); + echo BrainPress_Helper_UI::admin_notice( $message, 'warning', 'marketpress-run-notice', $data ); } } } diff --git a/include/brainpress/helper/integration/class-psecommerce.php b/include/brainpress/helper/integration/class-marketpress.php similarity index 92% rename from include/brainpress/helper/integration/class-psecommerce.php rename to include/brainpress/helper/integration/class-marketpress.php index 9a2e12e..7a4d28f 100644 --- a/include/brainpress/helper/integration/class-psecommerce.php +++ b/include/brainpress/helper/integration/class-marketpress.php @@ -7,9 +7,9 @@ */ /** - * Integrates PSeCommerce with BrainPress. + * Integrates MarketPress with BrainPress. */ -class BrainPress_Helper_Integration_PSeCommerce { +class BrainPress_Helper_Integration_MarketPress { private static $updated = false; public static $is_active = false; @@ -32,15 +32,15 @@ public static function init() { array( __CLASS__, 'add_settings_to_js_brainpress' ) ); - // If PSeCommerce is not activated just exit. - if ( ! BrainPress_Helper_Extension_PSeCommerce::activated() ) { + // If MarketPress is not activated just exit. + if ( ! BrainPress_Helper_Extension_MarketPress::activated() ) { return false; } - if ( ! BrainPress_Core::get_setting( 'psecommerce/enabled' ) ) { + if ( ! BrainPress_Core::get_setting( 'marketpress/enabled' ) ) { return false; } self::$is_active = true; - add_filter( 'brainpress_is_psecommerce_active', '__return_true' ); + add_filter( 'brainpress_is_marketpress_active', '__return_true' ); // Enable Payment Support add_filter( @@ -75,7 +75,7 @@ public static function init() { 10, 2 ); - // If for whatever reason the course gets updated in PSeCommerce, + // If for whatever reason the course gets updated in MarketPress, // reflect those changes in the course. add_action( 'post_updated', @@ -127,7 +127,7 @@ public static function init() { /** * Enroll upon pay * - * Reference to order ID, will need to get the actual product using the PSeCommerce Order class + * Reference to order ID, will need to get the actual product using the MarketPress Order class */ add_action( 'mp_order_order_paid', @@ -367,9 +367,9 @@ public static function product_settings( $content, $course_id ) { $mp_content = '
-

' . esc_html__( 'Dein Kurs wird ein neues Produkt in PSeCommerce sein. Gib unten die Zahlungseinstellungen Deines Kurses ein.', 'brainpress' ) . '

+

' . esc_html__( 'Dein Kurs wird ein neues Produkt in MarketPress sein. Gib unten die Zahlungseinstellungen Deines Kurses ein.', 'brainpress' ) . '

-

+

diff --git a/include/brainpress/view/front/class-student.php b/include/brainpress/view/front/class-student.php index 7c51bc0..54cb742 100644 --- a/include/brainpress/view/front/class-student.php +++ b/include/brainpress/view/front/class-student.php @@ -34,9 +34,9 @@ public static function render_enrollment_process_page() { /** This filter is documented in * include/brainpress/helper/integration/class-woocommerce.php */ $is_user_purchased_course = apply_filters( 'brainpress_is_user_purchased_course', false, $course, $student_id ); - if ( $is_paid && isset( $course->details->psecommerce_product ) && '' != $course->details->psecommerce_product && $brainpress->psecommerce_active ) { + if ( $is_paid && isset( $course->details->marketpress_product ) && '' != $course->details->marketpress_product && $brainpress->marketpress_active ) { $course_price = 1; //forces user to purchase course / show purchase form - $course->is_user_purchased_course( $course->details->psecommerce_product, $student_id ); + $course->is_user_purchased_course( $course->details->marketpress_product, $student_id ); } if ( 'passcode' == $course->details->enroll_type ) { @@ -56,7 +56,7 @@ public static function render_enrollment_process_page() { _e( 'Während des Einschreibungsprozesses ist ein Fehler aufgetreten. Bitte versuche es später noch einmal.', 'brainpress' ); } } else { - if ( $course->is_user_purchased_course( $course->details->psecommerce_product, $student_id ) ) { + if ( $course->is_user_purchased_course( $course->details->marketpress_product, $student_id ) ) { //Enroll student in if ( BrainPress_Data_Course::enroll_student( $student_id, $course_id ) ) { printf( __( 'Herzlichen Glückwunsch, Du hast dich erfolgreich für den Kurs "%s" eingeschrieben! Überprüfe Dein %s für weitere Informationen.', 'brainpress' ), '' . $course->details->post_title . '', '' . __( 'Dashboard', 'brainpress' ) . '' ); @@ -64,7 +64,7 @@ public static function render_enrollment_process_page() { _e( 'Während des Einschreibungsprozesses ist ein Fehler aufgetreten. Bitte versuche es später noch einmal.', 'brainpress' ); } } else { - $course->show_purchase_form( $course->details->psecommerce_product ); + $course->show_purchase_form( $course->details->marketpress_product ); } } } else { diff --git a/languages/brainpress-en_US.po b/languages/brainpress-en_US.po index b4490ad..9eef905 100644 --- a/languages/brainpress-en_US.po +++ b/languages/brainpress-en_US.po @@ -141,7 +141,7 @@ msgstr "Show all available courses." msgid " [ENTWURF]" msgstr "[DRAFT]" -#: include/brainpress/helper/extension/class-psecommerce.php:143 +#: include/brainpress/helper/extension/class-marketpress.php:143 #, php-format msgid " Aktualisiere jetzt Dein %s!" msgstr "Update your %s now!" @@ -241,7 +241,7 @@ msgstr[1] "" #: include/brainpress/view/admin/setting/class-setup.php:70 #, php-format msgid "" -"%s hat auch PSeCommerce mit dabei - Falls Du Kurse verkaufen möchtest, dann " +"%s hat auch MarketPress mit dabei - Falls Du Kurse verkaufen möchtest, dann " "installiere es einfach über das BrainPress Dashboard." msgstr "" @@ -466,25 +466,25 @@ msgstr "" #: include/brainpress/view/admin/course/class-edit.php:959 msgid "" -"

Please contact your administrator to enable PSeCommerce for your site.

" +"

Please contact your administrator to enable MarketPress for your site.

" msgstr "" #: include/brainpress/view/admin/course/class-edit.php:963 msgid "" -"

The full version of PSeCommerce has been bundled with BrainPress.

" +"

The full version of MarketPress has been bundled with BrainPress.

" msgstr "" #: include/brainpress/view/admin/course/class-edit.php:956 #, php-format msgid "" -"

To start selling your course, please install and activate PSeCommerce " +"

To start selling your course, please install and activate MarketPress " "here:

\n" -"\t\t\t\t\t\t\t\tActivate PSeCommerce" +"\t\t\t\t\t\t\t\tActivate MarketPress" msgstr "" #: include/brainpress/view/admin/course/class-edit.php:965 msgid "" -"

You can use the free or premium version of PSeCommerce to sell your " +"

You can use the free or premium version of MarketPress to sell your " "courses.

" msgstr "" @@ -634,12 +634,12 @@ msgstr "" msgid "Aktionen" msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:134 +#: include/brainpress/helper/extension/class-marketpress.php:134 #, php-format msgid "Aktiviere %s um mit den Verkauf von Kursen zu beginnen." msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:387 +#: include/brainpress/helper/integration/class-marketpress.php:387 #: include/brainpress/helper/integration/class-woocommerce.php:203 msgid "Aktiviere Angebotspreis" msgstr "" @@ -851,7 +851,7 @@ msgstr "" msgid "Anfangsdatum" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:381 +#: include/brainpress/helper/integration/class-marketpress.php:381 #: include/brainpress/helper/integration/class-woocommerce.php:197 msgid "Angebotspreis" msgstr "" @@ -1189,7 +1189,7 @@ msgstr "" msgid "Auswählbare Auswahl" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:396 +#: include/brainpress/helper/integration/class-marketpress.php:396 msgid "Automatisch generierte Lagerbestandseinheiten (SKUs)" msgstr "" @@ -1625,7 +1625,7 @@ msgstr "" msgid "bestehen" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:875 +#: include/brainpress/helper/integration/class-marketpress.php:875 #: include/brainpress/helper/setting/class-email.php:71 msgid "Bestellbestätigung" msgstr "" @@ -1941,7 +1941,7 @@ msgstr "" #: admin/class-edit.php:623 msgid "" -"Bitte wende Dich an Deinen Administrator, um PSeCommerce für Deine Seite zu " +"Bitte wende Dich an Deinen Administrator, um MarketPress für Deine Seite zu " "aktivieren." msgstr "" @@ -2343,7 +2343,7 @@ msgid "Das Upgrade ist abgeschlossen." msgstr "" #: include/brainpress/helper/class-utility.php:1406 -#: include/brainpress/helper/integration/class-psecommerce.php:1105 +#: include/brainpress/helper/integration/class-marketpress.php:1105 #: include/brainpress/helper/setting/class-email.php:384 #: include/brainpress/helper/setting/class-email.php:545 #: include/brainpress/view/front/class-general.php:59 @@ -2438,9 +2438,9 @@ msgid "" "Dein Feedback wird nach der Einreichung per E-Mail an den Studenten gesendet." msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:372 +#: include/brainpress/helper/integration/class-marketpress.php:372 msgid "" -"Dein Kurs wird ein neues Produkt in PSeCommerce sein. Gib unten die " +"Dein Kurs wird ein neues Produkt in MarketPress sein. Gib unten die " "Zahlungseinstellungen Deines Kurses ein." msgstr "" @@ -2852,7 +2852,7 @@ msgid "Die Videoeinstellungen des Kurses wurden aktualisiert." msgstr "" #: admin/class-edit.php:636 -msgid "Die Vollversion von PSeCommerce wurde mit BrainPress gebündelt." +msgid "Die Vollversion von MarketPress wurde mit BrainPress gebündelt." msgstr "" #: admin/view/steps/step-2.php:60 @@ -3374,7 +3374,7 @@ msgstr "" msgid "Du kannst diese Mindestpunktzahl in den Kurseinstellungen ändern." msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:1052 +#: include/brainpress/helper/integration/class-marketpress.php:1052 #: include/brainpress/helper/integration/class-woocommerce.php:711 msgid "Du kannst diesen Kurs jetzt in den Warenkorb legen." msgstr "" @@ -4277,8 +4277,8 @@ msgstr "" msgid "Erledigt" msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:44 -msgid "Ermögliche die Integration von PSeCommerce, um Kurse zu verkaufen ..." +#: include/brainpress/view/admin/setting/class-marketpress.php:44 +msgid "Ermögliche die Integration von MarketPress, um Kurse zu verkaufen ..." msgstr "" #: include/brainpress/view/admin/setting/class-woocommerce.php:41 @@ -5405,12 +5405,12 @@ msgstr "" msgid "insgesamt erworbene bewertbare Note % Gesamtzahl der bewertbaren Module" msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:130 -msgid "Installiere das PSeCommerce-Plugin, um Kurse zu verkaufen." +#: include/brainpress/helper/extension/class-marketpress.php:130 +msgid "Installiere das MarketPress-Plugin, um Kurse zu verkaufen." msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:131 -msgid "Installiere PSeCommerce" +#: include/brainpress/helper/extension/class-marketpress.php:131 +msgid "Installiere MarketPress" msgstr "" #: include/brainpress/helper/class-extension.php:97 @@ -5864,7 +5864,7 @@ msgstr "" msgid "Kurs Setup" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:391 +#: include/brainpress/helper/integration/class-marketpress.php:391 #: include/brainpress/helper/integration/class-woocommerce.php:207 msgid "Kurs SKU:" msgstr "" @@ -5892,7 +5892,7 @@ msgstr "" msgid "Kurs wählen" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:1048 +#: include/brainpress/helper/integration/class-marketpress.php:1048 #: include/brainpress/helper/integration/class-woocommerce.php:706 msgid "Kurs zum Warenkorb hinzufügen." msgstr "" @@ -6450,9 +6450,9 @@ msgstr "" msgid "Leider hast Du COURSE_NAME nicht bestanden." msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:85 +#: include/brainpress/view/admin/setting/class-marketpress.php:85 msgid "" -"Leite den PSeCommerce-Produktbeitrag zu einem übergeordneten Kursbeitrag um" +"Leite den MarketPress-Produktbeitrag zu einem übergeordneten Kursbeitrag um" msgstr "" #: include/brainpress/view/admin/setting/class-woocommerce.php:82 @@ -6599,9 +6599,9 @@ msgstr "" msgid "Lösche “%s” unwiederruflich" msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:103 -#: include/brainpress/view/admin/setting/class-psecommerce.php:120 -msgid "Lösche das zugehörige PSeCommerce-Produkt." +#: include/brainpress/view/admin/setting/class-marketpress.php:103 +#: include/brainpress/view/admin/setting/class-marketpress.php:120 +msgid "Lösche das zugehörige MarketPress-Produkt." msgstr "" #: include/brainpress/view/admin/setting/class-woocommerce.php:100 @@ -7655,21 +7655,21 @@ msgstr "" msgid "Prozent der Einheit fertiggestellt" msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:133 -#: include/brainpress/view/admin/setting/class-psecommerce.php:43 -msgid "PSeCommerce" +#: include/brainpress/helper/extension/class-marketpress.php:133 +#: include/brainpress/view/admin/setting/class-marketpress.php:43 +msgid "MarketPress" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:370 -msgid "PSeCommerce Produkt Einstellungen" +#: include/brainpress/helper/integration/class-marketpress.php:370 +msgid "MarketPress Produkt Einstellungen" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:404 +#: include/brainpress/helper/integration/class-marketpress.php:404 #, php-format -msgid "PSeCommerce Produkt ID: %d" +msgid "MarketPress Produkt ID: %d" msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:26 +#: include/brainpress/helper/extension/class-marketpress.php:26 msgid "PSource Server" msgstr "" @@ -7956,7 +7956,7 @@ msgid "Seite zum Abschluss des Kurses" msgstr "" #: include/brainpress/view/admin/setting/class-capabilities.php:270 -msgid "Seiten bearbeiten (erforderlich für PSeCommerce)" +msgid "Seiten bearbeiten (erforderlich für MarketPress)" msgstr "" #: include/brainpress/view/admin/setting/class-capabilities.php:273 @@ -8033,7 +8033,7 @@ msgid "Select the limitations on accessing and enrolling in this course." msgstr "" #: include/brainpress/view/admin/course/class-edit.php:975 -msgid "Sell your courses online with PSeCommerce." +msgid "Sell your courses online with MarketPress." msgstr "" #: include/brainpress/view/admin/assessment/class-list.php:794 @@ -9038,14 +9038,14 @@ msgstr "" #, php-format msgid "" "Um mit dem Verkauf Deines Kurses zu beginnen, bitte " -"Installiere und aktiviere PSeCommerce." +"Installiere und aktiviere MarketPress." msgstr "" #: admin/class-edit.php:631 #, php-format msgid "" "Um mit dem Verkauf Deines Kurses zu beginnen, bitte Setup " -"komplettieren für PSeCommerce." +"komplettieren für MarketPress." msgstr "" #: include/brainpress/view/front/class-instructor.php:97 @@ -9354,7 +9354,7 @@ msgid "Vergangene Kurse" msgstr "" #: admin/class-edit.php:647 -msgid "Verkaufe Deine Kurse online mit PSeCommerce." +msgid "Verkaufe Deine Kurse online mit MarketPress." msgstr "" #: include/brainpress/helper/ui/class-module.php:581 @@ -9464,8 +9464,8 @@ msgstr "" msgid "Verwende für diesen Kurs ein benutzerdefiniertes Zertifikat." msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:73 -msgid "Verwende PSeCommerce, um Kurse zu verkaufen" +#: include/brainpress/view/admin/setting/class-marketpress.php:73 +msgid "Verwende MarketPress, um Kurse zu verkaufen" msgstr "" #: include/brainpress/view/admin/setting/class-woocommerce.php:70 @@ -9548,7 +9548,7 @@ msgid "" "Das %5$s Team" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:1096 +#: include/brainpress/helper/integration/class-marketpress.php:1096 #, php-format msgid "" "Vielen Dank für Deine Bestellung %1$s,\n" @@ -9588,7 +9588,7 @@ msgstr "" msgid "Visuell" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:375 +#: include/brainpress/helper/integration/class-marketpress.php:375 #: include/brainpress/helper/integration/class-woocommerce.php:191 msgid "Voller Preis" msgstr "" @@ -9696,9 +9696,9 @@ msgstr "" msgid "Warten auf Überprüfung" msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:98 -#: include/brainpress/view/admin/setting/class-psecommerce.php:115 -msgid "Wechsle auf Entwurf des zugehörigen PSeCommerce-Produkts." +#: include/brainpress/view/admin/setting/class-marketpress.php:98 +#: include/brainpress/view/admin/setting/class-marketpress.php:115 +msgid "Wechsle auf Entwurf des zugehörigen MarketPress-Produkts." msgstr "" #: include/brainpress/view/admin/setting/class-woocommerce.php:95 @@ -9809,12 +9809,12 @@ msgstr "" msgid "Wenn außerhalb der ClassicPress-Schleife." msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:109 +#: include/brainpress/view/admin/setting/class-marketpress.php:109 #: include/brainpress/view/admin/setting/class-woocommerce.php:106 msgid "Wenn der Kurs gelöscht ist, dann:" msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:92 +#: include/brainpress/view/admin/setting/class-marketpress.php:92 #: include/brainpress/view/admin/setting/class-woocommerce.php:89 msgid "Wenn der Kurs unbezahlt ist, dann:" msgstr "" @@ -9873,10 +9873,10 @@ msgid "" "Bewertungen sehen." msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:87 +#: include/brainpress/view/admin/setting/class-marketpress.php:87 msgid "" "Wenn diese Option aktiviert ist, werden Besucher, die versuchen, auf einen " -"einzelnen Beitrag von PSeCommerce zuzugreifen, automatisch auf einen " +"einzelnen Beitrag von MarketPress zuzugreifen, automatisch auf einen " "einzelnen Beitrag eines übergeordneten Kurses umgeleitet." msgstr "" @@ -9893,19 +9893,19 @@ msgid "" "der URL angezeigt. Andernfalls wird die Hash-Version (MD5) angezeigt." msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:75 +#: include/brainpress/view/admin/setting/class-marketpress.php:75 msgid "" -"Wenn diese Option aktiviert ist, wird PSeCommerce für den Verkauf von Kursen " +"Wenn diese Option aktiviert ist, wird MarketPress für den Verkauf von Kursen " "verwendet" msgstr "" #: include/brainpress/view/admin/setting/class-woocommerce.php:72 msgid "" -"Wenn diese Option aktiviert ist, wird WooCommerce anstelle von PSeCommerce " +"Wenn diese Option aktiviert ist, wird WooCommerce anstelle von MarketPress " "für den Verkauf von Kursen verwendet" msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:142 +#: include/brainpress/helper/extension/class-marketpress.php:142 #, php-format msgid "" "Wenn Du eine ältere Version des %s-Plugins verwendest, benötigst Du aus " @@ -10180,7 +10180,7 @@ msgstr "" msgid "You do not have sufficient permission to add instructor!" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:393 +#: include/brainpress/helper/integration/class-marketpress.php:393 #: include/brainpress/helper/integration/class-woocommerce.php:209 #, php-format msgid "z.B. %s0001" @@ -10238,7 +10238,7 @@ msgstr "" msgid "Zeige Gratiskurse." msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:1057 +#: include/brainpress/helper/integration/class-marketpress.php:1057 #, php-format msgid "Zeige Kurs: %s" msgstr "" diff --git a/languages/brainpress.pot b/languages/brainpress.pot index 4613d6c..f6f392d 100644 --- a/languages/brainpress.pot +++ b/languages/brainpress.pot @@ -503,7 +503,7 @@ msgstr "" #: admin/class-edit.php:623 msgid "" -"Bitte wende Dich an Deinen Administrator, um PSeCommerce für Deine Seite zu " +"Bitte wende Dich an Deinen Administrator, um MarketPress für Deine Seite zu " "aktivieren." msgstr "" @@ -511,22 +511,22 @@ msgstr "" #, php-format msgid "" "Um mit dem Verkauf Deines Kurses zu beginnen, bitte Installiere und aktiviere PSeCommerce." +"href=\"%s\">Installiere und aktiviere MarketPress." msgstr "" #: admin/class-edit.php:631 #, php-format msgid "" "Um mit dem Verkauf Deines Kurses zu beginnen, bitte Setup " -"komplettieren für PSeCommerce." +"komplettieren für MarketPress." msgstr "" #: admin/class-edit.php:636 -msgid "Die Vollversion von PSeCommerce wurde mit BrainPress gebündelt." +msgid "Die Vollversion von MarketPress wurde mit BrainPress gebündelt." msgstr "" #: admin/class-edit.php:647 -msgid "Verkaufe Deine Kurse online mit PSeCommerce." +msgid "Verkaufe Deine Kurse online mit MarketPress." msgstr "" #: admin/class-edit.php:650 @@ -4786,7 +4786,7 @@ msgid "Anmelden/Abmelden" msgstr "" #: include/brainpress/helper/class-utility.php:1406 -#: include/brainpress/helper/integration/class-psecommerce.php:1105 +#: include/brainpress/helper/integration/class-marketpress.php:1105 #: include/brainpress/helper/setting/class-email.php:384 #: include/brainpress/helper/setting/class-email.php:545 #: include/brainpress/view/front/class-general.php:59 @@ -4811,36 +4811,36 @@ msgstr "" msgid "Zum Menü hinzufügen" msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:26 +#: include/brainpress/helper/extension/class-marketpress.php:26 msgid "PSource Server" msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:130 -msgid "Installiere das PSeCommerce-Plugin, um Kurse zu verkaufen." +#: include/brainpress/helper/extension/class-marketpress.php:130 +msgid "Installiere das MarketPress-Plugin, um Kurse zu verkaufen." msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:131 -msgid "Installiere PSeCommerce" +#: include/brainpress/helper/extension/class-marketpress.php:131 +msgid "Installiere MarketPress" msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:133 -#: include/brainpress/view/admin/setting/class-psecommerce.php:43 -msgid "PSeCommerce" +#: include/brainpress/helper/extension/class-marketpress.php:133 +#: include/brainpress/view/admin/setting/class-marketpress.php:43 +msgid "MarketPress" msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:134 +#: include/brainpress/helper/extension/class-marketpress.php:134 #, php-format msgid "Aktiviere %s um mit den Verkauf von Kursen zu beginnen." msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:142 +#: include/brainpress/helper/extension/class-marketpress.php:142 #, php-format msgid "" "Wenn Du eine ältere Version des %s-Plugins verwendest, benötigst Du aus " "Kompatibilitätsgründen die neueste Version." msgstr "" -#: include/brainpress/helper/extension/class-psecommerce.php:143 +#: include/brainpress/helper/extension/class-marketpress.php:143 #, php-format msgid " Aktualisiere jetzt Dein %s!" msgstr "" @@ -4850,72 +4850,72 @@ msgid "" "Komplette TCPDF-Bibliothek mit zusätzlichen Schriftarten (ClassicPress.org)" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:370 -msgid "PSeCommerce Produkt Einstellungen" +#: include/brainpress/helper/integration/class-marketpress.php:370 +msgid "MarketPress Produkt Einstellungen" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:372 +#: include/brainpress/helper/integration/class-marketpress.php:372 msgid "" -"Dein Kurs wird ein neues Produkt in PSeCommerce sein. Gib unten die " +"Dein Kurs wird ein neues Produkt in MarketPress sein. Gib unten die " "Zahlungseinstellungen Deines Kurses ein." msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:375 +#: include/brainpress/helper/integration/class-marketpress.php:375 #: include/brainpress/helper/integration/class-woocommerce.php:191 msgid "Voller Preis" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:381 +#: include/brainpress/helper/integration/class-marketpress.php:381 #: include/brainpress/helper/integration/class-woocommerce.php:197 msgid "Angebotspreis" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:387 +#: include/brainpress/helper/integration/class-marketpress.php:387 #: include/brainpress/helper/integration/class-woocommerce.php:203 msgid "Aktiviere Angebotspreis" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:391 +#: include/brainpress/helper/integration/class-marketpress.php:391 #: include/brainpress/helper/integration/class-woocommerce.php:207 msgid "Kurs SKU:" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:393 +#: include/brainpress/helper/integration/class-marketpress.php:393 #: include/brainpress/helper/integration/class-woocommerce.php:209 #, php-format msgid "z.B. %s0001" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:396 +#: include/brainpress/helper/integration/class-marketpress.php:396 msgid "Automatisch generierte Lagerbestandseinheiten (SKUs)" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:404 +#: include/brainpress/helper/integration/class-marketpress.php:404 #, php-format -msgid "PSeCommerce Produkt ID: %d" +msgid "MarketPress Produkt ID: %d" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:875 +#: include/brainpress/helper/integration/class-marketpress.php:875 #: include/brainpress/helper/setting/class-email.php:71 msgid "Bestellbestätigung" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:1048 +#: include/brainpress/helper/integration/class-marketpress.php:1048 #: include/brainpress/helper/integration/class-woocommerce.php:706 msgid "Kurs zum Warenkorb hinzufügen." msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:1052 +#: include/brainpress/helper/integration/class-marketpress.php:1052 #: include/brainpress/helper/integration/class-woocommerce.php:711 msgid "Du kannst diesen Kurs jetzt in den Warenkorb legen." msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:1057 +#: include/brainpress/helper/integration/class-marketpress.php:1057 #, php-format msgid "Zeige Kurs: %s" msgstr "" -#: include/brainpress/helper/integration/class-psecommerce.php:1096 +#: include/brainpress/helper/integration/class-marketpress.php:1096 #, php-format msgid "" "Vielen Dank für Deine Bestellung %1$s,\n" @@ -6878,29 +6878,29 @@ msgstr "" #: include/brainpress/view/admin/course/class-edit.php:956 #, php-format msgid "" -"

To start selling your course, please install and activate PSeCommerce " +"

To start selling your course, please install and activate MarketPress " "here:

\n" -"\t\t\t\t\t\t\t\tActivate PSeCommerce" +"\t\t\t\t\t\t\t\tActivate MarketPress" msgstr "" #: include/brainpress/view/admin/course/class-edit.php:959 msgid "" -"

Please contact your administrator to enable PSeCommerce for your site.

" +"

Please contact your administrator to enable MarketPress for your site.

" msgstr "" #: include/brainpress/view/admin/course/class-edit.php:963 msgid "" -"

The full version of PSeCommerce has been bundled with BrainPress.

" +"

The full version of MarketPress has been bundled with BrainPress.

" msgstr "" #: include/brainpress/view/admin/course/class-edit.php:965 msgid "" -"

You can use the free or premium version of PSeCommerce to sell your " +"

You can use the free or premium version of MarketPress to sell your " "courses.

" msgstr "" #: include/brainpress/view/admin/course/class-edit.php:975 -msgid "Sell your courses online with PSeCommerce." +msgid "Sell your courses online with MarketPress." msgstr "" #: include/brainpress/view/admin/course/class-edit.php:976 @@ -7639,7 +7639,7 @@ msgid "Ändert den Status jeder Diskussion" msgstr "" #: include/brainpress/view/admin/setting/class-capabilities.php:270 -msgid "Seiten bearbeiten (erforderlich für PSeCommerce)" +msgid "Seiten bearbeiten (erforderlich für MarketPress)" msgstr "" #: include/brainpress/view/admin/setting/class-capabilities.php:271 @@ -8126,48 +8126,48 @@ msgstr "" msgid "Wähle eine Seite aus, auf der der Registrierungsprozess angezeigt wird." msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:44 -msgid "Ermögliche die Integration von PSeCommerce, um Kurse zu verkaufen ..." +#: include/brainpress/view/admin/setting/class-marketpress.php:44 +msgid "Ermögliche die Integration von MarketPress, um Kurse zu verkaufen ..." msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:73 -msgid "Verwende PSeCommerce, um Kurse zu verkaufen" +#: include/brainpress/view/admin/setting/class-marketpress.php:73 +msgid "Verwende MarketPress, um Kurse zu verkaufen" msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:75 +#: include/brainpress/view/admin/setting/class-marketpress.php:75 msgid "" -"Wenn diese Option aktiviert ist, wird PSeCommerce für den Verkauf von Kursen " +"Wenn diese Option aktiviert ist, wird MarketPress für den Verkauf von Kursen " "verwendet" msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:85 +#: include/brainpress/view/admin/setting/class-marketpress.php:85 msgid "" -"Leite den PSeCommerce-Produktbeitrag zu einem übergeordneten Kursbeitrag um" +"Leite den MarketPress-Produktbeitrag zu einem übergeordneten Kursbeitrag um" msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:87 +#: include/brainpress/view/admin/setting/class-marketpress.php:87 msgid "" "Wenn diese Option aktiviert ist, werden Besucher, die versuchen, auf einen " -"einzelnen Beitrag von PSeCommerce zuzugreifen, automatisch auf einen " +"einzelnen Beitrag von MarketPress zuzugreifen, automatisch auf einen " "einzelnen Beitrag eines übergeordneten Kurses umgeleitet." msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:92 +#: include/brainpress/view/admin/setting/class-marketpress.php:92 #: include/brainpress/view/admin/setting/class-woocommerce.php:89 msgid "Wenn der Kurs unbezahlt ist, dann:" msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:98 -#: include/brainpress/view/admin/setting/class-psecommerce.php:115 -msgid "Wechsle auf Entwurf des zugehörigen PSeCommerce-Produkts." +#: include/brainpress/view/admin/setting/class-marketpress.php:98 +#: include/brainpress/view/admin/setting/class-marketpress.php:115 +msgid "Wechsle auf Entwurf des zugehörigen MarketPress-Produkts." msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:103 -#: include/brainpress/view/admin/setting/class-psecommerce.php:120 -msgid "Lösche das zugehörige PSeCommerce-Produkt." +#: include/brainpress/view/admin/setting/class-marketpress.php:103 +#: include/brainpress/view/admin/setting/class-marketpress.php:120 +msgid "Lösche das zugehörige MarketPress-Produkt." msgstr "" -#: include/brainpress/view/admin/setting/class-psecommerce.php:109 +#: include/brainpress/view/admin/setting/class-marketpress.php:109 #: include/brainpress/view/admin/setting/class-woocommerce.php:106 msgid "Wenn der Kurs gelöscht ist, dann:" msgstr "" @@ -8201,7 +8201,7 @@ msgstr "" #: include/brainpress/view/admin/setting/class-setup.php:70 #, php-format msgid "" -"%s hat auch PSeCommerce mit dabei - Falls Du Kurse verkaufen möchtest, dann " +"%s hat auch MarketPress mit dabei - Falls Du Kurse verkaufen möchtest, dann " "installiere es einfach über das BrainPress Dashboard." msgstr "" @@ -9564,7 +9564,7 @@ msgstr "" #: include/brainpress/view/admin/setting/class-woocommerce.php:72 msgid "" -"Wenn diese Option aktiviert ist, wird WooCommerce anstelle von PSeCommerce " +"Wenn diese Option aktiviert ist, wird WooCommerce anstelle von MarketPress " "für den Verkauf von Kursen verwendet" msgstr "" diff --git a/readme.txt b/readme.txt index 7cd8ddb..c645929 100644 --- a/readme.txt +++ b/readme.txt @@ -98,7 +98,7 @@ Make a [donation by bank transfer or PayPal](https://github.com/cp-psourcespende = 2.3.5 = * DSGVO neu integriert -* Anpassungen PSeCommerce +* Anpassungen MarketPress * Text Overhaul * PSource Updater v1.1 integriert diff --git a/themes/brainpress-theme/style.css b/themes/brainpress-theme/style.css index 5181d11..840bfe4 100644 --- a/themes/brainpress-theme/style.css +++ b/themes/brainpress-theme/style.css @@ -1324,7 +1324,7 @@ a.rsswidget { } -body.psecommerce-course .entry-content-excerpt { +body.marketpress-course .entry-content-excerpt { min-height: 360px; }