PluginProbe
Kit (formerly ConvertKit) – Email Newsletter, Email Marketing, Membership, Subscribers and Landing Pages / 3.3.0
Kit (formerly ConvertKit) – Email Newsletter, Email Marketing, Membership, Subscribers and Landing Pages v3.3.0
3.4.6 3.4.5 3.4.4 3.4.3 3.4.2 3.4.1 3.4.0 3.3.9 3.3.8 3.3.7 3.3.6 3.3.5 3.3.4 3.3.3 3.3.2 3.3.1 2.2.0 2.2.1 2.2.2 2.2.3 2.2.4 2.2.5 2.2.6 2.2.7 2.2.8 All 199 releases
← All changes | includes/class-convertkit-settings-restrict-content.php +52 -20 2.2.8 → 3.3.0 View file →
@@ -64,8 +64,34 @@
64 64
65 65 }
66 66
67 67 /**
68 + * Returns whether crawlers are permitted to index Member Content in the Plugin settings.
69 + *
70 + * @since 2.4.1
71 + *
72 + * @return bool
73 + */
74 + public function permit_crawlers() {
75 +
76 + return ( $this->settings['permit_crawlers'] === 'on' ? true : false );
77 +
78 + }
79 +
80 + /**
81 + * Returns whether login by email is required for Member Content by Tag functionality.
82 + *
83 + * @since 2.7.2
84 + *
85 + * @return bool
86 + */
87 + public function require_tag_login() {
88 +
89 + return ( $this->settings['require_tag_login'] === 'on' ? true : false );
90 +
91 + }
92 +
93 + /**
68 94 * Returns Restrict Content settings value for the given key.
69 95 *
70 96 * @since 2.1.0
71 97 *
@@ -89,21 +115,8 @@
89 115
90 116 }
91 117
92 118 /**
93 - * Returns whether Restrict Content is enabled in the Plugin settings.
94 - *
95 - * @since 2.1.0
96 - *
97 - * @return bool
98 - */
99 - public function enabled() {
100 -
101 - return ( $this->settings['enabled'] === 'on' ? true : false );
102 -
103 - }
104 -
105 - /**
106 119 * The default settings, used when the ConvertKit Restrict Content Settings haven't been saved
107 120 * e.g. on a new installation.
108 121 *
109 122 * @since 2.1.0
@@ -112,15 +125,34 @@
112 125 */
113 126 public function get_defaults() {
114 127
115 128 $defaults = array(
116 - 'enabled' => '',
117 - 'subscribe_text' => __( 'This content is only available to premium subscribers', 'convertkit' ),
129 + // Permit Crawlers.
130 + 'permit_crawlers' => '',
131 +
132 + // Restrict by Form.
133 + 'no_access_text_form' => __( 'Your account does not have access to this content. Please use the form above to subscribe.', 'convertkit' ),
134 +
135 + // Restrict by Product.
136 + 'subscribe_heading' => __( 'Read this post with a premium subscription', 'convertkit' ),
137 + 'subscribe_text' => __( 'This post is only available to premium subscribers. Join today to get access to all posts.', 'convertkit' ),
138 + 'no_access_text' => __( 'Your account does not have access to this content. Please use the button above to purchase, or enter the email address you used to purchase the product.', 'convertkit' ),
139 +
140 + // Restrict by Tag.
141 + 'subscribe_heading_tag' => __( 'Subscribe to keep reading', 'convertkit' ),
142 + 'subscribe_text_tag' => __( 'This post is free to read but only available to subscribers. Join today to get access to all posts.', 'convertkit' ),
143 + 'require_tag_login' => '', // blank|on.
144 + 'no_access_text_tag' => __( 'Your account does not have access to this content. Please use the form above to subscribe.', 'convertkit' ),
145 +
146 + // All.
118 147 'subscribe_button_label' => __( 'Subscribe', 'convertkit' ),
119 - 'email_text' => __( 'Already a premium subscriber? Enter the email address used when purchasing below, to receive a login link to access.', 'convertkit' ),
120 - 'email_button_label' => __( 'Send email', 'convertkit' ),
121 - 'email_check_text' => __( 'Check your email and click the link to login, or enter the code from the email below.', 'convertkit' ),
122 - 'no_access_text' => __( 'Your account does not have access to this content. Please use the button below to purchase, or enter the email address you used to purchase the product.', 'convertkit' ),
148 + 'email_text' => __( 'Already subscribed?', 'convertkit' ),
149 + 'email_button_label' => __( 'Log in', 'convertkit' ),
150 + 'email_heading' => __( 'Log in to read this post', 'convertkit' ),
151 + 'email_description_text' => __( 'We\'ll email you a magic code to log you in without a password.', 'convertkit' ),
152 + 'email_check_heading' => __( 'We just emailed you a log in code', 'convertkit' ),
153 + 'email_check_text' => __( 'Enter the code below to finish logging in', 'convertkit' ),
154 + 'container_css_classes' => '',
123 155 );
124 156
125 157 /**
126 158 * The default settings, used when the ConvertKit Restrict Content Settings haven't been saved
@@ -127,9 +159,9 @@
127 159 * e.g. on a new installation.
128 160 *
129 161 * @since 2.1.0
130 162 *
131 - * @param array $defaults
163 + * @param array $defaults Default settings.
132 164 */
133 165 $defaults = apply_filters( 'convertkit_settings_restrict_content_get_defaults', $defaults );
134 166
135 167 return $defaults;