Version Description
= v140409 =
(Maintenance Release) Upgrade immediately.
Download this release
Release Info
Developer | JasWSInc |
Plugin | s2Member Framework (Member Roles, Capabilities, Membership, PayPal Members) |
Version | 140409 |
Comparing to | |
See all releases |
Code changes from version 140328 to 140409
- checksum.txt +1 -1
- includes/classes/mo-page-in.inc.php +158 -96
- includes/classes/mo-page.inc.php +77 -63
- includes/classes/paypal-notify-in.inc.php +4 -4
- includes/classes/paypal-return-in.inc.php +5 -5
- includes/classes/roles-caps.inc.php +175 -183
- includes/classes/users-list.inc.php +1 -1
- includes/codes.inc.php +33 -33
- includes/hooks.inc.php +2 -0
- includes/menu-pages/code-samples/api-mop-vars-e.x-php +5 -58
- includes/menu-pages/code-samples/api-mop-vars-o.x-php +47 -22
- includes/menu-pages/code-samples/api-mop-vars-ro.x-php +38 -0
- includes/menu-pages/code-samples/api-mop-vars.x-php +45 -44
- includes/menu-pages/gen-ops.inc.php +1450 -1422
- includes/menu-pages/scripting.inc.php +13 -7
- includes/syscon.inc.php +4 -0
- includes/translations/s2member.pot +19 -19
- readme.txt +13 -3
- s2member.php +4 -4
checksum.txt
CHANGED
@@ -1 +1 @@
|
|
1 |
-
|
1 |
+
0dc9576ca2b6a5856d4e1e602dccc109
|
includes/classes/mo-page-in.inc.php
CHANGED
@@ -1,105 +1,167 @@
|
|
1 |
<?php
|
2 |
/**
|
3 |
-
* Membership Options Page (inner processing routines).
|
4 |
-
*
|
5 |
-
* Copyright: © 2009-2011
|
6 |
-
* {@link http://www.websharks-inc.com/ WebSharks, Inc.}
|
7 |
-
* (coded in the USA)
|
8 |
-
*
|
9 |
-
* Released under the terms of the GNU General Public License.
|
10 |
-
* You should have received a copy of the GNU General Public License,
|
11 |
-
* along with this software. In the main directory, see: /licensing/
|
12 |
-
* If not, see: {@link http://www.gnu.org/licenses/}.
|
13 |
-
*
|
14 |
-
* @package s2Member\Membership_Options_Page
|
15 |
-
* @since 3.5
|
16 |
-
*/
|
17 |
-
if
|
18 |
exit ("Do not access this file directly.");
|
19 |
|
20 |
-
if
|
21 |
{
|
22 |
/**
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
class c_ws_plugin__s2member_mo_page_in
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
|
99 |
-
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
104 |
}
|
105 |
?>
|
1 |
<?php
|
2 |
/**
|
3 |
+
* Membership Options Page (inner processing routines).
|
4 |
+
*
|
5 |
+
* Copyright: © 2009-2011
|
6 |
+
* {@link http://www.websharks-inc.com/ WebSharks, Inc.}
|
7 |
+
* (coded in the USA)
|
8 |
+
*
|
9 |
+
* Released under the terms of the GNU General Public License.
|
10 |
+
* You should have received a copy of the GNU General Public License,
|
11 |
+
* along with this software. In the main directory, see: /licensing/
|
12 |
+
* If not, see: {@link http://www.gnu.org/licenses/}.
|
13 |
+
*
|
14 |
+
* @package s2Member\Membership_Options_Page
|
15 |
+
* @since 3.5
|
16 |
+
*/
|
17 |
+
if(realpath(__FILE__) === realpath($_SERVER["SCRIPT_FILENAME"]))
|
18 |
exit ("Do not access this file directly.");
|
19 |
|
20 |
+
if(!class_exists("c_ws_plugin__s2member_mo_page_in"))
|
21 |
{
|
22 |
/**
|
23 |
+
* Membership Options Page (inner processing routines).
|
24 |
+
*
|
25 |
+
* @package s2Member\Membership_Options_Page
|
26 |
+
* @since 3.5
|
27 |
+
*/
|
28 |
class c_ws_plugin__s2member_mo_page_in
|
29 |
+
{
|
30 |
+
/**
|
31 |
+
* Forces a redirection to the Membership Options Page for s2Member.
|
32 |
+
*
|
33 |
+
* This can be used by 3rd party apps that are not aware of which Page is currently set as the Membership Options Page.
|
34 |
+
* Example usage: `http://example.com/?s2member_membership_options_page=1`
|
35 |
+
*
|
36 |
+
* Redirection URLs containing array brackets MUST be URL encoded to get through: ``wp_sanitize_redirect()``.
|
37 |
+
* So we pass everything to ``urlencode_deep()``, as an array. It handles this via ``_http_build_query()``.
|
38 |
+
* See bug report here: {@link http://core.trac.wordpress.org/ticket/17052}
|
39 |
+
*
|
40 |
+
* @package s2Member\Membership_Options_Page
|
41 |
+
* @since 3.5
|
42 |
+
*
|
43 |
+
* @attaches-to ``add_action("init");``
|
44 |
+
*
|
45 |
+
* @return null Or exits script execution after redirection w/ `301` status.
|
46 |
+
*/
|
47 |
+
public static function membership_options_page() // Real Membership Options Page.
|
48 |
+
{
|
49 |
+
do_action("ws_plugin__s2member_before_membership_options_page", get_defined_vars());
|
50 |
+
|
51 |
+
if(!empty ($_GET["s2member_membership_options_page"]) && is_array($_g = c_ws_plugin__s2member_utils_strings::trim_deep(stripslashes_deep($_GET))))
|
52 |
+
{
|
53 |
+
$args = array(); // Initialize this to an empty array value.
|
54 |
+
|
55 |
+
foreach($_g as $var => $value) // Include all of the `_?s2member_` variables.
|
56 |
+
// Do NOT include `s2member_membership_options_page`; creates a redirection loop.
|
57 |
+
if(preg_match("/^_?s2member_/", $var) && $var !== "s2member_membership_options_page")
|
58 |
+
$args[$var] = $value; // Supports nested arrays.
|
59 |
+
|
60 |
+
wp_redirect(add_query_arg(urlencode_deep($args), get_page_link($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["membership_options_page"])), 301).exit ();
|
61 |
+
}
|
62 |
+
do_action("ws_plugin__s2member_after_membership_options_page", get_defined_vars());
|
63 |
+
}
|
64 |
+
|
65 |
+
/**
|
66 |
+
* Redirects to Membership Options Page w/ MOP Vars.
|
67 |
+
*
|
68 |
+
* Redirection URLs containing array brackets MUST be URL encoded to get through: ``wp_sanitize_redirect()``.
|
69 |
+
* So we pass everything to ``urlencode_deep()``, as an array. It handles this via ``_http_build_query()``.
|
70 |
+
* See bug report here: {@link http://core.trac.wordpress.org/ticket/17052}
|
71 |
+
*
|
72 |
+
* @package s2Member\Membership_Options_Page
|
73 |
+
* @since 111101
|
74 |
+
*
|
75 |
+
* @param str $seeking_type Seeking content type. One of: `post|page|catg|ptag|file|ruri`.
|
76 |
+
* @param str|int $seeking_type_value Seeking content type data. String, or a Post/Page ID.
|
77 |
+
* @param str $req_type Access requirement type. One of these values: `level|ccap|sp`.
|
78 |
+
* @param str|int $req_type_value Access requirement. String, or a Post/Page ID.
|
79 |
+
* @param str $seeking_uri The full URI that access was attempted on.
|
80 |
+
* @param str $res_type Restriction type that's preventing access.
|
81 |
+
* One of: `post|page|catg|ptag|file|ruri|ccap|sp|sys`.
|
82 |
+
* Defaults to ``$seeking_type``.
|
83 |
+
*
|
84 |
+
* @return bool This function always returns true.
|
85 |
+
*
|
86 |
+
* @TODO Update documentation in the API Scripting section.
|
87 |
+
*/
|
88 |
+
public static function wp_redirect_w_mop_vars($seeking_type = FALSE, $seeking_type_value = FALSE, $req_type = FALSE, $req_type_value = FALSE, $seeking_uri = FALSE, $res_type = FALSE)
|
89 |
+
{
|
90 |
+
do_action("ws_plugin__s2member_before_wp_redirect_w_mop_vars", get_defined_vars());
|
91 |
+
|
92 |
+
foreach(array("seeking_type", "seeking_type_value", "req_type", "req_type_value", "seeking_uri", "res_type") as $_param)
|
93 |
+
{
|
94 |
+
if($_param === "seeking_uri" || ($_param === "seeking_type_value" && $seeking_type === "ruri"))
|
95 |
+
${$_param} = base64_encode((string)${$_param});
|
96 |
+
else ${$_param} = str_replace(".", "", (string)${$_param});
|
97 |
+
}
|
98 |
+
unset($_param); // Housekeeping.
|
99 |
+
|
100 |
+
if(!$res_type) $res_type = $seeking_type;
|
101 |
+
|
102 |
+
$vars = $res_type.".".$req_type.".".$req_type_value.".";
|
103 |
+
$vars .= $seeking_type.".".$seeking_type_value.".".$seeking_uri;
|
104 |
+
$vars = array("_s2member_vars" => $vars);
|
105 |
+
|
106 |
+
$status = apply_filters("ws_plugin__s2member_content_redirect_status", 301, get_defined_vars());
|
107 |
+
$status = apply_filters("ws_plugin__s2member_wp_redirect_w_mop_vars_status", $status, get_defined_vars());
|
108 |
+
|
109 |
+
$mop_url = get_page_link($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["membership_options_page"]);
|
110 |
+
if($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["membership_options_page_vars_enable"])
|
111 |
+
{
|
112 |
+
$mop_url = add_query_arg(urlencode_deep($vars), $mop_url);
|
113 |
+
$mop_url = c_ws_plugin__s2member_utils_urls::add_s2member_sig($mop_url);
|
114 |
+
}
|
115 |
+
wp_redirect($mop_url, $status); // NOTE: we do not exit here (on purpose).
|
116 |
+
|
117 |
+
do_action("ws_plugin__s2member_after_wp_redirect_w_mop_vars", get_defined_vars());
|
118 |
+
|
119 |
+
return TRUE; // Always returns true here.
|
120 |
+
}
|
121 |
+
|
122 |
+
/*
|
123 |
+
* s2Member's MOP Vars are now a dot (`.`) delimited list of six values.
|
124 |
+
*
|
125 |
+
* e.g. .../membership-options-page/
|
126 |
+
* ?_s2member_vars=[restriction type].[requirement type].[requirement type value].
|
127 |
+
* [seeking type].[seeking type value].[seeking URI base 64 encoded]
|
128 |
+
*/
|
129 |
+
public static function back_compat_mop_vars()
|
130 |
+
{
|
131 |
+
if(empty($_REQUEST["_s2member_vars"])
|
132 |
+
|| !is_string($_REQUEST["_s2member_vars"])
|
133 |
+
) return;
|
134 |
+
|
135 |
+
$v = explode(".", $_REQUEST["_s2member_vars"]);
|
136 |
+
if(count($v) !== 6) return;
|
137 |
+
|
138 |
+
/*
|
139 |
+
* Back compat. Deprecated since v1404xx.
|
140 |
+
*/
|
141 |
+
$ov["_s2member_seeking"] = array(
|
142 |
+
"type" => $v[3],
|
143 |
+
$v[3] => $v[4],
|
144 |
+
"_uri" => $v[5]
|
145 |
+
);
|
146 |
+
$ov["_s2member_req"] = array(
|
147 |
+
"type" => $v[1],
|
148 |
+
$v[1] => $v[2],
|
149 |
+
);
|
150 |
+
$ov["_s2member_res"]["type"] = $v[0];
|
151 |
+
|
152 |
+
/*
|
153 |
+
* Back compat. Deprecated since v1104xx.
|
154 |
+
*/
|
155 |
+
$ov["s2member_seeking"] = $v[3]."-".$v[4];
|
156 |
+
$ov["s2member_".$v[1]."_req"] = $v[2];
|
157 |
+
|
158 |
+
/*
|
159 |
+
* Fill both $_GET and $_REQUEST vars.
|
160 |
+
*/
|
161 |
+
foreach($ov as $_k => $_v)
|
162 |
+
$_GET[$_k] = $_REQUEST[$_k] = $_v;
|
163 |
+
unset($_k, $_v);
|
164 |
+
}
|
165 |
+
}
|
166 |
}
|
167 |
?>
|
includes/classes/mo-page.inc.php
CHANGED
@@ -1,72 +1,86 @@
|
|
1 |
<?php
|
2 |
/**
|
3 |
-
* Membership Options Page.
|
4 |
-
*
|
5 |
-
* Copyright: © 2009-2011
|
6 |
-
* {@link http://www.websharks-inc.com/ WebSharks, Inc.}
|
7 |
-
* (coded in the USA)
|
8 |
-
*
|
9 |
-
* Released under the terms of the GNU General Public License.
|
10 |
-
* You should have received a copy of the GNU General Public License,
|
11 |
-
* along with this software. In the main directory, see: /licensing/
|
12 |
-
* If not, see: {@link http://www.gnu.org/licenses/}.
|
13 |
-
*
|
14 |
-
* @package s2Member\Membership_Options_Page
|
15 |
-
* @since 3.5
|
16 |
-
*/
|
17 |
-
if
|
18 |
exit ("Do not access this file directly.");
|
19 |
|
20 |
-
if
|
21 |
{
|
22 |
/**
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
class c_ws_plugin__s2member_mo_page
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
71 |
}
|
72 |
?>
|
1 |
<?php
|
2 |
/**
|
3 |
+
* Membership Options Page.
|
4 |
+
*
|
5 |
+
* Copyright: © 2009-2011
|
6 |
+
* {@link http://www.websharks-inc.com/ WebSharks, Inc.}
|
7 |
+
* (coded in the USA)
|
8 |
+
*
|
9 |
+
* Released under the terms of the GNU General Public License.
|
10 |
+
* You should have received a copy of the GNU General Public License,
|
11 |
+
* along with this software. In the main directory, see: /licensing/
|
12 |
+
* If not, see: {@link http://www.gnu.org/licenses/}.
|
13 |
+
*
|
14 |
+
* @package s2Member\Membership_Options_Page
|
15 |
+
* @since 3.5
|
16 |
+
*/
|
17 |
+
if(realpath(__FILE__) === realpath($_SERVER["SCRIPT_FILENAME"]))
|
18 |
exit ("Do not access this file directly.");
|
19 |
|
20 |
+
if(!class_exists("c_ws_plugin__s2member_mo_page"))
|
21 |
{
|
22 |
/**
|
23 |
+
* Membership Options Page.
|
24 |
+
*
|
25 |
+
* @package s2Member\Membership_Options_Page
|
26 |
+
* @since 3.5
|
27 |
+
*/
|
28 |
class c_ws_plugin__s2member_mo_page
|
29 |
+
{
|
30 |
+
/**
|
31 |
+
* Forces a redirection to the Membership Options Page for s2Member.
|
32 |
+
*
|
33 |
+
* This can be used by 3rd party apps that are not aware of which Page is currently set as the Membership Options Page.
|
34 |
+
* Example usage: `http://example.com/?s2member_membership_options_page=1`
|
35 |
+
*
|
36 |
+
* @package s2Member\Membership_Options_Page
|
37 |
+
* @since 3.5
|
38 |
+
*
|
39 |
+
* @attaches-to ``add_action("init");``
|
40 |
+
*
|
41 |
+
* @return null|inner Return-value of inner routine.
|
42 |
+
*/
|
43 |
+
public static function membership_options_page()
|
44 |
+
{
|
45 |
+
if(!empty ($_GET["s2member_membership_options_page"]))
|
46 |
+
{
|
47 |
+
return c_ws_plugin__s2member_mo_page_in::membership_options_page();
|
48 |
+
}
|
49 |
+
}
|
50 |
+
|
51 |
+
/**
|
52 |
+
* Redirects to Membership Options Page w/ MOP Vars.
|
53 |
+
*
|
54 |
+
* @package s2Member\Membership_Options_Page
|
55 |
+
* @since 111101
|
56 |
+
*
|
57 |
+
* @param str $seeking_type Seeking content type. One of: `post|page|catg|ptag|file|ruri`.
|
58 |
+
* @param str|int $seeking_type_value Seeking content type data. String, or a Post/Page ID.
|
59 |
+
* @param str $req_type Access requirement type. One of these values: `level|ccap|sp`.
|
60 |
+
* @param str|int $req_type_value Access requirement. String, or a Post/Page ID.
|
61 |
+
* @param str $seeking_uri The full URI that access was attempted on.
|
62 |
+
* @param str $res_type Restriction type that's preventing access.
|
63 |
+
* One of: `post|page|catg|ptag|file|ruri|ccap|sp|sys`.
|
64 |
+
* Defaults to ``$seeking_type``.
|
65 |
+
*
|
66 |
+
* @return inner Return-value of inner routine.
|
67 |
+
*/
|
68 |
+
public static function wp_redirect_w_mop_vars($seeking_type = FALSE, $seeking_type_value = FALSE, $req_type = FALSE, $req_type_value = FALSE, $seeking_uri = FALSE, $res_type = FALSE)
|
69 |
+
{
|
70 |
+
return c_ws_plugin__s2member_mo_page_in::wp_redirect_w_mop_vars($seeking_type, $seeking_type_value, $req_type, $req_type_value, $seeking_uri, $res_type);
|
71 |
+
}
|
72 |
+
|
73 |
+
/*
|
74 |
+
* s2Member's MOP Vars are now a dot (`.`) delimited list of six values.
|
75 |
+
*
|
76 |
+
* e.g. .../membership-options-page/
|
77 |
+
* ?_s2member_vars=[restriction type].[requirement type].[requirement type value].
|
78 |
+
* [seeking type].[seeking type value].[seeking URI base 64 encoded]
|
79 |
+
*/
|
80 |
+
public static function back_compat_mop_vars()
|
81 |
+
{
|
82 |
+
return c_ws_plugin__s2member_mo_page_in::back_compat_mop_vars();
|
83 |
+
}
|
84 |
+
}
|
85 |
}
|
86 |
?>
|
includes/classes/paypal-notify-in.inc.php
CHANGED
@@ -176,22 +176,22 @@ if (!class_exists ("c_ws_plugin__s2member_paypal_notify_in"))
|
|
176 |
Add IPN proxy (when available) to the ``$paypal`` array.
|
177 |
*/
|
178 |
if (!empty ($_REQUEST["s2member_paypal_proxy"]))
|
179 |
-
$paypal["s2member_paypal_proxy"] = esc_html(trim(stripslashes($_REQUEST["s2member_paypal_proxy"])));
|
180 |
/*
|
181 |
Add IPN proxy use vars (when available) to the ``$paypal`` array.
|
182 |
*/
|
183 |
if (!empty ($_REQUEST["s2member_paypal_proxy_use"]))
|
184 |
-
$paypal["s2member_paypal_proxy_use"] = esc_html(trim(stripslashes($_REQUEST["s2member_paypal_proxy_use"])));
|
185 |
/*
|
186 |
Add IPN proxy coupon vars (when available) to the ``$paypal`` array.
|
187 |
*/
|
188 |
if (!empty ($_REQUEST["s2member_paypal_proxy_coupon"]))
|
189 |
-
$paypal["s2member_paypal_proxy_coupon"] =
|
190 |
/*
|
191 |
Also add IPN proxy self-verification (when available) to the ``$paypal`` array.
|
192 |
*/
|
193 |
if (!empty ($_REQUEST["s2member_paypal_proxy_verification"]))
|
194 |
-
$paypal["s2member_paypal_proxy_verification"] = esc_html(trim(stripslashes($_REQUEST["s2member_paypal_proxy_verification"])));
|
195 |
/*
|
196 |
If debugging/logging is enabled; we need to append ``$paypal`` to the log file.
|
197 |
Logging now supports Multisite Networking as well.
|
176 |
Add IPN proxy (when available) to the ``$paypal`` array.
|
177 |
*/
|
178 |
if (!empty ($_REQUEST["s2member_paypal_proxy"]))
|
179 |
+
$paypal["s2member_paypal_proxy"] = esc_html(trim(stripslashes((string)$_REQUEST["s2member_paypal_proxy"])));
|
180 |
/*
|
181 |
Add IPN proxy use vars (when available) to the ``$paypal`` array.
|
182 |
*/
|
183 |
if (!empty ($_REQUEST["s2member_paypal_proxy_use"]))
|
184 |
+
$paypal["s2member_paypal_proxy_use"] = esc_html(trim(stripslashes((string)$_REQUEST["s2member_paypal_proxy_use"])));
|
185 |
/*
|
186 |
Add IPN proxy coupon vars (when available) to the ``$paypal`` array.
|
187 |
*/
|
188 |
if (!empty ($_REQUEST["s2member_paypal_proxy_coupon"]))
|
189 |
+
$paypal["s2member_paypal_proxy_coupon"] = stripslashes_deep((array)$_REQUEST["s2member_paypal_proxy_coupon"]);
|
190 |
/*
|
191 |
Also add IPN proxy self-verification (when available) to the ``$paypal`` array.
|
192 |
*/
|
193 |
if (!empty ($_REQUEST["s2member_paypal_proxy_verification"]))
|
194 |
+
$paypal["s2member_paypal_proxy_verification"] = esc_html(trim(stripslashes((string)$_REQUEST["s2member_paypal_proxy_verification"])));
|
195 |
/*
|
196 |
If debugging/logging is enabled; we need to append ``$paypal`` to the log file.
|
197 |
Logging now supports Multisite Networking as well.
|
includes/classes/paypal-return-in.inc.php
CHANGED
@@ -141,27 +141,27 @@ if (!class_exists ("c_ws_plugin__s2member_paypal_return_in"))
|
|
141 |
Add RTN proxy (when available) to the ``$paypal`` array.
|
142 |
*/
|
143 |
if (!empty ($_GET["s2member_paypal_proxy"]))
|
144 |
-
$paypal["s2member_paypal_proxy"] = esc_html(trim(stripslashes($_GET["s2member_paypal_proxy"])));
|
145 |
/*
|
146 |
Add IPN proxy use vars (when available) to the ``$paypal`` array.
|
147 |
*/
|
148 |
if (!empty ($_GET["s2member_paypal_proxy_use"]))
|
149 |
-
$paypal["s2member_paypal_proxy_use"] = esc_html(trim(stripslashes($_GET["s2member_paypal_proxy_use"])));
|
150 |
/*
|
151 |
Also add RTN proxy self-verification (when available) to the ``$paypal`` array.
|
152 |
*/
|
153 |
if (!empty ($_GET["s2member_paypal_proxy_verification"]))
|
154 |
-
$paypal["s2member_paypal_proxy_verification"] = esc_html(trim(stripslashes($_GET["s2member_paypal_proxy_verification"])));
|
155 |
/*
|
156 |
Also add RTN success redirection URL (when available) to the ``$paypal`` array.
|
157 |
*/
|
158 |
if (!empty ($_GET["s2member_paypal_return_success"]))
|
159 |
-
$paypal["s2member_paypal_return_success"] = esc_html(trim(stripslashes($_GET["s2member_paypal_return_success"])));
|
160 |
/*
|
161 |
Also add RTN t and r Attributes (when available) to the ``$paypal`` array.
|
162 |
*/
|
163 |
if (!empty ($_GET["s2member_paypal_return_tra"]))
|
164 |
-
$paypal["s2member_paypal_return_tra"] = esc_html(trim(stripslashes($_GET["s2member_paypal_return_tra"])));
|
165 |
/*
|
166 |
If debugging/logging is enabled; we need to append $paypal to the log file.
|
167 |
Logging now supports Multisite Networking as well.
|
141 |
Add RTN proxy (when available) to the ``$paypal`` array.
|
142 |
*/
|
143 |
if (!empty ($_GET["s2member_paypal_proxy"]))
|
144 |
+
$paypal["s2member_paypal_proxy"] = esc_html(trim(stripslashes((string)$_GET["s2member_paypal_proxy"])));
|
145 |
/*
|
146 |
Add IPN proxy use vars (when available) to the ``$paypal`` array.
|
147 |
*/
|
148 |
if (!empty ($_GET["s2member_paypal_proxy_use"]))
|
149 |
+
$paypal["s2member_paypal_proxy_use"] = esc_html(trim(stripslashes((string)$_GET["s2member_paypal_proxy_use"])));
|
150 |
/*
|
151 |
Also add RTN proxy self-verification (when available) to the ``$paypal`` array.
|
152 |
*/
|
153 |
if (!empty ($_GET["s2member_paypal_proxy_verification"]))
|
154 |
+
$paypal["s2member_paypal_proxy_verification"] = esc_html(trim(stripslashes((string)$_GET["s2member_paypal_proxy_verification"])));
|
155 |
/*
|
156 |
Also add RTN success redirection URL (when available) to the ``$paypal`` array.
|
157 |
*/
|
158 |
if (!empty ($_GET["s2member_paypal_return_success"]))
|
159 |
+
$paypal["s2member_paypal_return_success"] = esc_html(trim(stripslashes((string)$_GET["s2member_paypal_return_success"])));
|
160 |
/*
|
161 |
Also add RTN t and r Attributes (when available) to the ``$paypal`` array.
|
162 |
*/
|
163 |
if (!empty ($_GET["s2member_paypal_return_tra"]))
|
164 |
+
$paypal["s2member_paypal_return_tra"] = esc_html(trim(stripslashes((string)$_GET["s2member_paypal_return_tra"])));
|
165 |
/*
|
166 |
If debugging/logging is enabled; we need to append $paypal to the log file.
|
167 |
Logging now supports Multisite Networking as well.
|
includes/classes/roles-caps.inc.php
CHANGED
@@ -1,207 +1,199 @@
|
|
1 |
<?php
|
2 |
/**
|
3 |
-
* Roles/Capabilities.
|
4 |
-
*
|
5 |
-
* Copyright: © 2009-2011
|
6 |
-
* {@link http://www.websharks-inc.com/ WebSharks, Inc.}
|
7 |
-
* (coded in the USA)
|
8 |
-
*
|
9 |
-
* Released under the terms of the GNU General Public License.
|
10 |
-
* You should have received a copy of the GNU General Public License,
|
11 |
-
* along with this software. In the main directory, see: /licensing/
|
12 |
-
* If not, see: {@link http://www.gnu.org/licenses/}.
|
13 |
-
*
|
14 |
-
* @package s2Member\Roles_Caps
|
15 |
-
* @since 110524RC
|
16 |
-
*/
|
17 |
if(realpath(__FILE__) === realpath($_SERVER["SCRIPT_FILENAME"]))
|
18 |
exit("Do not access this file directly.");
|
19 |
|
20 |
if(!class_exists("c_ws_plugin__s2member_roles_caps"))
|
21 |
{
|
22 |
/**
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
class c_ws_plugin__s2member_roles_caps
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
if(0 === 0) // Subscriber Role is required by s2Member.
|
59 |
-
{
|
60 |
-
$caps = array("read" => true, "level_0" => true);
|
61 |
-
$caps = array_merge($caps, array("access_s2member_level0" => true));
|
62 |
-
$caps = (!empty($bbp_participant_caps)) ? array_merge($caps, $bbp_participant_caps) : $caps;
|
63 |
-
|
64 |
-
if(!($role = &get_role("subscriber")))
|
65 |
-
{
|
66 |
-
add_role("subscriber", "Subscriber");
|
67 |
-
$role = &get_role("subscriber");
|
68 |
-
}
|
69 |
-
|
70 |
-
foreach(array_keys($caps) as $cap)
|
71 |
-
$role->add_cap($cap);
|
72 |
-
}
|
73 |
-
|
74 |
-
for($n = 1; $n <= $GLOBALS["WS_PLUGIN__"]["s2member"]["c"]["levels"]; $n++)
|
75 |
-
{
|
76 |
-
for($i = 0, $caps = array("read" => true, "level_0" => true); $i <= $n; $i++)
|
77 |
-
$caps = array_merge($caps, array("access_s2member_level".$i => true));
|
78 |
-
$caps = (!empty($bbp_participant_caps)) ? array_merge($caps, $bbp_participant_caps) : $caps;
|
79 |
-
|
80 |
-
if(!($role = &get_role("s2member_level".$n)))
|
81 |
-
{
|
82 |
-
add_role("s2member_level".$n, "s2Member Level ".$n);
|
83 |
-
$role = &get_role("s2member_level".$n);
|
84 |
-
}
|
85 |
-
|
86 |
-
foreach(array_keys($caps) as $cap)
|
87 |
-
$role->add_cap($cap);
|
88 |
-
}
|
89 |
-
|
90 |
-
$full_access_roles = array("administrator", "editor", "author", "contributor");
|
91 |
-
|
92 |
-
if(function_exists("bbp_get_caps_for_role") && !function_exists("bbp_get_dynamic_roles") /* bbPress < v2.2 integration. */)
|
93 |
-
$full_access_roles = array_merge($full_access_roles, (array)bbp_get_moderator_role());
|
94 |
-
|
95 |
-
foreach($full_access_roles as $role)
|
96 |
-
{
|
97 |
-
if(($role = &get_role($role)))
|
98 |
-
for($n = 0; $n <= $GLOBALS["WS_PLUGIN__"]["s2member"]["c"]["levels"]; $n++)
|
99 |
-
$role->add_cap("access_s2member_level".$n);
|
100 |
-
}
|
101 |
-
}
|
102 |
-
|
103 |
-
do_action("ws_plugin__s2member_after_config_roles", get_defined_vars());
|
104 |
-
|
105 |
-
return /* Return for uniformity. */;
|
106 |
-
}
|
107 |
-
/**
|
108 |
-
* Adds support for bbPress v2.2+ dynamic roles.
|
109 |
-
*
|
110 |
-
* @package s2Member\Roles_Caps
|
111 |
-
* @since 112512
|
112 |
-
*
|
113 |
-
* @attaches-to ``add_filter("bbp_get_caps_for_role");``
|
114 |
-
*
|
115 |
-
* @return array
|
116 |
-
*/
|
117 |
-
public static function bbp_dynamic_role_caps($caps = FALSE, $role = FALSE)
|
118 |
-
{
|
119 |
-
if(function_exists("bbp_get_dynamic_roles") && $role !== bbp_get_blocked_role())
|
120 |
-
if(!did_action("bbp_deactivation") && !did_action("bbp_uninstall"))
|
121 |
{
|
122 |
-
$caps =
|
123 |
-
$caps = array_merge($caps, array("access_s2member_level0" =>
|
124 |
-
|
125 |
-
|
|
|
126 |
{
|
127 |
-
|
128 |
-
|
129 |
}
|
|
|
|
|
130 |
}
|
131 |
-
|
132 |
-
|
133 |
-
|
134 |
-
|
135 |
-
|
136 |
-
* @package s2Member\Roles_Caps
|
137 |
-
* @since 110524RC
|
138 |
-
*
|
139 |
-
* @return null
|
140 |
-
*/
|
141 |
-
public static function unlink_roles()
|
142 |
-
{
|
143 |
-
do_action("ws_plugin__s2member_before_unlink_roles", get_defined_vars());
|
144 |
-
|
145 |
-
if(!apply_filters("ws_plugin__s2member_lock_roles_caps", false))
|
146 |
-
{
|
147 |
-
if(($role = &get_role("subscriber")))
|
148 |
-
$role->remove_cap("access_s2member_level0");
|
149 |
|
150 |
-
|
151 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
152 |
|
153 |
-
|
|
|
154 |
|
155 |
-
|
156 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
157 |
|
158 |
-
|
159 |
{
|
160 |
-
|
161 |
-
|
162 |
-
$role->remove_cap("access_s2member_level".$n);
|
163 |
}
|
164 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
165 |
|
166 |
-
|
167 |
-
|
168 |
-
return /* Return for uniformity. */;
|
169 |
-
}
|
170 |
-
/**
|
171 |
-
* Updates Roles/Capabilities via AJAX.
|
172 |
-
*
|
173 |
-
* @package s2Member\Roles_Caps
|
174 |
-
* @since 110524RC
|
175 |
-
*
|
176 |
-
* @attaches-to ``add_action("wp_ajax_ws_plugin__s2member_update_roles_via_ajax");``
|
177 |
-
*
|
178 |
-
* @return null Exits script execution after output for AJAX caller.
|
179 |
-
*/
|
180 |
-
public static function update_roles_via_ajax()
|
181 |
-
{
|
182 |
-
do_action("ws_plugin__s2member_before_update_roles_via_ajax", get_defined_vars());
|
183 |
-
|
184 |
-
status_header(200); // Send a 200 OK status header.
|
185 |
-
header("Content-Type: text/plain; charset=UTF-8"); // Content-Type with UTF-8.
|
186 |
-
while (@ob_end_clean ()); // Clean any existing output buffers.
|
187 |
-
|
188 |
-
if(current_user_can("create_users")) // Check privileges. Ability to create Users?
|
189 |
-
|
190 |
-
if(!empty($_POST["ws_plugin__s2member_update_roles_via_ajax"]))
|
191 |
-
if(($nonce = $_POST["ws_plugin__s2member_update_roles_via_ajax"]))
|
192 |
-
if(wp_verify_nonce($nonce, "ws-plugin--s2member-update-roles-via-ajax"))
|
193 |
-
|
194 |
-
if(!apply_filters("ws_plugin__s2member_lock_roles_caps", false))
|
195 |
-
{
|
196 |
-
c_ws_plugin__s2member_roles_caps::config_roles();
|
197 |
-
$success = true; // Roles updated.
|
198 |
-
}
|
199 |
-
else // Else flag as having been locked here.
|
200 |
-
$locked = true;
|
201 |
-
|
202 |
-
exit(apply_filters("ws_plugin__s2member_update_roles_via_ajax", // Also handle ``$locked`` here.
|
203 |
((isset($success) && $success) ? "1" : ((isset($locked) && $locked) ? "l" : "0")), get_defined_vars()));
|
204 |
-
|
205 |
-
|
206 |
}
|
207 |
?>
|
1 |
<?php
|
2 |
/**
|
3 |
+
* Roles/Capabilities.
|
4 |
+
*
|
5 |
+
* Copyright: © 2009-2011
|
6 |
+
* {@link http://www.websharks-inc.com/ WebSharks, Inc.}
|
7 |
+
* (coded in the USA)
|
8 |
+
*
|
9 |
+
* Released under the terms of the GNU General Public License.
|
10 |
+
* You should have received a copy of the GNU General Public License,
|
11 |
+
* along with this software. In the main directory, see: /licensing/
|
12 |
+
* If not, see: {@link http://www.gnu.org/licenses/}.
|
13 |
+
*
|
14 |
+
* @package s2Member\Roles_Caps
|
15 |
+
* @since 110524RC
|
16 |
+
*/
|
17 |
if(realpath(__FILE__) === realpath($_SERVER["SCRIPT_FILENAME"]))
|
18 |
exit("Do not access this file directly.");
|
19 |
|
20 |
if(!class_exists("c_ws_plugin__s2member_roles_caps"))
|
21 |
{
|
22 |
/**
|
23 |
+
* Roles/Capabilities.
|
24 |
+
*
|
25 |
+
* @package s2Member\Roles_Caps
|
26 |
+
* @since 110524RC
|
27 |
+
*/
|
28 |
class c_ws_plugin__s2member_roles_caps
|
29 |
+
{
|
30 |
+
/**
|
31 |
+
* Configures Roles/Capabilities.
|
32 |
+
*
|
33 |
+
* @package s2Member\Roles_Caps
|
34 |
+
* @since 110524RC
|
35 |
+
*
|
36 |
+
* @return null
|
37 |
+
*/
|
38 |
+
public static function config_roles()
|
39 |
+
{
|
40 |
+
do_action("ws_plugin__s2member_before_config_roles", get_defined_vars());
|
41 |
+
|
42 |
+
if(!apply_filters("ws_plugin__s2member_lock_roles_caps", FALSE))
|
43 |
+
{
|
44 |
+
c_ws_plugin__s2member_roles_caps::unlink_roles();
|
45 |
+
|
46 |
+
if(function_exists("bbp_get_dynamic_roles") /* bbPress v2.2+ integration. */)
|
47 |
+
{
|
48 |
+
foreach(bbp_get_caps_for_role(bbp_get_participant_role()) as $bbp_participant_cap => $bbp_participant_cap_is)
|
49 |
+
if($bbp_participant_cap_is /* Is this capability enabled? */)
|
50 |
+
$bbp_participant_caps[$bbp_participant_cap] = TRUE;
|
51 |
+
}
|
52 |
+
else if(function_exists("bbp_get_caps_for_role") /* bbPress < v2.2 integration. */)
|
53 |
+
{
|
54 |
+
foreach(bbp_get_caps_for_role(bbp_get_participant_role()) as $bbp_participant_cap)
|
55 |
+
$bbp_participant_caps[$bbp_participant_cap] = TRUE;
|
56 |
+
}
|
57 |
+
if(0 === 0) // Subscriber Role is required by s2Member.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
58 |
{
|
59 |
+
$caps = array("read" => TRUE, "level_0" => TRUE);
|
60 |
+
$caps = array_merge($caps, array("access_s2member_level0" => TRUE));
|
61 |
+
$caps = (!empty($bbp_participant_caps)) ? array_merge($caps, $bbp_participant_caps) : $caps;
|
62 |
+
|
63 |
+
if(!($role = get_role("subscriber")))
|
64 |
{
|
65 |
+
add_role("subscriber", "Subscriber");
|
66 |
+
$role = get_role("subscriber");
|
67 |
}
|
68 |
+
foreach(array_keys($caps) as $cap)
|
69 |
+
$role->add_cap($cap);
|
70 |
}
|
71 |
+
for($n = 1; $n <= $GLOBALS["WS_PLUGIN__"]["s2member"]["c"]["levels"]; $n++)
|
72 |
+
{
|
73 |
+
for($i = 0, $caps = array("read" => TRUE, "level_0" => TRUE); $i <= $n; $i++)
|
74 |
+
$caps = array_merge($caps, array("access_s2member_level".$i => TRUE));
|
75 |
+
$caps = (!empty($bbp_participant_caps)) ? array_merge($caps, $bbp_participant_caps) : $caps;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
76 |
|
77 |
+
if(!($role = get_role("s2member_level".$n)))
|
78 |
+
{
|
79 |
+
add_role("s2member_level".$n, "s2Member Level ".$n);
|
80 |
+
$role = get_role("s2member_level".$n);
|
81 |
+
}
|
82 |
+
foreach(array_keys($caps) as $cap)
|
83 |
+
$role->add_cap($cap);
|
84 |
+
}
|
85 |
+
$full_access_roles = array("administrator", "editor", "author", "contributor");
|
86 |
|
87 |
+
if(function_exists("bbp_get_caps_for_role") && !function_exists("bbp_get_dynamic_roles") /* bbPress < v2.2 integration. */)
|
88 |
+
$full_access_roles = array_merge($full_access_roles, (array)bbp_get_moderator_role());
|
89 |
|
90 |
+
foreach($full_access_roles as $role)
|
91 |
+
{
|
92 |
+
if(($role = get_role($role)))
|
93 |
+
for($n = 0; $n <= $GLOBALS["WS_PLUGIN__"]["s2member"]["c"]["levels"]; $n++)
|
94 |
+
$role->add_cap("access_s2member_level".$n);
|
95 |
+
}
|
96 |
+
}
|
97 |
+
do_action("ws_plugin__s2member_after_config_roles", get_defined_vars());
|
98 |
+
}
|
99 |
+
|
100 |
+
/**
|
101 |
+
* Adds support for bbPress v2.2+ dynamic roles.
|
102 |
+
*
|
103 |
+
* @package s2Member\Roles_Caps
|
104 |
+
* @since 112512
|
105 |
+
*
|
106 |
+
* @attaches-to ``add_filter("bbp_get_caps_for_role");``
|
107 |
+
*
|
108 |
+
* @return array
|
109 |
+
*/
|
110 |
+
public static function bbp_dynamic_role_caps($caps = FALSE, $role = FALSE)
|
111 |
+
{
|
112 |
+
if(function_exists("bbp_get_dynamic_roles") && $role !== bbp_get_blocked_role())
|
113 |
+
if(!did_action("bbp_deactivation") && !did_action("bbp_uninstall"))
|
114 |
+
{
|
115 |
+
$caps = array_merge($caps, array("read" => TRUE, "level_0" => TRUE));
|
116 |
+
$caps = array_merge($caps, array("access_s2member_level0" => TRUE));
|
117 |
|
118 |
+
if(in_array($role, array(bbp_get_keymaster_role(), bbp_get_moderator_role()), TRUE))
|
119 |
{
|
120 |
+
for($n = 0; $n <= $GLOBALS["WS_PLUGIN__"]["s2member"]["c"]["levels"]; $n++)
|
121 |
+
$caps = array_merge($caps, array("access_s2member_level".$n => TRUE));
|
|
|
122 |
}
|
123 |
}
|
124 |
+
return $caps;
|
125 |
+
}
|
126 |
+
|
127 |
+
/**
|
128 |
+
* Unlinks Roles/Capabilities.
|
129 |
+
*
|
130 |
+
* @package s2Member\Roles_Caps
|
131 |
+
* @since 110524RC
|
132 |
+
*
|
133 |
+
* @return null
|
134 |
+
*/
|
135 |
+
public static function unlink_roles()
|
136 |
+
{
|
137 |
+
do_action("ws_plugin__s2member_before_unlink_roles", get_defined_vars());
|
138 |
+
|
139 |
+
if(!apply_filters("ws_plugin__s2member_lock_roles_caps", FALSE))
|
140 |
+
{
|
141 |
+
if(($role = get_role("subscriber")))
|
142 |
+
$role->remove_cap("access_s2member_level0");
|
143 |
+
|
144 |
+
for($n = 1; $n <= $GLOBALS["WS_PLUGIN__"]["s2member"]["c"]["max_levels"]; $n++)
|
145 |
+
remove_role("s2member_level".$n);
|
146 |
+
|
147 |
+
$full_access_roles = array("administrator", "editor", "author", "contributor");
|
148 |
+
|
149 |
+
if(function_exists("bbp_get_caps_for_role") && !function_exists("bbp_get_dynamic_roles") /* bbPress < v2.2 integration. */)
|
150 |
+
$full_access_roles = array_merge($full_access_roles, (array)bbp_get_moderator_role());
|
151 |
+
|
152 |
+
foreach($full_access_roles as $role)
|
153 |
+
{
|
154 |
+
if(($role = get_role($role)))
|
155 |
+
for($n = 0; $n <= $GLOBALS["WS_PLUGIN__"]["s2member"]["c"]["max_levels"]; $n++)
|
156 |
+
$role->remove_cap("access_s2member_level".$n);
|
157 |
+
}
|
158 |
+
}
|
159 |
+
do_action("ws_plugin__s2member_after_unlink_roles", get_defined_vars());
|
160 |
+
}
|
161 |
+
|
162 |
+
/**
|
163 |
+
* Updates Roles/Capabilities via AJAX.
|
164 |
+
*
|
165 |
+
* @package s2Member\Roles_Caps
|
166 |
+
* @since 110524RC
|
167 |
+
*
|
168 |
+
* @attaches-to ``add_action("wp_ajax_ws_plugin__s2member_update_roles_via_ajax");``
|
169 |
+
*
|
170 |
+
* @return null Exits script execution after output for AJAX caller.
|
171 |
+
*/
|
172 |
+
public static function update_roles_via_ajax()
|
173 |
+
{
|
174 |
+
do_action("ws_plugin__s2member_before_update_roles_via_ajax", get_defined_vars());
|
175 |
+
|
176 |
+
status_header(200); // Send a 200 OK status header.
|
177 |
+
header("Content-Type: text/plain; charset=UTF-8"); // Content-Type with UTF-8.
|
178 |
+
while(@ob_end_clean()) ; // Clean any existing output buffers.
|
179 |
+
|
180 |
+
if(current_user_can("create_users")) // Check privileges. Ability to create Users?
|
181 |
+
|
182 |
+
if(!empty($_POST["ws_plugin__s2member_update_roles_via_ajax"]))
|
183 |
+
if(($nonce = $_POST["ws_plugin__s2member_update_roles_via_ajax"]))
|
184 |
+
if(wp_verify_nonce($nonce, "ws-plugin--s2member-update-roles-via-ajax"))
|
185 |
+
|
186 |
+
if(!apply_filters("ws_plugin__s2member_lock_roles_caps", FALSE))
|
187 |
+
{
|
188 |
+
c_ws_plugin__s2member_roles_caps::config_roles();
|
189 |
+
$success = TRUE; // Roles updated.
|
190 |
+
}
|
191 |
+
else // Else flag as having been locked here.
|
192 |
+
$locked = TRUE;
|
193 |
|
194 |
+
exit(apply_filters("ws_plugin__s2member_update_roles_via_ajax", // Also handle ``$locked`` here.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
195 |
((isset($success) && $success) ? "1" : ((isset($locked) && $locked) ? "l" : "0")), get_defined_vars()));
|
196 |
+
}
|
197 |
+
}
|
198 |
}
|
199 |
?>
|
includes/classes/users-list.inc.php
CHANGED
@@ -210,7 +210,7 @@ if (!class_exists ("c_ws_plugin__s2member_users_list"))
|
|
210 |
$val = (!empty ($ccaps)) ? implode ("<br />", $ccaps) : "—";
|
211 |
}
|
212 |
else if($col === "s2member_auto_eot_time")
|
213 |
-
$val = ($v = get_user_option ("s2member_auto_eot_time", $user_id)) ?
|
214 |
|
215 |
else if (preg_match ("/^s2member_custom_field_/", $col))
|
216 |
{
|
210 |
$val = (!empty ($ccaps)) ? implode ("<br />", $ccaps) : "—";
|
211 |
}
|
212 |
else if($col === "s2member_auto_eot_time")
|
213 |
+
$val = ($v = get_user_option ("s2member_auto_eot_time", $user_id)) ? date("D M jS, Y", (integer)$v) . "<br /><small>@ precisely " . date ("g:i a", (integer)$v)."</small>" : "—";
|
214 |
|
215 |
else if (preg_match ("/^s2member_custom_field_/", $col))
|
216 |
{
|
includes/codes.inc.php
CHANGED
@@ -1,42 +1,42 @@
|
|
1 |
<?php
|
2 |
/**
|
3 |
-
* Shortcodes for the s2Member plugin.
|
4 |
-
*
|
5 |
-
* Copyright: © 2009-2011
|
6 |
-
* {@link http://www.websharks-inc.com/ WebSharks, Inc.}
|
7 |
-
* (coded in the USA)
|
8 |
-
*
|
9 |
-
* Released under the terms of the GNU General Public License.
|
10 |
-
* You should have received a copy of the GNU General Public License,
|
11 |
-
* along with this software. In the main directory, see: /licensing/
|
12 |
-
* If not, see: {@link http://www.gnu.org/licenses/}.
|
13 |
-
*
|
14 |
-
* @package s2Member
|
15 |
-
* @since 3.0
|
16 |
-
*/
|
17 |
-
if
|
18 |
exit ("Do not access this file directly.");
|
19 |
/*
|
20 |
Add WordPress Editor Shortcodes.
|
21 |
*/
|
22 |
-
add_shortcode
|
23 |
-
add_shortcode
|
24 |
-
add_shortcode
|
25 |
-
add_shortcode
|
26 |
|
27 |
-
add_shortcode
|
28 |
-
add_shortcode
|
29 |
-
add_shortcode
|
30 |
-
add_shortcode
|
31 |
-
add_shortcode
|
32 |
-
add_shortcode
|
33 |
-
add_shortcode
|
34 |
-
add_shortcode
|
35 |
-
add_shortcode
|
36 |
-
add_shortcode
|
37 |
-
add_shortcode
|
38 |
|
39 |
-
add_shortcode
|
40 |
-
add_shortcode
|
41 |
-
add_shortcode
|
42 |
?>
|
1 |
<?php
|
2 |
/**
|
3 |
+
* Shortcodes for the s2Member plugin.
|
4 |
+
*
|
5 |
+
* Copyright: © 2009-2011
|
6 |
+
* {@link http://www.websharks-inc.com/ WebSharks, Inc.}
|
7 |
+
* (coded in the USA)
|
8 |
+
*
|
9 |
+
* Released under the terms of the GNU General Public License.
|
10 |
+
* You should have received a copy of the GNU General Public License,
|
11 |
+
* along with this software. In the main directory, see: /licensing/
|
12 |
+
* If not, see: {@link http://www.gnu.org/licenses/}.
|
13 |
+
*
|
14 |
+
* @package s2Member
|
15 |
+
* @since 3.0
|
16 |
+
*/
|
17 |
+
if(realpath(__FILE__) === realpath($_SERVER["SCRIPT_FILENAME"]))
|
18 |
exit ("Do not access this file directly.");
|
19 |
/*
|
20 |
Add WordPress Editor Shortcodes.
|
21 |
*/
|
22 |
+
add_shortcode("s2Key", "c_ws_plugin__s2member_sc_keys::sc_get_key");
|
23 |
+
add_shortcode("s2Get", "c_ws_plugin__s2member_sc_gets::sc_get_details");
|
24 |
+
add_shortcode("s2File", "c_ws_plugin__s2member_sc_files::sc_get_file");
|
25 |
+
add_shortcode("s2Stream", "c_ws_plugin__s2member_sc_files::sc_get_stream");
|
26 |
|
27 |
+
add_shortcode("s2If", "c_ws_plugin__s2member_sc_if_conds::sc_if_conditionals");
|
28 |
+
add_shortcode("_s2If", "c_ws_plugin__s2member_sc_if_conds::sc_if_conditionals");
|
29 |
+
add_shortcode("__s2If", "c_ws_plugin__s2member_sc_if_conds::sc_if_conditionals");
|
30 |
+
add_shortcode("___s2If", "c_ws_plugin__s2member_sc_if_conds::sc_if_conditionals");
|
31 |
+
add_shortcode("____s2If", "c_ws_plugin__s2member_sc_if_conds::sc_if_conditionals");
|
32 |
+
add_shortcode("_____s2If", "c_ws_plugin__s2member_sc_if_conds::sc_if_conditionals");
|
33 |
+
add_shortcode("______s2If", "c_ws_plugin__s2member_sc_if_conds::sc_if_conditionals");
|
34 |
+
add_shortcode("_______s2If", "c_ws_plugin__s2member_sc_if_conds::sc_if_conditionals");
|
35 |
+
add_shortcode("________s2If", "c_ws_plugin__s2member_sc_if_conds::sc_if_conditionals");
|
36 |
+
add_shortcode("_________s2If", "c_ws_plugin__s2member_sc_if_conds::sc_if_conditionals");
|
37 |
+
add_shortcode("__________s2If", "c_ws_plugin__s2member_sc_if_conds::sc_if_conditionals");
|
38 |
|
39 |
+
add_shortcode("s2Member-Profile", "c_ws_plugin__s2member_sc_profile::sc_profile");
|
40 |
+
add_shortcode("s2Member-PayPal-Button", "c_ws_plugin__s2member_sc_paypal_button::sc_paypal_button");
|
41 |
+
add_shortcode("s2Member-Security-Badge", "c_ws_plugin__s2member_sc_s_badge::sc_s_badge");
|
42 |
?>
|
includes/hooks.inc.php
CHANGED
@@ -181,6 +181,8 @@ add_filter("bbp_get_caps_for_role", "c_ws_plugin__s2member_roles_caps::bbp_dynam
|
|
181 |
add_action("bbp_activation", "c_ws_plugin__s2member_roles_caps::config_roles", 11);
|
182 |
|
183 |
add_action("http_api_debug", "c_ws_plugin__s2member_utils_logs::http_api_debug", 1000, 5);
|
|
|
|
|
184 |
/*
|
185 |
Register the activation | de-activation routines.
|
186 |
*/
|
181 |
add_action("bbp_activation", "c_ws_plugin__s2member_roles_caps::config_roles", 11);
|
182 |
|
183 |
add_action("http_api_debug", "c_ws_plugin__s2member_utils_logs::http_api_debug", 1000, 5);
|
184 |
+
|
185 |
+
add_action("plugins_loaded", "c_ws_plugin__s2member_mo_page::back_compat_mop_vars", -(PHP_INT_MAX - 10));
|
186 |
/*
|
187 |
Register the activation | de-activation routines.
|
188 |
*/
|
includes/menu-pages/code-samples/api-mop-vars-e.x-php
CHANGED
@@ -1,60 +1,7 @@
|
|
1 |
<?php
|
2 |
-
|
|
|
|
|
3 |
|
4 |
-
$
|
5 |
-
|
6 |
-
// ------------------------------------------------------------------------------------
|
7 |
-
|
8 |
-
if (isset ($_g["_s2member_seeking"]["type"]) /* One of: page|post|catg|ptag|file|ruri */ )
|
9 |
-
echo 'You were trying to access a protected: ' . esc_html ($_g["_s2member_seeking"]["type"]) . '.';
|
10 |
-
|
11 |
-
// ---------------------------------------------------------------
|
12 |
-
|
13 |
-
if (isset ($_g["_s2member_seeking"]["page"]))
|
14 |
-
echo 'You were trying to access Page ID #' . esc_html ($_g["_s2member_seeking"]["page"]) . '.';
|
15 |
-
|
16 |
-
else if (isset ($_g["_s2member_seeking"]["post"]))
|
17 |
-
echo 'You were trying to access Post ID #' . esc_html ($_g["_s2member_seeking"]["post"]) . '.';
|
18 |
-
|
19 |
-
else if (isset ($_g["_s2member_seeking"]["catg"]))
|
20 |
-
echo 'You were trying to access Category ID #' . esc_html ($_g["_s2member_seeking"]["catg"]) . '.';
|
21 |
-
|
22 |
-
else if (isset ($_g["_s2member_seeking"]["ptag"]))
|
23 |
-
echo 'You were trying to access the Tag ID #' . esc_html ($_g["_s2member_seeking"]["ptag"]) . '.';
|
24 |
-
|
25 |
-
else if (isset ($_g["_s2member_seeking"]["file"]))
|
26 |
-
echo 'You were trying to access the File: ' . esc_html ($_g["_s2member_seeking"]["file"]) . '.';
|
27 |
-
|
28 |
-
else if (isset ($_g["_s2member_seeking"]["ruri"]) /* Full URI they were trying to access. */)
|
29 |
-
echo 'You were trying to access URI: ' . esc_html (base64_decode ($_g["_s2member_seeking"]["ruri"])) . '.';
|
30 |
-
// See also: <http://codex.wordpress.org/Function_Reference/site_url>.
|
31 |
-
// See also: <http://php.net/manual/en/function.base64-decode.php>.
|
32 |
-
|
33 |
-
// ---------------------------------------------------------------
|
34 |
-
|
35 |
-
if (isset ($_g["_s2member_seeking"]["_uri"]) /* Full URI they were trying to access. */ )
|
36 |
-
echo 'You were trying to access URL: ' . esc_html (site_url(base64_decode($_g["_s2member_seeking"]["_uri"]))) . '.';
|
37 |
-
// See also: <http://codex.wordpress.org/Function_Reference/site_url>.
|
38 |
-
// See also: <http://php.net/manual/en/function.base64-decode.php>.
|
39 |
-
|
40 |
-
// ------------------------------------------------------------------------------------
|
41 |
-
|
42 |
-
if (isset ($_g["_s2member_req"]["type"]) /* One of: level|ccap|sp */)
|
43 |
-
echo 'You were trying to access content that requires: ' . esc_html ($_g["_s2member_req"]["type"]) . '.';
|
44 |
-
|
45 |
-
// ---------------------------------------------------------------
|
46 |
-
|
47 |
-
if (isset ($_g["_s2member_req"]["level"]))
|
48 |
-
echo 'You must be a Member at Level #' . esc_html ($_g["_s2member_req"]["level"]) . ' or higher.';
|
49 |
-
|
50 |
-
else if (isset ($_g["_s2member_req"]["ccap"]))
|
51 |
-
echo 'You must be a Member with Custom Capability: ' . esc_html ($_g["_s2member_req"]["ccap"]) . '.';
|
52 |
-
|
53 |
-
else if (isset ($_g["_s2member_req"]["sp"]))
|
54 |
-
echo 'You must purchase Specific Post/Page ID #' . esc_html ($_g["_s2member_req"]["sp"]) . '.';
|
55 |
-
|
56 |
-
// ------------------------------------------------------------------------------------
|
57 |
-
|
58 |
-
if (isset ($_g["_s2member_res"]["type"]) /* One of: post|page|catg|ptag|file|ruri|ccap|sp|sys */)
|
59 |
-
echo 'You were trying to access content protected via s2Member: ' . esc_html ($_g["_s2member_res"]["type"]) . ' restrictions.';
|
60 |
-
?>
|
1 |
<?php
|
2 |
+
if(!empty($_REQUEST["_s2member_vars"]))
|
3 |
+
@list($restriction_type, $requirement_type, $requirement_type_value, $seeking_type, $seeking_type_value, $seeking_uri)
|
4 |
+
= explode(".", stripslashes((string)$_REQUEST["_s2member_vars"]));
|
5 |
|
6 |
+
if (!empty($seeking_type) /* One of: page|post|catg|ptag|file|ruri */ )
|
7 |
+
echo 'You were trying to access a protected: ' . esc_html($seeking_type) . '.';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/menu-pages/code-samples/api-mop-vars-o.x-php
CHANGED
@@ -1,34 +1,59 @@
|
|
|
|
|
|
|
|
|
|
1 |
-----------------------------------------------------------------------------------------------------------
|
2 |
-
|
3 |
-----------------------------------------------------------------------------------------------------------
|
4 |
|
5 |
-
.../membership-options-page/?
|
6 |
-
.../membership-options-page/?
|
7 |
-
.../membership-options-page/?
|
8 |
-
.../membership-options-page/?
|
9 |
-
.../membership-options-page/?
|
10 |
-
.../membership-options-page/?
|
11 |
-
.../membership-options-page/?
|
12 |
-
.../membership-options-page/?
|
13 |
-
.../membership-options-page/?
|
14 |
-
.../membership-options-page/?
|
15 |
|
16 |
-----------------------------------------------------------------------------------------------------------
|
17 |
|
18 |
Here is a breakdown on each of these Variables:
|
19 |
|
20 |
-
* `
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
* `
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
27 |
|
28 |
-
`
|
29 |
-
|
30 |
-
|
|
|
|
|
|
|
31 |
|
32 |
-----------------------------------------------------------------------------------------------------------
|
33 |
|
34 |
-
*
|
1 |
+
NOTE: While these old variables no longer appear in the URL,
|
2 |
+
s2Member will create the following variables (internally) for backward compatibility
|
3 |
+
with older versions of the software.
|
4 |
+
|
5 |
-----------------------------------------------------------------------------------------------------------
|
6 |
+
Example redirection links, including many of the possible MOP Variable variations.
|
7 |
-----------------------------------------------------------------------------------------------------------
|
8 |
|
9 |
+
.../membership-options-page/?_s2member_seeking[post]=369&_s2member_req[sp]=369
|
10 |
+
.../membership-options-page/?_s2member_seeking[page]=559&_s2member_req[sp]=559
|
11 |
+
.../membership-options-page/?_s2member_seeking[page]=587&_s2member_req[level]=1
|
12 |
+
.../membership-options-page/?_s2member_seeking[post]=545&_s2member_req[level]=2
|
13 |
+
.../membership-options-page/?_s2member_seeking[catg]=698&_s2member_req[level]=4
|
14 |
+
.../membership-options-page/?_s2member_seeking[ptag]=447&_s2member_req[level]=3
|
15 |
+
.../membership-options-page/?_s2member_seeking[page]=887&_s2member_req[ccap]=music
|
16 |
+
.../membership-options-page/?_s2member_seeking[post]=871&_s2member_req[ccap]=videos
|
17 |
+
.../membership-options-page/?_s2member_seeking[file]=example.zip&_s2member_req[level]=1
|
18 |
+
.../membership-options-page/?_s2member_seeking[ruri]=aHR0cDov...&_s2member_req[level]=1
|
19 |
|
20 |
-----------------------------------------------------------------------------------------------------------
|
21 |
|
22 |
Here is a breakdown on each of these Variables:
|
23 |
|
24 |
+
* `_s2member_seeking[post|page|catg|ptag|file|ruri]` = (Post ID, Page ID, Category ID, Tag ID, File, URI)
|
25 |
+
Tip: `_s2member_seeking[file]` = (File path, relative to /s2member-files/, or your Amazon® S3 Bucket)
|
26 |
+
Tip: `_s2member_seeking[ruri]` = (A base 64 encoded URI; only applies w/ Membership URI Restrictions)
|
27 |
+
Tip: These array elements are mutually exclusive: [post|page|catg|ptag|file|ruri].
|
28 |
+
Only ONE of these array elements (i.e. Content Types) will be specified.
|
29 |
+
|
30 |
+
* `_s2member_req[level]` = a Membership Level # required for access (only applies to Membership Level Access)
|
31 |
+
* `_s2member_req[ccap]` = a Custom Capability required for access (only applies to Custom Capability Restrictions)
|
32 |
+
* `_s2member_req[sp]` = a Specific Post/Page ID required (only applies to Specific Post/Page Access Restrictions)
|
33 |
+
Tip: `_s2member_req[level|ccap|sp]` are mutually exclusive Requirement Types.
|
34 |
+
Only ONE of these three elements will be passed in combination with:
|
35 |
+
`_s2member_seeking[post|page|catg|ptag|file|ruri]`.
|
36 |
+
|
37 |
+
-----------------------------------------------------------------------------------------------------------
|
38 |
+
|
39 |
+
Additional Variables that might be useful to developers:
|
40 |
+
|
41 |
+
* `_s2member_seeking[_uri]` = (A base 64 encoded URI; the URI they were originally seeking)
|
42 |
+
Tip: this is ALWAYS passed through, regardless of which Content Type was protected.
|
43 |
+
|
44 |
+
* `_s2member_seeking[type]` = (A string. One of: post|page|catg|ptag|file|ruri)
|
45 |
+
Tip: this is ALWAYS passed through, regardless of which Content Type was protected.
|
46 |
+
|
47 |
+
* `_s2member_req[type]` = (A string. One of: level|ccap|sp)
|
48 |
+
Tip: this Requirement Type Variable is ALWAYS passed through.
|
49 |
|
50 |
+
* `_s2member_res[type]` = (A string. One of: post|page|catg|ptag|file|ruri|ccap|sp|sys)
|
51 |
+
Tip: Actual Restriction Type that's preventing access; may differ from `_s2member_seeking[type]`.
|
52 |
+
Tip: Restriction Type `sys` Systematic (i.e. something s2Member protects automatically)
|
53 |
+
Tip: Restriction Type `ccap` represents Custom Capability Restrictions by s2Member.
|
54 |
+
Tip: Restriction Type `sp` represents Specific Post/Page Access Restrictions.
|
55 |
+
Tip: this Restriction Type Variable is ALWAYS passed through.
|
56 |
|
57 |
-----------------------------------------------------------------------------------------------------------
|
58 |
|
59 |
+
* The use of MOP Vars is 100% completely optional (for advanced site owners).
|
includes/menu-pages/code-samples/api-mop-vars-ro.x-php
ADDED
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
NOTE: While these old variables no longer appear in the URL,
|
2 |
+
s2Member will create the following variables (internally) for backward compatibility
|
3 |
+
with older versions of the software.
|
4 |
+
|
5 |
+
-----------------------------------------------------------------------------------------------------------
|
6 |
+
These example redirection links include all possible MOP Variable variations in the query string.
|
7 |
+
-----------------------------------------------------------------------------------------------------------
|
8 |
+
|
9 |
+
.../membership-options-page/?s2member_seeking=page-587&s2member_level_req=1
|
10 |
+
.../membership-options-page/?s2member_seeking=post-545&s2member_level_req=2
|
11 |
+
.../membership-options-page/?s2member_seeking=catg-698&s2member_level_req=4
|
12 |
+
.../membership-options-page/?s2member_seeking=ptag-447&s2member_level_req=3
|
13 |
+
.../membership-options-page/?s2member_seeking=page-887&s2member_ccap_req=music
|
14 |
+
.../membership-options-page/?s2member_seeking=post-871&s2member_ccap_req=videos
|
15 |
+
.../membership-options-page/?s2member_seeking=post-369&s2member_sp_req=369
|
16 |
+
.../membership-options-page/?s2member_seeking=bbpress&s2member_level_req=1
|
17 |
+
.../membership-options-page/?s2member_seeking=ruri-aHR0cDovL3d3dy5leGFtcGxlLmNvbS8&s2member_level_req=1
|
18 |
+
.../membership-options-page/?s2member_seeking=file-example.zip&s2member_level_req=1
|
19 |
+
|
20 |
+
-----------------------------------------------------------------------------------------------------------
|
21 |
+
|
22 |
+
Here is a breakdown on each of these Variables:
|
23 |
+
|
24 |
+
* `s2member_seeking` = [post|page|catg|ptag]-[ID number] (Post ID, Page ID, Category ID, Tag ID)
|
25 |
+
Or: `s2member_seeking` = ruri-[base64 encoded URI] (only applies w/ Membership URI Restrictions)
|
26 |
+
Or: `s2member_seeking` = file-[protected file name] (only applies w/ Download Restrictions)
|
27 |
+
Or: `s2member_seeking` = bbpress (only applies when the s2Member -› bbPress Bridge is installed)
|
28 |
+
* `s2member_level_req` = a Membership Level # required for access (only applies to Membership Level Access)
|
29 |
+
* `s2member_ccap_req` = a Custom Capability required for access (only applies to Custom Capability Restrictions)
|
30 |
+
* `s2member_sp_req` = a Specific Post/Page ID required (only applies to Specific Post/Page Access Restrictions)
|
31 |
+
|
32 |
+
`s2member_seeking` is always passed in; it is never excluded.
|
33 |
+
`s2member_level_req`, `s2member_ccap_req`, `s2member_sp_req` are mutually exclusive.
|
34 |
+
Only ONE of these three Variables will be passed in combination with `s2member_seeking`.
|
35 |
+
|
36 |
+
-----------------------------------------------------------------------------------------------------------
|
37 |
+
|
38 |
+
* These old MOP Vars are deprecated (they will NOT be available in future versions of s2Member).
|
includes/menu-pages/code-samples/api-mop-vars.x-php
CHANGED
@@ -1,54 +1,55 @@
|
|
1 |
-----------------------------------------------------------------------------------------------------------
|
2 |
-
Example redirection
|
3 |
-----------------------------------------------------------------------------------------------------------
|
4 |
|
5 |
-
|
6 |
-
.../membership-options-page/?_s2member_seeking[page]=559&_s2member_req[sp]=559
|
7 |
-
.../membership-options-page/?_s2member_seeking[page]=587&_s2member_req[level]=1
|
8 |
-
.../membership-options-page/?_s2member_seeking[post]=545&_s2member_req[level]=2
|
9 |
-
.../membership-options-page/?_s2member_seeking[catg]=698&_s2member_req[level]=4
|
10 |
-
.../membership-options-page/?_s2member_seeking[ptag]=447&_s2member_req[level]=3
|
11 |
-
.../membership-options-page/?_s2member_seeking[page]=887&_s2member_req[ccap]=music
|
12 |
-
.../membership-options-page/?_s2member_seeking[post]=871&_s2member_req[ccap]=videos
|
13 |
-
.../membership-options-page/?_s2member_seeking[file]=example.zip&_s2member_req[level]=1
|
14 |
-
.../membership-options-page/?_s2member_seeking[ruri]=aHR0cDov...&_s2member_req[level]=1
|
15 |
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
* `_s2member_seeking[post|page|catg|ptag|file|ruri]` = (Post ID, Page ID, Category ID, Tag ID, File, URI)
|
21 |
-
Tip: `_s2member_seeking[file]` = (File path, relative to /s2member-files/, or your Amazon® S3 Bucket)
|
22 |
-
Tip: `_s2member_seeking[ruri]` = (A base 64 encoded URI; only applies w/ Membership URI Restrictions)
|
23 |
-
Tip: These array elements are mutually exclusive: [post|page|catg|ptag|file|ruri].
|
24 |
-
Only ONE of these array elements (i.e. Content Types) will be specified.
|
25 |
-
|
26 |
-
* `_s2member_req[level]` = a Membership Level # required for access (only applies to Membership Level Access)
|
27 |
-
* `_s2member_req[ccap]` = a Custom Capability required for access (only applies to Custom Capability Restrictions)
|
28 |
-
* `_s2member_req[sp]` = a Specific Post/Page ID required (only applies to Specific Post/Page Access Restrictions)
|
29 |
-
Tip: `_s2member_req[level|ccap|sp]` are mutually exclusive Requirement Types.
|
30 |
-
Only ONE of these three elements will be passed in combination with:
|
31 |
-
`_s2member_seeking[post|page|catg|ptag|file|ruri]`.
|
32 |
|
33 |
-----------------------------------------------------------------------------------------------------------
|
34 |
|
35 |
-
|
36 |
-
|
37 |
-
* `
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
52 |
|
53 |
-----------------------------------------------------------------------------------------------------------
|
54 |
|
1 |
-----------------------------------------------------------------------------------------------------------
|
2 |
+
Example redirection link with MOP Vars, in psuedo code:
|
3 |
-----------------------------------------------------------------------------------------------------------
|
4 |
|
5 |
+
s2Member's MOP Vars are now a dot (`.`) delimited list of six values.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
6 |
|
7 |
+
.../membership-options-page/
|
8 |
+
?_s2member_vars=[restriction type].[requirement type].[requirement type value].
|
9 |
+
[seeking type].[seeking type value].[seeking URI base 64 encoded]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
10 |
|
11 |
-----------------------------------------------------------------------------------------------------------
|
12 |
|
13 |
+
Here is a breakdown that explains each of the values:
|
14 |
+
|
15 |
+
* `[restriction type]` = A string. One of: `post|page|catg|ptag|file|ruri|ccap|sp|sys`
|
16 |
+
- The s2Member Restriction Type you've configured which is preventing access.
|
17 |
+
- Restriction Type `post` indicates that Post Access Restrictions triggered the redirection.
|
18 |
+
- Restriction Type `page` indicates that Page Access Restrictions triggered the redirection.
|
19 |
+
- Restriction Type `catg` indicates that Category Access Restrictions triggered the redirection.
|
20 |
+
- Restriction Type `ptag` indicates that Post Tag Access Restrictions triggered the redirection.
|
21 |
+
- Restriction Type `file` indicates that File Access Restrictions triggered the redirection.
|
22 |
+
- Restriction Type `ruri` indicates that Request URI Access Restrictions triggered the redirection.
|
23 |
+
- Restriction Type `ccap` indicates Custom Capability Restrictions triggered the redirection.
|
24 |
+
- Restriction Type `sp` indicates Specific Post/Page Access Restrictions triggered the redirection.
|
25 |
+
- Restriction Type `sys` indicates Systematic (i.e. something s2Member protects automatically).
|
26 |
+
|
27 |
+
* `[requirement type]` = A string. One of: `level|ccap|sp`
|
28 |
+
- Requirement Type `level` indicates that a Membership Level is required for access.
|
29 |
+
- Requirement Type `ccap` indicates that a Custom Capability is required for access.
|
30 |
+
- Requirement Type `sp` indicates that a Specific Post/Page purchase is required for access.
|
31 |
+
|
32 |
+
* `[requirement type value]` = A string. The Level, CCAP or Specific Post/Page ID required for access.
|
33 |
+
- This value correlates with `[requirement type]` to supply more specific information.
|
34 |
+
For instance, if `[requirement type]` is `level`, `[requirement type value]`
|
35 |
+
might be `1` to indicate that Level `1` is required for access.
|
36 |
+
- In the case of a CCAP, this will be set to the CCAP required for access.
|
37 |
+
- In the case of a Specific Post/Page, this is set to the Post/Page ID in WordPress.
|
38 |
+
|
39 |
+
* `[seeking type]` = A string. One of: `post|page|catg|ptag|file|ruri`
|
40 |
+
- This identifies the type of content a visitor was attempting to access.
|
41 |
+
A Post (`post`), Page (`page`), Category (`catg`), Post Tag (`ptag`), File (`file`),
|
42 |
+
or a Request URI (`ruri`) to indicate something that doesn't fall into any other classification.
|
43 |
+
|
44 |
+
* `[seeking type value]` = A string. A Post ID, Page ID, Category ID, Post Tag ID, File, or Request URI.
|
45 |
+
- This correlates with `[seeking type]` to supply more specific information.
|
46 |
+
For instance, if `[seeking type]` is `post`, this might be `123` to indicate the
|
47 |
+
visitor was attempting to access Post ID `123` in WordPress.
|
48 |
+
- File paths are relative to `/s2member-files/`, or your Amazon® S3 Bucket.
|
49 |
+
- Request URIs are base 64 encoded. Use PHP's `base64_decode()` to decode the value.
|
50 |
+
|
51 |
+
* `[seeking URI; base 64 encoded]` = A string. Base 64 encoded URI that a visitor was attempting to access.
|
52 |
+
- Request URIs are base 64 encoded. Use PHP's `base64_decode()` to decode the value.
|
53 |
|
54 |
-----------------------------------------------------------------------------------------------------------
|
55 |
|
includes/menu-pages/gen-ops.inc.php
CHANGED
@@ -1,1488 +1,1516 @@
|
|
1 |
<?php
|
2 |
/**
|
3 |
-
* Menu page for the s2Member plugin (General Options page).
|
4 |
-
*
|
5 |
-
* Copyright: © 2009-2011
|
6 |
-
* {@link http://www.websharks-inc.com/ WebSharks, Inc.}
|
7 |
-
* (coded in the USA)
|
8 |
-
*
|
9 |
-
* Released under the terms of the GNU General Public License.
|
10 |
-
* You should have received a copy of the GNU General Public License,
|
11 |
-
* along with this software. In the main directory, see: /licensing/
|
12 |
-
* If not, see: {@link http://www.gnu.org/licenses/}.
|
13 |
-
*
|
14 |
-
* @package s2Member\Menu_Pages
|
15 |
-
* @since 3.0
|
16 |
-
*/
|
17 |
-
if
|
18 |
exit("Do not access this file directly.");
|
19 |
|
20 |
-
if
|
21 |
{
|
22 |
/**
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
class c_ws_plugin__s2member_menu_page_gen_ops
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
71 |
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
|
99 |
-
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
|
108 |
-
|
109 |
-
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
-
|
114 |
-
|
115 |
-
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
|
121 |
-
|
122 |
-
|
123 |
-
|
124 |
-
|
125 |
-
|
126 |
-
|
127 |
-
|
128 |
-
|
129 |
-
|
130 |
-
|
131 |
-
|
132 |
-
|
133 |
-
|
134 |
-
|
135 |
-
|
136 |
-
|
137 |
-
|
138 |
-
|
139 |
-
|
140 |
-
|
141 |
-
|
142 |
-
|
143 |
-
|
144 |
-
|
145 |
-
|
146 |
-
|
147 |
-
|
148 |
-
|
149 |
-
|
150 |
-
|
151 |
-
|
152 |
-
|
153 |
-
|
154 |
-
|
155 |
-
|
156 |
-
|
157 |
-
|
158 |
-
|
159 |
-
|
160 |
-
|
161 |
-
|
162 |
-
|
163 |
-
|
164 |
-
|
165 |
-
|
166 |
-
|
167 |
-
|
168 |
-
|
169 |
-
|
170 |
-
|
171 |
-
|
172 |
-
|
173 |
-
|
174 |
-
|
175 |
-
|
176 |
-
|
177 |
-
|
178 |
-
|
179 |
-
|
180 |
-
|
181 |
-
|
182 |
-
|
183 |
-
|
184 |
-
|
185 |
-
|
186 |
-
|
187 |
-
|
188 |
-
|
189 |
-
|
190 |
-
|
191 |
-
|
192 |
-
|
193 |
-
|
194 |
-
|
195 |
-
|
196 |
-
|
197 |
-
|
198 |
-
|
199 |
-
|
200 |
-
|
201 |
-
|
202 |
-
|
203 |
-
|
204 |
-
|
205 |
-
|
206 |
-
|
207 |
-
|
208 |
-
|
209 |
-
|
210 |
-
|
211 |
-
|
212 |
-
|
213 |
-
|
214 |
-
|
215 |
-
|
216 |
-
|
217 |
-
|
218 |
-
|
219 |
-
|
220 |
-
|
221 |
-
|
222 |
-
|
223 |
-
|
224 |
-
|
225 |
-
|
226 |
-
|
227 |
-
|
228 |
-
|
229 |
-
|
230 |
-
|
231 |
-
|
232 |
-
|
233 |
-
|
234 |
-
|
235 |
-
|
236 |
-
|
237 |
-
|
238 |
-
|
239 |
-
|
240 |
-
|
241 |
-
|
242 |
-
|
243 |
-
|
244 |
-
|
245 |
-
|
246 |
-
|
247 |
-
|
248 |
-
|
249 |
-
|
250 |
-
|
251 |
-
|
252 |
-
|
253 |
-
|
254 |
-
|
255 |
-
|
256 |
-
|
257 |
-
|
258 |
-
|
259 |
-
|
260 |
-
|
261 |
-
|
262 |
-
|
263 |
-
|
264 |
-
|
265 |
-
|
266 |
-
|
267 |
-
|
268 |
-
|
269 |
-
|
270 |
-
|
271 |
-
|
272 |
-
|
273 |
-
|
274 |
-
|
275 |
-
|
276 |
-
|
277 |
-
|
278 |
-
|
279 |
-
|
280 |
-
|
281 |
-
|
282 |
-
|
283 |
-
|
284 |
-
|
285 |
-
|
286 |
-
|
287 |
-
|
288 |
-
|
289 |
-
|
290 |
-
|
291 |
-
|
292 |
-
|
293 |
-
|
294 |
-
|
295 |
-
|
296 |
-
|
297 |
-
|
298 |
-
|
299 |
-
|
300 |
-
|
301 |
-
|
302 |
-
|
303 |
-
|
304 |
-
|
305 |
-
|
306 |
-
|
307 |
-
|
308 |
-
|
309 |
-
|
310 |
-
|
311 |
-
|
312 |
-
|
313 |
-
|
314 |
-
|
315 |
-
|
316 |
-
|
317 |
-
|
318 |
-
|
319 |
-
|
320 |
-
|
321 |
-
|
322 |
-
|
323 |
-
|
324 |
-
|
325 |
-
|
326 |
-
|
327 |
-
|
328 |
-
|
329 |
-
|
330 |
-
|
331 |
-
|
332 |
-
|
333 |
-
|
334 |
-
|
335 |
-
|
336 |
-
|
337 |
-
|
338 |
-
|
339 |
-
|
340 |
-
|
341 |
-
|
342 |
-
|
343 |
-
|
344 |
-
|
345 |
-
|
346 |
-
|
347 |
-
|
348 |
-
|
349 |
-
|
350 |
-
|
351 |
-
|
352 |
-
|
353 |
-
|
354 |
-
|
355 |
-
|
356 |
-
|
357 |
-
|
358 |
-
|
359 |
-
|
360 |
-
|
361 |
-
|
362 |
-
|
363 |
-
|
364 |
-
|
365 |
-
|
366 |
-
|
367 |
-
|
368 |
-
|
369 |
-
|
370 |
-
|
371 |
-
|
372 |
-
|
373 |
-
|
374 |
-
|
375 |
-
|
376 |
-
|
377 |
-
|
378 |
-
|
379 |
-
|
380 |
-
|
381 |
-
|
382 |
-
|
383 |
-
|
384 |
-
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
|
390 |
-
|
391 |
-
|
392 |
-
|
393 |
-
|
394 |
-
|
395 |
-
|
396 |
-
|
397 |
-
|
398 |
-
|
399 |
-
|
400 |
-
|
401 |
-
|
402 |
-
|
403 |
-
|
404 |
-
|
405 |
-
|
406 |
-
|
407 |
-
|
408 |
-
|
409 |
-
|
410 |
-
|
411 |
-
|
412 |
-
|
413 |
-
|
414 |
-
|
415 |
-
|
416 |
-
|
417 |
-
|
418 |
-
|
419 |
-
|
420 |
-
|
421 |
-
|
422 |
-
|
423 |
-
|
424 |
-
|
425 |
-
|
426 |
-
|
427 |
-
|
428 |
-
|
429 |
-
|
430 |
-
|
431 |
-
|
432 |
-
|
433 |
-
|
434 |
-
|
435 |
-
|
436 |
-
|
437 |
-
|
438 |
-
|
439 |
-
|
440 |
-
|
441 |
-
|
442 |
-
|
443 |
-
|
444 |
-
|
445 |
-
|
446 |
-
|
447 |
-
|
448 |
-
|
449 |
-
|
450 |
-
|
451 |
-
|
452 |
-
|
453 |
-
|
454 |
-
|
455 |
-
|
456 |
-
|
457 |
-
|
458 |
-
|
459 |
-
|
460 |
-
|
461 |
-
|
462 |
-
|
463 |
-
|
464 |
-
|
465 |
-
|
466 |
-
|
467 |
-
|
468 |
-
|
469 |
-
|
470 |
-
|
471 |
-
|
472 |
-
|
473 |
-
|
474 |
-
|
475 |
-
|
476 |
-
|
477 |
-
|
478 |
-
|
479 |
-
|
480 |
-
|
481 |
-
|
482 |
-
|
483 |
-
|
484 |
-
|
485 |
-
|
486 |
-
|
487 |
-
|
488 |
-
|
489 |
-
|
490 |
-
|
491 |
-
|
492 |
-
|
493 |
-
|
494 |
-
|
495 |
-
|
496 |
-
|
497 |
-
|
498 |
-
|
499 |
-
|
500 |
-
|
501 |
-
|
502 |
-
|
503 |
-
|
504 |
-
|
505 |
-
|
506 |
-
|
507 |
-
|
508 |
-
|
509 |
-
|
510 |
-
|
511 |
-
|
512 |
-
|
513 |
-
|
514 |
-
|
515 |
-
|
516 |
-
|
517 |
-
|
518 |
-
|
519 |
-
|
520 |
-
|
521 |
-
|
522 |
-
|
523 |
-
|
524 |
-
|
525 |
-
|
526 |
-
|
527 |
-
|
528 |
-
|
529 |
-
|
530 |
-
|
531 |
-
|
532 |
-
|
533 |
-
|
534 |
-
|
535 |
-
|
536 |
-
|
537 |
-
|
538 |
-
|
539 |
-
|
540 |
-
|
541 |
-
|
542 |
-
|
543 |
-
|
544 |
-
|
545 |
-
|
546 |
-
|
547 |
-
|
548 |
-
|
549 |
-
|
550 |
-
|
551 |
-
|
552 |
-
|
553 |
-
|
554 |
-
|
555 |
-
|
556 |
-
|
557 |
-
|
558 |
-
|
559 |
-
|
560 |
-
|
561 |
-
|
562 |
-
|
563 |
-
|
564 |
-
|
565 |
-
|
566 |
-
|
567 |
-
|
568 |
-
|
569 |
-
|
570 |
-
|
571 |
-
|
572 |
-
|
573 |
-
|
574 |
-
|
575 |
-
|
576 |
-
|
577 |
-
|
578 |
-
|
579 |
-
|
580 |
-
|
581 |
-
|
582 |
-
|
583 |
-
|
584 |
-
|
585 |
-
|
586 |
-
|
587 |
-
|
588 |
-
|
589 |
-
|
590 |
-
|
591 |
-
|
592 |
-
|
593 |
-
|
594 |
-
|
595 |
-
|
596 |
-
|
597 |
-
|
598 |
-
|
599 |
-
|
600 |
-
|
601 |
-
|
602 |
-
|
603 |
-
|
604 |
-
|
605 |
-
|
606 |
-
|
607 |
-
|
608 |
-
|
609 |
-
|
610 |
-
|
611 |
-
|
612 |
-
|
613 |
-
|
614 |
-
|
615 |
-
|
616 |
-
|
617 |
-
|
618 |
-
|
619 |
-
|
620 |
-
|
621 |
-
|
622 |
-
|
623 |
-
|
624 |
-
|
625 |
-
|
626 |
-
|
627 |
-
|
628 |
-
|
629 |
-
|
630 |
-
|
631 |
-
|
632 |
-
|
633 |
-
|
634 |
|
635 |
-
|
636 |
-
|
637 |
-
|
638 |
-
|
639 |
|
640 |
-
|
641 |
-
|
642 |
|
643 |
-
|
644 |
-
|
645 |
-
|
646 |
-
|
647 |
-
|
648 |
-
|
649 |
-
|
650 |
-
|
651 |
-
|
652 |
-
|
653 |
-
|
654 |
-
|
655 |
-
|
656 |
-
|
657 |
-
|
658 |
-
|
659 |
-
|
660 |
|
661 |
-
|
662 |
-
|
663 |
-
|
664 |
-
|
665 |
-
|
666 |
-
|
667 |
-
|
668 |
-
|
669 |
|
670 |
-
|
671 |
|
672 |
-
|
673 |
-
|
674 |
|
675 |
-
|
676 |
|
677 |
-
|
678 |
|
679 |
-
|
680 |
-
|
681 |
|
682 |
-
|
683 |
-
|
684 |
-
|
685 |
|
686 |
-
|
687 |
|
688 |
-
|
689 |
-
|
690 |
-
|
691 |
-
|
692 |
-
|
693 |
-
|
694 |
|
695 |
-
|
696 |
-
|
697 |
-
|
698 |
|
699 |
-
|
700 |
-
|
701 |
-
|
702 |
-
|
703 |
-
|
704 |
-
|
705 |
-
|
706 |
|
707 |
-
|
708 |
-
|
709 |
-
|
710 |
|
711 |
-
|
712 |
|
713 |
-
|
714 |
|
715 |
-
|
716 |
-
|
717 |
-
|
718 |
|
719 |
-
|
720 |
-
|
721 |
-
|
722 |
-
|
723 |
|
724 |
-
|
725 |
-
|
726 |
|
727 |
-
|
728 |
-
|
729 |
-
|
730 |
-
|
731 |
-
|
732 |
|
733 |
-
|
734 |
-
|
735 |
|
736 |
-
|
737 |
-
|
738 |
-
|
739 |
-
|
740 |
|
741 |
-
|
742 |
-
|
743 |
-
|
744 |
-
|
745 |
-
|
746 |
-
|
747 |
-
|
748 |
-
|
749 |
-
|
750 |
-
|
751 |
-
|
752 |
-
|
753 |
-
|
754 |
-
|
755 |
-
|
756 |
-
|
757 |
-
|
758 |
-
|
759 |
-
|
760 |
-
|
761 |
-
|
762 |
-
|
763 |
-
|
764 |
-
|
765 |
-
|
766 |
-
|
767 |
-
|
768 |
-
|
769 |
-
|
770 |
-
|
771 |
-
|
772 |
-
|
773 |
-
|
774 |
-
|
775 |
-
|
776 |
-
|
777 |
-
|
778 |
-
|
779 |
-
|
780 |
-
|
781 |
-
|
782 |
-
|
783 |
-
|
784 |
-
|
785 |
-
|
786 |
-
|
787 |
-
|
788 |
-
|
789 |
-
|
790 |
-
|
791 |
-
|
792 |
-
|
793 |
-
|
794 |
-
|
795 |
-
|
796 |
-
|
797 |
-
|
798 |
-
|
799 |
-
|
800 |
-
|
801 |
-
|
802 |
-
|
803 |
-
|
804 |
-
|
805 |
-
|
806 |
-
|
807 |
-
|
808 |
-
|
809 |
-
|
810 |
-
|
811 |
-
|
812 |
-
|
813 |
-
|
814 |
-
|
815 |
-
|
816 |
-
|
817 |
-
|
818 |
-
|
819 |
-
|
820 |
-
|
821 |
-
|
822 |
-
|
823 |
-
|
824 |
-
|
825 |
-
|
826 |
-
|
827 |
-
|
828 |
-
|
829 |
-
|
830 |
-
|
831 |
-
|
832 |
-
|
833 |
-
|
834 |
-
|
835 |
-
|
836 |
-
|
837 |
-
|
838 |
-
|
839 |
-
|
840 |
-
|
841 |
-
|
842 |
-
|
843 |
-
|
844 |
-
|
845 |
-
|
846 |
-
|
847 |
-
|
848 |
-
|
849 |
-
|
850 |
-
|
851 |
-
|
852 |
-
|
853 |
-
|
854 |
-
|
855 |
-
|
856 |
-
|
857 |
-
|
858 |
-
|
859 |
-
|
860 |
-
|
861 |
-
|
862 |
-
|
863 |
-
|
864 |
-
|
865 |
-
|
866 |
-
|
867 |
-
|
868 |
-
|
869 |
-
|
870 |
-
|
871 |
-
|
872 |
-
|
873 |
-
|
874 |
-
|
875 |
-
|
876 |
-
|
877 |
-
|
878 |
-
|
879 |
-
|
880 |
-
|
881 |
-
|
882 |
-
|
883 |
-
|
884 |
-
|
885 |
-
|
886 |
-
|
887 |
-
|
888 |
-
|
889 |
-
|
890 |
-
|
891 |
-
|
892 |
-
|
893 |
-
|
894 |
-
|
895 |
-
|
896 |
-
|
897 |
-
|
898 |
-
|
899 |
-
|
900 |
-
|
901 |
-
|
902 |
-
|
903 |
-
|
904 |
-
|
905 |
-
|
906 |
-
|
907 |
-
|
908 |
-
|
909 |
-
|
910 |
-
|
911 |
-
|
912 |
-
|
913 |
-
|
914 |
-
|
915 |
-
|
916 |
-
|
917 |
-
|
918 |
-
|
919 |
-
|
920 |
-
|
921 |
-
|
922 |
-
|
923 |
-
|
924 |
-
|
925 |
-
|
926 |
-
|
927 |
-
|
928 |
-
|
929 |
-
|
930 |
-
|
931 |
-
|
932 |
-
|
933 |
-
|
934 |
-
|
935 |
-
|
936 |
-
|
937 |
-
|
938 |
-
|
939 |
-
|
940 |
-
|
941 |
-
|
942 |
-
|
943 |
-
|
944 |
-
|
945 |
-
|
946 |
-
|
947 |
-
|
948 |
-
|
949 |
-
|
950 |
-
|
951 |
-
|
952 |
-
|
953 |
-
|
954 |
-
|
955 |
-
|
956 |
-
|
957 |
-
|
958 |
-
|
959 |
-
|
960 |
-
|
961 |
-
|
962 |
-
|
963 |
-
|
964 |
-
|
965 |
-
|
966 |
-
|
967 |
-
|
968 |
-
|
969 |
-
|
970 |
-
|
971 |
-
|
972 |
-
|
973 |
-
|
974 |
-
|
975 |
-
|
976 |
-
|
977 |
-
|
978 |
-
|
979 |
-
|
980 |
-
|
981 |
-
|
982 |
-
|
983 |
-
|
984 |
-
|
985 |
-
|
986 |
-
|
987 |
-
|
988 |
-
|
989 |
-
|
990 |
-
|
991 |
-
|
992 |
-
|
993 |
-
|
994 |
-
|
995 |
-
|
996 |
-
|
997 |
-
|
998 |
-
|
999 |
-
|
1000 |
-
|
1001 |
-
|
1002 |
-
|
1003 |
-
|
1004 |
-
|
1005 |
-
|
1006 |
-
|
1007 |
-
|
1008 |
-
|
1009 |
-
|
1010 |
-
|
1011 |
-
|
1012 |
-
|
1013 |
-
|
1014 |
-
|
1015 |
-
|
1016 |
-
|
1017 |
-
|
1018 |
-
|
1019 |
-
|
1020 |
-
|
1021 |
-
|
1022 |
-
|
1023 |
-
|
1024 |
-
|
1025 |
-
|
1026 |
-
|
1027 |
-
|
1028 |
-
|
1029 |
-
|
1030 |
-
|
1031 |
-
|
1032 |
-
|
1033 |
-
|
1034 |
-
|
1035 |
-
|
1036 |
-
|
1037 |
-
|
1038 |
-
|
1039 |
-
|
1040 |
-
|
1041 |
-
|
1042 |
-
|
1043 |
-
|
1044 |
-
|
1045 |
-
|
1046 |
-
|
1047 |
-
|
1048 |
-
|
1049 |
-
|
1050 |
-
|
1051 |
-
|
1052 |
-
|
1053 |
-
|
1054 |
-
|
1055 |
-
|
1056 |
-
|
1057 |
-
|
1058 |
-
|
1059 |
-
|
1060 |
-
|
1061 |
-
|
1062 |
-
|
1063 |
-
|
1064 |
-
|
1065 |
-
|
1066 |
-
|
1067 |
-
|
1068 |
-
|
1069 |
-
|
1070 |
-
|
1071 |
-
|
1072 |
-
|
1073 |
-
|
1074 |
-
|
1075 |
-
|
1076 |
-
|
1077 |
-
|
1078 |
-
|
1079 |
-
|
1080 |
-
|
1081 |
-
|
1082 |
-
|
1083 |
-
|
1084 |
-
|
1085 |
-
|
1086 |
-
|
1087 |
-
|
1088 |
-
|
1089 |
-
|
1090 |
-
|
1091 |
-
|
1092 |
-
|
1093 |
-
|
1094 |
-
|
1095 |
-
|
1096 |
-
|
1097 |
-
|
1098 |
-
|
1099 |
-
|
1100 |
-
|
1101 |
-
|
1102 |
-
|
1103 |
-
|
1104 |
-
|
1105 |
-
|
1106 |
-
|
1107 |
-
|
1108 |
-
|
1109 |
-
|
1110 |
-
|
1111 |
-
|
1112 |
-
|
1113 |
-
|
1114 |
-
|
1115 |
-
|
1116 |
-
|
1117 |
-
|
1118 |
-
|
1119 |
-
|
1120 |
-
|
1121 |
-
|
1122 |
-
|
1123 |
-
|
1124 |
-
|
1125 |
-
|
1126 |
-
|
1127 |
-
|
1128 |
-
|
1129 |
-
|
1130 |
-
|
1131 |
-
|
1132 |
-
|
1133 |
-
|
1134 |
-
|
1135 |
-
|
1136 |
-
|
1137 |
-
|
1138 |
-
|
1139 |
-
|
1140 |
-
|
1141 |
-
|
1142 |
-
|
1143 |
-
|
1144 |
-
|
1145 |
-
|
1146 |
-
|
1147 |
-
|
1148 |
-
|
1149 |
-
|
1150 |
-
|
1151 |
-
|
1152 |
-
|
1153 |
-
|
1154 |
-
|
1155 |
-
|
1156 |
-
|
1157 |
-
|
1158 |
-
|
1159 |
-
|
1160 |
-
|
1161 |
-
|
1162 |
-
|
1163 |
-
|
1164 |
-
|
1165 |
-
|
1166 |
-
|
1167 |
-
|
1168 |
-
|
1169 |
-
|
1170 |
-
|
1171 |
-
|
1172 |
-
|
1173 |
-
|
1174 |
-
|
1175 |
-
|
1176 |
-
|
1177 |
-
|
1178 |
-
|
1179 |
-
|
1180 |
-
|
1181 |
-
|
1182 |
-
|
1183 |
-
|
1184 |
-
|
1185 |
-
|
1186 |
-
|
1187 |
-
|
1188 |
-
|
1189 |
-
|
1190 |
-
|
1191 |
-
|
1192 |
-
|
1193 |
-
|
1194 |
-
|
1195 |
-
|
1196 |
-
|
1197 |
-
|
1198 |
-
|
1199 |
-
|
1200 |
-
|
1201 |
-
|
1202 |
-
|
1203 |
-
|
1204 |
-
|
1205 |
-
|
1206 |
-
|
1207 |
-
|
1208 |
-
|
1209 |
-
|
1210 |
-
|
1211 |
-
|
1212 |
-
|
1213 |
-
|
1214 |
-
|
1215 |
-
|
1216 |
-
|
1217 |
-
|
1218 |
-
|
1219 |
-
|
1220 |
-
|
1221 |
-
|
1222 |
-
|
1223 |
-
|
1224 |
-
|
1225 |
-
|
1226 |
-
|
1227 |
-
|
1228 |
-
|
1229 |
-
|
1230 |
-
|
1231 |
-
|
1232 |
-
|
1233 |
-
|
1234 |
-
|
1235 |
-
|
1236 |
-
|
1237 |
-
|
1238 |
-
|
1239 |
-
|
1240 |
-
|
1241 |
-
|
1242 |
-
|
1243 |
-
|
1244 |
-
|
1245 |
-
|
1246 |
-
|
1247 |
-
|
1248 |
-
|
1249 |
-
|
1250 |
-
|
1251 |
-
|
1252 |
-
|
1253 |
-
|
1254 |
-
|
1255 |
-
|
1256 |
-
|
1257 |
-
|
1258 |
-
|
1259 |
-
|
1260 |
-
|
1261 |
-
|
1262 |
-
|
1263 |
-
|
1264 |
-
|
1265 |
-
|
1266 |
-
|
1267 |
-
|
1268 |
-
|
1269 |
-
|
1270 |
-
|
1271 |
-
|
1272 |
-
|
1273 |
-
|
1274 |
-
|
1275 |
-
|
1276 |
-
|
1277 |
-
|
1278 |
-
|
1279 |
-
|
1280 |
-
|
1281 |
-
|
1282 |
-
|
1283 |
-
|
1284 |
-
|
1285 |
-
|
1286 |
-
|
1287 |
-
|
1288 |
-
|
1289 |
-
|
1290 |
-
|
1291 |
-
|
1292 |
-
|
1293 |
-
|
1294 |
-
|
1295 |
-
|
1296 |
-
|
1297 |
-
|
1298 |
-
|
1299 |
-
|
1300 |
-
|
1301 |
-
|
1302 |
-
|
1303 |
-
|
1304 |
-
|
1305 |
-
|
1306 |
-
|
1307 |
-
|
1308 |
-
|
1309 |
-
|
1310 |
-
|
1311 |
-
|
1312 |
-
|
1313 |
-
|
1314 |
-
|
1315 |
-
|
1316 |
-
|
1317 |
-
|
1318 |
-
|
1319 |
-
|
1320 |
-
|
1321 |
-
|
1322 |
-
|
1323 |
-
|
1324 |
-
|
1325 |
-
|
1326 |
-
|
1327 |
-
|
1328 |
-
|
1329 |
-
|
1330 |
-
|
1331 |
-
|
1332 |
-
|
1333 |
-
|
1334 |
-
|
1335 |
-
|
1336 |
-
|
1337 |
-
|
1338 |
-
|
1339 |
-
|
1340 |
-
|
1341 |
-
|
1342 |
-
|
1343 |
-
|
1344 |
-
|
1345 |
-
|
1346 |
-
|
1347 |
-
|
1348 |
-
|
1349 |
-
|
1350 |
-
|
1351 |
-
|
1352 |
-
|
1353 |
-
|
1354 |
-
|
1355 |
-
|
1356 |
-
|
1357 |
-
|
1358 |
-
|
1359 |
-
|
1360 |
-
|
1361 |
-
|
1362 |
-
|
1363 |
-
|
1364 |
-
|
1365 |
-
|
1366 |
-
|
1367 |
-
|
1368 |
-
|
1369 |
-
|
1370 |
-
|
1371 |
-
|
1372 |
-
|
1373 |
-
|
1374 |
-
|
1375 |
-
|
1376 |
-
|
1377 |
-
|
1378 |
-
|
1379 |
-
|
1380 |
-
|
1381 |
-
|
1382 |
-
|
1383 |
-
|
1384 |
-
|
1385 |
-
|
1386 |
-
|
1387 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1388 |
|
1389 |
-
|
1390 |
-
|
1391 |
-
|
|
|
1392 |
|
1393 |
-
|
|
|
|
|
1394 |
|
1395 |
-
|
1396 |
-
echo '<p><input type="text" autocomplete="off" value="' . format_to_edit ('[s2Member-Profile /]') . '" class="monospace" onclick="this.select ();" /></p>' . "\n";
|
1397 |
|
1398 |
-
|
1399 |
-
|
1400 |
-
echo '</div>' . "\n";
|
1401 |
|
1402 |
-
|
|
|
|
|
1403 |
|
1404 |
-
|
1405 |
-
}
|
1406 |
|
1407 |
-
|
1408 |
-
|
1409 |
-
|
|
|
1410 |
|
1411 |
-
|
|
|
|
|
1412 |
|
1413 |
-
|
1414 |
-
|
1415 |
-
|
1416 |
-
|
|
|
1417 |
|
1418 |
-
|
1419 |
-
|
1420 |
-
echo '<tr>' . "\n";
|
1421 |
|
1422 |
-
|
1423 |
-
|
1424 |
-
|
1425 |
-
|
1426 |
-
|
|
|
1427 |
|
1428 |
-
|
1429 |
-
|
1430 |
|
1431 |
-
|
1432 |
-
|
1433 |
-
|
1434 |
-
|
1435 |
-
|
1436 |
-
echo '</td>' . "\n";
|
1437 |
|
1438 |
-
|
1439 |
-
|
1440 |
|
1441 |
-
|
1442 |
-
|
1443 |
-
|
1444 |
-
|
1445 |
-
echo '</th>' . "\n";
|
1446 |
|
1447 |
-
|
1448 |
-
|
|
|
|
|
1449 |
|
1450 |
-
|
1451 |
-
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_default_custom_str_url_shortener" id="ws-plugin--s2member-default-custom-str-url-shortener" value="' . format_to_edit ($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["default_custom_str_url_shortener"]) . '" /><br />' . "\n";
|
1452 |
-
echo 'Your own custom URL <code>(i.e. GET request)</code>, with <code>%%s2_long_url%%</code> Replacement Code. [ <a href="#" onclick="alert(\'s2Member makes it possible for advanced site owners to use a custom URL shortening service they prefer, over the ones currently pre-integrated with s2Member. In order for this to work, your URL shortening service MUST support basic GET requests through its API (sometimes referred to as a REST or NVP API). In addition, your URL shortening service MUST be capable of returning a simple URL in the response that s2Member receives, as a result of s2Member processing the GET request you formulate. See example below.\\n\\nBitly example GET request with format=txt:\nhttp://api.bitly.com/v3/shorten?login=demo&apiKey=2d71bf07&format=txt&longUrl=%%s2_long_url%%\\n(s2Member expects a shortened URL in the response from Bitly)\\n\\n* If you configure s2Member to use your own custom URL shortening service, s2Member will try your configuration first, and if anything fails, it will fall back on its own pre-integrated backups. When configuring your URL for the GET request, s2Member makes two Replacement Codes available:\\n\\n%%s2_long_url%% = The full URL that needs to be shortened (raw URL-encoded).\\n%%s2_long_url_md5%% = An MD5 hash of the full URL (might be useful in some APIs).\\n\\n* If you have any trouble getting your URL shortening service integrated with s2Member in this way, you might take a look at this WordPress Filter ( `ws_plugin__s2member_url_shorten` ), which s2Member makes available for advanced circumstances. Search s2Member\\\'s source code for `ws_plugin__s2member_url_shorten`.\'); return false;" tabindex="-1">click for details</a> ]<br />' . "\n";
|
1453 |
-
echo '</td>' . "\n";
|
1454 |
|
1455 |
-
|
1456 |
-
|
1457 |
-
echo '</table>' . "\n";
|
1458 |
-
echo '</div>' . "\n";
|
1459 |
|
1460 |
-
|
1461 |
|
1462 |
-
|
1463 |
-
}
|
1464 |
|
1465 |
-
|
1466 |
|
1467 |
-
|
1468 |
|
1469 |
-
|
1470 |
|
1471 |
-
|
|
|
|
|
1472 |
|
1473 |
-
|
|
|
|
|
1474 |
|
1475 |
-
|
1476 |
-
|
1477 |
-
|
1478 |
-
|
1479 |
-
echo '</tr>' . "\n";
|
1480 |
-
echo '</tbody>' . "\n";
|
1481 |
-
echo '</table>' . "\n";
|
1482 |
-
|
1483 |
-
echo '</div>' . "\n";
|
1484 |
-
}
|
1485 |
-
}
|
1486 |
}
|
1487 |
|
1488 |
new c_ws_plugin__s2member_menu_page_gen_ops ();
|
1 |
<?php
|
2 |
/**
|
3 |
+
* Menu page for the s2Member plugin (General Options page).
|
4 |
+
*
|
5 |
+
* Copyright: © 2009-2011
|
6 |
+
* {@link http://www.websharks-inc.com/ WebSharks, Inc.}
|
7 |
+
* (coded in the USA)
|
8 |
+
*
|
9 |
+
* Released under the terms of the GNU General Public License.
|
10 |
+
* You should have received a copy of the GNU General Public License,
|
11 |
+
* along with this software. In the main directory, see: /licensing/
|
12 |
+
* If not, see: {@link http://www.gnu.org/licenses/}.
|
13 |
+
*
|
14 |
+
* @package s2Member\Menu_Pages
|
15 |
+
* @since 3.0
|
16 |
+
*/
|
17 |
+
if(realpath(__FILE__) === realpath($_SERVER["SCRIPT_FILENAME"]))
|
18 |
exit("Do not access this file directly.");
|
19 |
|
20 |
+
if(!class_exists("c_ws_plugin__s2member_menu_page_gen_ops"))
|
21 |
{
|
22 |
/**
|
23 |
+
* Menu page for the s2Member plugin (General Options page).
|
24 |
+
*
|
25 |
+
* @package s2Member\Menu_Pages
|
26 |
+
* @since 110531
|
27 |
+
*/
|
28 |
class c_ws_plugin__s2member_menu_page_gen_ops
|
29 |
+
{
|
30 |
+
public function __construct()
|
31 |
+
{
|
32 |
+
echo '<div class="wrap ws-menu-page">'."\n";
|
33 |
+
|
34 |
+
echo '<div class="ws-menu-page-toolbox">'."\n";
|
35 |
+
c_ws_plugin__s2member_menu_pages_tb::display();
|
36 |
+
echo '</div>'."\n";
|
37 |
+
|
38 |
+
echo '<h2>General Options</h2>'."\n";
|
39 |
|
40 |
+
echo '<table class="ws-menu-page-table">'."\n";
|
41 |
+
echo '<tbody class="ws-menu-page-table-tbody">'."\n";
|
42 |
+
echo '<tr class="ws-menu-page-table-tr">'."\n";
|
43 |
+
echo '<td class="ws-menu-page-table-l">'."\n";
|
44 |
+
|
45 |
+
echo '<form method="post" name="ws_plugin__s2member_options_form" id="ws-plugin--s2member-options-form">'."\n";
|
46 |
+
echo '<input type="hidden" name="ws_plugin__s2member_options_save" id="ws-plugin--s2member-options-save" value="'.esc_attr(wp_create_nonce("ws-plugin--s2member-options-save")).'" />'."\n";
|
47 |
+
echo '<input type="hidden" name="ws_plugin__s2member_configured" id="ws-plugin--s2member-configured" value="1" />'."\n";
|
48 |
+
|
49 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_before_left_sections", get_defined_vars());
|
50 |
|
51 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_deactivation", (!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site() || is_super_admin()), get_defined_vars()))
|
52 |
+
{
|
53 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_deactivation", get_defined_vars());
|
54 |
|
55 |
+
echo '<div class="ws-menu-page-group" title="Deactivation Safeguards"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["run_deactivation_routines"]) ? ' default-state="open"' : '').'>'."\n";
|
56 |
+
|
57 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-deactivation-section">'."\n";
|
58 |
+
echo '<h3>Deactivation Safeguards (highly recommended)</h3>'."\n";
|
59 |
+
echo (is_multisite() && c_ws_plugin__s2member_utils_conds::is_multisite_farm() && !is_main_site() && is_super_admin()) ? '<p><em class="ws-menu-page-hilite">On a Multisite Blog Farm, this panel is ONLY visible to YOU, as a Super Administrator. s2Member automatically Safeguards everything on a Multisite Blog Farm. However, as the Super Administrator, you may turn this off; on a per-Blog basis. For example, if you\'re going to de-activate s2Member on this particular Blog, you can turn OFF the Safeguards below, so that s2Member will completely erase itself.</em></p>'."\n" : '<p>By default, s2Member will retain all of it\'s Roles, Capabilities, and your Configuration Options when/if you deactivate s2Member from the Plugins Menu in WordPress. However, if you would like for s2Member to erase itself completely, please choose: <code>No (upon deactivation, erase all data/options)</code>.</p>'."\n";
|
60 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_deactivation", get_defined_vars());
|
61 |
|
62 |
+
echo '<table class="form-table">'."\n";
|
63 |
+
echo '<tbody>'."\n";
|
64 |
+
echo '<tr>'."\n";
|
65 |
|
66 |
+
echo '<th>'."\n";
|
67 |
+
echo '<label for="ws-plugin--s2member-run-deactivation-routines">'."\n";
|
68 |
+
echo 'Safeguard s2Member Data/Options?'."\n";
|
69 |
+
echo '</label>'."\n";
|
70 |
+
echo '</th>'."\n";
|
71 |
|
72 |
+
echo '</tr>'."\n";
|
73 |
+
echo '<tr>'."\n";
|
74 |
+
|
75 |
+
echo '<td>'."\n";
|
76 |
+
echo '<select name="ws_plugin__s2member_run_deactivation_routines" id="ws-plugin--s2member-run-deactivation-routines">'."\n";
|
77 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["run_deactivation_routines"]) ? ' selected="selected"' : '').'>Yes (safeguard all data/options)</option>'."\n";
|
78 |
+
echo '<option value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["run_deactivation_routines"]) ? ' selected="selected"' : '').'>No (upon deactivation, erase all data/options)</option>'."\n";
|
79 |
+
echo '</select><br />'."\n";
|
80 |
+
echo 'Recommended setting: (<code>Yes, safeguard all data/options</code>)'."\n";
|
81 |
+
echo '</td>'."\n";
|
82 |
+
|
83 |
+
echo '</tr>'."\n";
|
84 |
+
echo '</tbody>'."\n";
|
85 |
+
echo '</table>'."\n";
|
86 |
+
echo '</div>'."\n";
|
87 |
+
|
88 |
+
echo '</div>'."\n";
|
89 |
+
|
90 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_deactivation", get_defined_vars());
|
91 |
+
}
|
92 |
+
|
93 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_security", TRUE, get_defined_vars()))
|
94 |
+
{
|
95 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_security", get_defined_vars());
|
96 |
+
|
97 |
+
echo '<div class="ws-menu-page-group" title="Security Encryption Key">'."\n";
|
98 |
+
|
99 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-security-section">'."\n";
|
100 |
+
echo '<img src="'.esc_attr($GLOBALS["WS_PLUGIN__"]["s2member"]["c"]["dir_url"]).'/images/large-icon.png" title="s2Member (a Membership management system for WordPress)" alt="" style="float:right; margin:0 0 0 25px; border:0;" />'."\n";
|
101 |
+
echo '<h3>Security Encryption Key (optional, for tighter security)</h3>'."\n";
|
102 |
+
echo '<p>Just like WordPress, s2Member is open-source software. Which is wonderful. However, this also makes it possible for anyone to grab a copy of the software, and try to learn their way around its security measures. In order to keep your installation of s2Member unique/secure, you should configure a Security Encryption Key. s2Member will use your Security Encryption Key to protect itself against hackers. It does this by encrypting all sensitive information with your Key. A Security Encryption Key is unique to your installation.</p>'."\n";
|
103 |
+
echo '<p>Once you configure this, you do NOT want to change it; not ever. In fact, it is a VERY good idea to keep this backed up in a safe place, just in case you need to move your site, or re-install s2Member in the future. Some of the sensitive data that s2Member stores, will be encrypted with this Key. If you change it, that data can no longer be read, even by s2Member itself. In other words, don\'t use s2Member for six months, then decide to change your Key. That would break your installation.</p>'."\n";
|
104 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_security", get_defined_vars());
|
105 |
+
|
106 |
+
echo '<table class="form-table">'."\n";
|
107 |
+
echo '<tbody>'."\n";
|
108 |
+
echo '<tr>'."\n";
|
109 |
+
|
110 |
+
echo '<th>'."\n";
|
111 |
+
echo '<label for="ws-plugin--s2member-sec-encryption-key">'."\n";
|
112 |
+
echo 'Security Encryption Key (at least 60 chars)'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["sec_encryption_key"]) ? ' <a href="#" onclick="ws_plugin__s2member_enableSecurityKey(); return false;" title="(not recommended)">edit key</a>' : ' <a href="#" onclick="ws_plugin__s2member_generateSecurityKey(); return false;" title="Insert an auto-generated Key. (recommended)">auto-generate</a>')."\n";
|
113 |
+
echo '</label>'."\n";
|
114 |
+
echo '</th>'."\n";
|
115 |
+
|
116 |
+
echo '</tr>'."\n";
|
117 |
+
echo '<tr>'."\n";
|
118 |
+
|
119 |
+
echo '<td>'."\n";
|
120 |
+
echo '<input type="text" maxlength="256" autocomplete="off" name="ws_plugin__s2member_sec_encryption_key" id="ws-plugin--s2member-sec-encryption-key" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["sec_encryption_key"]).'"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["sec_encryption_key"]) ? ' disabled="disabled"' : '').' />'."\n";
|
121 |
+
echo (!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["sec_encryption_key"]) ? '<br />This may contain letters, numbers, spaces; even punctuation. Up to 256 characters.<br /><em>Ex: <code>'.esc_html(strtoupper(c_ws_plugin__s2member_utils_strings::random_str_gen(64))).'</code></em>'."\n" : '';
|
122 |
+
echo (count($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["sec_encryption_key_history"]) > 1) ? '<br /><a href="#" onclick="ws_plugin__s2member_securityKeyHistory(); return false;">Click here</a> for a history of your last 10 Encryption Keys.<div id="ws-plugin--s2member-sec-encryption-key-history" style="display:none;"><code>'.implode('</code><br /><code>', $GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["sec_encryption_key_history"]).'</code></div>'."\n" : '';
|
123 |
+
echo '</td>'."\n";
|
124 |
+
|
125 |
+
echo '</tr>'."\n";
|
126 |
+
echo '</tbody>'."\n";
|
127 |
+
echo '</table>'."\n";
|
128 |
+
echo '</div>'."\n";
|
129 |
+
|
130 |
+
echo '</div>'."\n";
|
131 |
+
|
132 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_security", get_defined_vars());
|
133 |
+
}
|
134 |
+
|
135 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_localhost_info", (!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site() || is_super_admin()), get_defined_vars()))
|
136 |
+
{
|
137 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_localhost_info", get_defined_vars());
|
138 |
+
|
139 |
+
echo '<div class="ws-menu-page-group" title="Localhost WAMP/MAMP Developers">'."\n";
|
140 |
+
|
141 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-localhost-info-section">'."\n";
|
142 |
+
echo '<h3>Localhost WAMP/MAMP Installs (are you a developer?)</h3>'."\n";
|
143 |
+
echo '<p>If you\'re developing your site in a <code>localhost</code> environment, running something like WAMP/MAMP, or <a href="http://www.easyphp.org/" target="_blank" rel="external">EasyPHP</a>, please add this line to your <code>/wp-config.php</code> file: <code><span style="color:#0000BB;">define</span><span style="color:#007700;">(</span><span style="color:#DD0000;">"LOCALHOST"</span>, <span style="color:#0000BB;">true</span><span style="color:#007700;">);</span></code>.</p>'."\n";
|
144 |
+
echo '<p>This lets s2Member know definitively that your site is in a <code>localhost</code> environment. s2Member will adjust itself accordingly, maximizing functionality during your developement. s2Member can usually auto-detect this, but in cases where your <code>localhost</code> installation runs on something other than <code>127.0.0.1/localhost</code>, you need to tell s2Member definitively, by adding that line to your <code>/wp-config.php</code> file. For instance, s2Member needs to know when your server IP is the same as all User IPs.</p>'."\n";
|
145 |
+
echo '<p><em>Once your site goes live, please remove the line. If you\'re already on a live server connected to the web, please ignore this section.</em></p>'."\n";
|
146 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_localhost_info", get_defined_vars());
|
147 |
+
echo '</div>'."\n";
|
148 |
+
|
149 |
+
echo '</div>'."\n";
|
150 |
+
|
151 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_localhost_info", get_defined_vars());
|
152 |
+
}
|
153 |
+
|
154 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_lazy_load", (!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site() || is_super_admin()), get_defined_vars()))
|
155 |
+
{
|
156 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_lazy_load", get_defined_vars());
|
157 |
+
|
158 |
+
echo '<div class="ws-menu-page-group" title="CSS/JS Lazy Loading">'."\n";
|
159 |
+
|
160 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-lazy-load-section">'."\n";
|
161 |
+
echo '<h3>CSS/JS Lazy Loading (Client-Side Libraries)</h3>'."\n";
|
162 |
+
echo '<p>By default, s2Member will load it\'s CSS/JS libraries on every page of your site. However, you may wish to enable lazy-loading here (e.g. only load when absolutely necessary).</p>'."\n";
|
163 |
+
echo '<p><em><strong>Tip:</strong> Do you need s2Member\'s CSS/JS on every page? If not, you can turn lazy-loading on. If you need s2Member\'s CSS/JS on a given Post/Page, you can insert an HTML comment into the Post/Page content like this: <code><!--s2member--></code>. If a Post/Page contains the word <code>s2member</code> or an <code>[s2*</code> Shortcode, this will automatically trigger s2Member\'s lazy-load routine (no matter what you configure here). Thus, it\'s an easy way to force s2Member to load it\'s CSS/JS on specific Posts/Pages where you deem this necessary. There is also a WordPress filter available: <code>add_filter("ws_plugin__s2member_lazy_load_css_js", "__return_true");</code> for developers; this could be incorporated into more dynamic scenarios.</em></p>'."\n";
|
164 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_lazy_load", get_defined_vars());
|
165 |
+
|
166 |
+
echo '<table class="form-table">'."\n";
|
167 |
+
echo '<tbody>'."\n";
|
168 |
+
echo '<tr>'."\n";
|
169 |
+
|
170 |
+
echo '<th>'."\n";
|
171 |
+
echo '<label for="ws-plugin--s2member-lazy-load-css-js">'."\n";
|
172 |
+
echo 'Lazy-Load s2Member\'s CSS/JS Libraries?'."\n";
|
173 |
+
echo '</label>'."\n";
|
174 |
+
echo '</th>'."\n";
|
175 |
+
|
176 |
+
echo '</tr>'."\n";
|
177 |
+
echo '<tr>'."\n";
|
178 |
+
|
179 |
+
echo '<td>'."\n";
|
180 |
+
echo '<select name="ws_plugin__s2member_lazy_load_css_js" id="ws-plugin--s2member-lazy-load-css-js">'."\n";
|
181 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["lazy_load_css_js"]) ? ' selected="selected"' : '').'>No (always load the CSS/JS libraries; e.g. on every page of the site)</option>'."\n";
|
182 |
+
echo '<option value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["lazy_load_css_js"]) ? ' selected="selected"' : '').'>Yes (lazy-load CSS/JS libraries; e.g. load only when absolutely necessary)</option>'."\n";
|
183 |
+
echo '</select>'."\n";
|
184 |
+
echo '</td>'."\n";
|
185 |
+
|
186 |
+
echo '</tr>'."\n";
|
187 |
+
echo '</tbody>'."\n";
|
188 |
+
echo '</table>'."\n";
|
189 |
+
echo '</div>'."\n";
|
190 |
+
|
191 |
+
echo '</div>'."\n";
|
192 |
+
|
193 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_lazy_load", get_defined_vars());
|
194 |
+
}
|
195 |
+
|
196 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_s_badge_wp_footer_code", TRUE, get_defined_vars()))
|
197 |
+
{
|
198 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_s_badge_wp_footer_code", get_defined_vars());
|
199 |
+
|
200 |
+
echo '<div class="ws-menu-page-group" title="s2Member Security Badge">'."\n";
|
201 |
+
|
202 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-s-badge-wp-footer-code-section">'."\n";
|
203 |
+
echo '<h3>Security Badge & Footer Configuration (optional)</h3>'."\n";
|
204 |
+
echo '<div class="ws-menu-page-right">'.c_ws_plugin__s2member_utilities::s_badge_gen("1", TRUE, TRUE).'</div>'."\n";
|
205 |
+
echo '<p>An s2Member Security Badge <em>(optional)</em>, can be used to express your site\'s concern for security; demonstrating to all Users/Members that your site <em>(and the s2Member software)</em>, takes security seriously. However, in order to qualify your site, you MUST generate a Security Encryption Key <em>(previous section)</em>, and then click "Save All Changes". Only then, will s2Member officially verify your installation <em>(verification occurs automatically)</em>.</p>'."\n";
|
206 |
+
echo '<p>Once you\'ve <a href="http://www.s2member.com/kb/security-badges/" target="_blank" rel="external">properly configured all security aspects of s2Member</a>, your s2Member Security Badge will be verified. To see the "verified" version of your Security Badge, you might need to refresh your browser after saving all changes <em>(i.e. after you create a Security Encryption Key)</em>. Also, s2Member will NOT "verify" your site if you turn off Unique IP Restrictions, Brute Force Login Protection, or if your <code>/wp-config.php</code> file lacks <a href="http://codex.wordpress.org/Editing_wp-config.php#Security_Keys" target="_blank" rel="external">Security Keys</a> <em>(each at least 60 chars in length)</em>. In addition, it\'s NOT possible for s2Member to verify your Security Badge, if your site is in a <code>localhost</code> environment; i.e. not connected to the web.</p>'."\n";
|
207 |
+
echo '<p><strong>How does s2Member know when my site is secure?</strong><br />If enabled below, an API call for "Security Badge Status", will allow web service connections to determine your status. Clicking <a href="'.esc_attr(site_url("/?s2member_s_badge_status=1")).'" target="_blank" rel="external">this link</a> will report <code>1</code> <em>(secure)</em>, <code>0</code> <em>(at risk)</em>, or <code>-</code> <em>(API disabled)</em>. Once all security considerations are satisfied, s2Member will report <code>1</code> <em>(secure)</em> for your installation. *Note, this simple API will NOT, and should not, report any other information. It will ONLY report the current status of your Security Badge, as determined by your installation of s2Member. When/if you install the s2Member Security Badge, s2Member will make a connection to your site "once per day", to test your status.</p>'."\n";
|
208 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_s_badge_wp_footer_code", get_defined_vars());
|
209 |
+
|
210 |
+
echo '<table class="form-table">'."\n";
|
211 |
+
echo '<tbody>'."\n";
|
212 |
+
echo '<tr>'."\n";
|
213 |
+
|
214 |
+
echo '<th>'."\n";
|
215 |
+
echo '<label for="ws-plugin--s2member-s-badge-status-enabled">'."\n";
|
216 |
+
echo 'Enable Security Badge Status API?'."\n";
|
217 |
+
echo '</label>'."\n";
|
218 |
+
echo '</th>'."\n";
|
219 |
+
|
220 |
+
echo '</tr>'."\n";
|
221 |
+
echo '<tr>'."\n";
|
222 |
+
|
223 |
+
echo '<td>'."\n";
|
224 |
+
echo '<select name="ws_plugin__s2member_s_badge_status_enabled" id="ws-plugin--s2member-s-badge-status-enabled">'."\n";
|
225 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["s_badge_status_enabled"]) ? ' selected="selected"' : '').'>No (default, Badge Status API is disabled)</option>'."\n";
|
226 |
+
echo '<option value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["s_badge_status_enabled"]) ? ' selected="selected"' : '').'>Yes (enable Badge Status API for verification)</option>'."\n";
|
227 |
+
echo '</select><br />'."\n";
|
228 |
+
echo 'This must be enabled if you want s2Member to verify your Security Badge.'."\n";
|
229 |
+
echo '</td>'."\n";
|
230 |
+
|
231 |
+
echo '</tr>'."\n";
|
232 |
+
echo '<tr>'."\n";
|
233 |
+
|
234 |
+
echo '<th>'."\n";
|
235 |
+
echo '<label for="ws-plugin--s2member-wp-footer-code">'."\n";
|
236 |
+
echo 'Customize WordPress Footer:<br />'."\n";
|
237 |
+
echo '<small>[ <a href="#" onclick="this.$code = jQuery(\'textarea#ws-plugin--s2member-wp-footer-code\'); this.$code.val(jQuery.trim(unescape(\''.rawurlencode('[s2Member-Security-Badge v="1" /]').'\')+\'\n\'+this.$code.val())); return false;">Click HERE to insert your Security Badge</a> ],<br />or use Shortcode <code>[s2Member-Security-Badge v="1" /]</code> in a Post/Page/Widget.<br />The <code>v="1"</code> attribute is a Security Badge style/variation. Try variations <code>1|2|3</code>.</small>'."\n";
|
238 |
+
echo '</label>'."\n";
|
239 |
+
echo '</th>'."\n";
|
240 |
+
|
241 |
+
echo '</tr>'."\n";
|
242 |
+
echo '<tr>'."\n";
|
243 |
+
|
244 |
+
echo '<td>'."\n";
|
245 |
+
echo '<textarea name="ws_plugin__s2member_wp_footer_code" id="ws-plugin--s2member-wp-footer-code" rows="8" wrap="off" spellcheck="false" class="monospace">'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["wp_footer_code"]).'</textarea><br />'."\n";
|
246 |
+
echo 'Any valid XHTML / JavaScript'.((is_multisite() && c_ws_plugin__s2member_utils_conds::is_multisite_farm() && !is_main_site()) ? '' : ' (or even PHP)').' code will work just fine here.'."\n";
|
247 |
+
echo '</td>'."\n";
|
248 |
+
|
249 |
+
echo '</tr>'."\n";
|
250 |
+
echo '</tbody>'."\n";
|
251 |
+
echo '</table>'."\n";
|
252 |
+
echo '</div>'."\n";
|
253 |
+
|
254 |
+
echo '</div>'."\n";
|
255 |
+
|
256 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_s_badge_wp_footer_code", get_defined_vars());
|
257 |
+
}
|
258 |
+
|
259 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_email_config", TRUE, get_defined_vars()))
|
260 |
+
{
|
261 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_email_config", get_defined_vars());
|
262 |
+
|
263 |
+
echo '<div class="ws-menu-page-group" title="Email Configuration">'."\n";
|
264 |
+
|
265 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-email-section">'."\n";
|
266 |
+
echo '<h3 style="margin:0;">Email From: '.esc_html('"Name" <address>').'</h3>'."\n";
|
267 |
+
echo '<p style="margin:0;">This is the name/address that will appear in outgoing email notifications sent by the s2Member plugin.</p>'."\n";
|
268 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_email_from_name_config", get_defined_vars());
|
269 |
+
|
270 |
+
echo '<table class="form-table">'."\n";
|
271 |
+
echo '<tbody>'."\n";
|
272 |
+
echo '<tr>'."\n";
|
273 |
+
|
274 |
+
echo '<th>'."\n";
|
275 |
+
echo '<label for="ws-plugin--s2member-reg-email-from-name">'."\n";
|
276 |
+
echo 'Email From Name:'."\n";
|
277 |
+
echo '</label>'."\n";
|
278 |
+
echo '</th>'."\n";
|
279 |
+
|
280 |
+
echo '</tr>'."\n";
|
281 |
+
echo '<tr>'."\n";
|
282 |
+
|
283 |
+
echo '<td>'."\n";
|
284 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_reg_email_from_name" id="ws-plugin--s2member-reg-email-from-name" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["reg_email_from_name"]).'" /><br />'."\n";
|
285 |
+
echo 'We recommend that you use the name of your site here.'."\n";
|
286 |
+
echo '</td>'."\n";
|
287 |
+
|
288 |
+
echo '</tr>'."\n";
|
289 |
+
echo '<tr>'."\n";
|
290 |
+
|
291 |
+
echo '<th>'."\n";
|
292 |
+
echo '<label for="ws-plugin--s2member-reg-email-from-email">'."\n";
|
293 |
+
echo 'Email From Address:'."\n";
|
294 |
+
echo '</label>'."\n";
|
295 |
+
echo '</th>'."\n";
|
296 |
+
|
297 |
+
echo '</tr>'."\n";
|
298 |
+
echo '<tr>'."\n";
|
299 |
+
|
300 |
+
echo '<td>'."\n";
|
301 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_reg_email_from_email" id="ws-plugin--s2member-reg-email-from-email" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["reg_email_from_email"]).'" /><br />'."\n";
|
302 |
+
echo 'Example: support@your-domain.com. <em class="ws-menu-page-hilite">Please read <a href="#" onclick="alert(\'Running WordPress with an SMTP mail plugin?\\n\\nPlease be advised. If you run an SMTP mail plugin with WordPress, be sure to configure s2Member with a valid `From:` address (i.e. one matching your SMTP configuration perhaps). Most free SMTP servers, such as Gmail and Yahoo, require that your `From:` header match the email address associated with your account. Please check with your SMTP service provider before attempting to configure plugins like s2Member to use a different `From:` address when sending email messages.\'); return false;">this IMPORTANT note</a></em>.'."\n";
|
303 |
+
echo '</td>'."\n";
|
304 |
+
|
305 |
+
echo '</tr>'."\n";
|
306 |
+
echo '<tr>'."\n";
|
307 |
+
|
308 |
+
echo '<th>'."\n";
|
309 |
+
echo '<label for="ws-plugin--s2member-reg-email-support-link">'."\n";
|
310 |
+
echo 'Email Support/Contact Link:'."\n";
|
311 |
+
echo '</label>'."\n";
|
312 |
+
echo '</th>'."\n";
|
313 |
+
|
314 |
+
echo '</tr>'."\n";
|
315 |
+
echo '<tr>'."\n";
|
316 |
+
|
317 |
+
echo '<td>'."\n";
|
318 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_reg_email_support_link" id="ws-plugin--s2member-reg-email-support-link" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["reg_email_support_link"]).'" /><br />'."\n";
|
319 |
+
echo 'Ex: <code>mailto:support@your-domain.com</code> (<em>mailto link</em>).<br />'."\n";
|
320 |
+
echo 'Or: <code>'.esc_html(site_url("/contact-us/")).'</code>.'."\n";
|
321 |
+
echo '</td>'."\n";
|
322 |
+
|
323 |
+
echo '</tr>'."\n";
|
324 |
+
echo '</tbody>'."\n";
|
325 |
+
echo '</table>'."\n";
|
326 |
+
|
327 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
328 |
+
|
329 |
+
echo '<h3 style="margin:0;">New User Email Configuration</h3>'."\n";
|
330 |
+
echo '<input type="hidden" id="ws-plugin--s2member-pluggables-wp-new-user-notification" value="'.esc_attr((empty ($GLOBALS["WS_PLUGIN__"]["s2member"]["c"]["pluggables"]["wp_new_user_notification"])) ? '0' : '1').'" />'."\n";
|
331 |
+
echo (empty ($GLOBALS["WS_PLUGIN__"]["s2member"]["c"]["pluggables"]["wp_new_user_notification"])) ? '<p class="ws-menu-page-error" style="margin:0;"><em><strong>Conflict warning:</strong> You have another theme or plugin installed that is preventing s2Member from controlling this aspect of your installation. When the pluggable function <code><a href="http://codex.wordpress.org/Function_Reference/wp_new_user_notification" target="_blank" rel="external">wp_new_user_notification()</a></code> is handled by another plugin, it\'s not possible for s2Member to allow customization of New User Emails. This is NOT a major issue. In fact, in some cases, it might be desirable. That being said, if you DO want to use s2Member\'s customization of New User Emails, you will need to deactivate one plugin at a time until this conflict warning goes away.</em></p>'."\n" : '';
|
332 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_new_user_emails", get_defined_vars());
|
333 |
+
|
334 |
+
echo '<table class="form-table">'."\n";
|
335 |
+
echo '<tbody>'."\n";
|
336 |
+
echo '<tr>'."\n";
|
337 |
+
|
338 |
+
echo '<td>'."\n";
|
339 |
+
echo '<select name="ws_plugin__s2member_new_user_emails_enabled" id="ws-plugin--s2member-new-user-emails-enabled">'."\n";
|
340 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["new_user_emails_enabled"]) ? ' selected="selected"' : '').'>No (default, use WordPress defaults)</option>'."\n";
|
341 |
+
echo '<option value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["new_user_emails_enabled"]) ? ' selected="selected"' : '').'>Yes (customize New User Emails with s2Member)</option>'."\n";
|
342 |
+
echo '</select>'."\n";
|
343 |
+
echo '</td>'."\n";
|
344 |
+
|
345 |
+
echo '</tr>'."\n";
|
346 |
+
echo '</tbody>'."\n";
|
347 |
+
echo '</table>'."\n";
|
348 |
+
|
349 |
+
echo '<div id="ws-plugin--s2member-new-user-emails">'."\n";
|
350 |
+
|
351 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
352 |
+
|
353 |
+
echo '<h3 style="margin:0;">New User Email Message (<a href="#" onclick="jQuery(\'div#ws-plugin--s2member-new-user-email-details\').toggle(); return false;" class="ws-dotted-link">click to customize</a>)</h3>'."\n";
|
354 |
+
echo '<p style="margin:0;">This email is sent to all new Users/Members. It should always contain their Username/Password. In addition to this email, s2Member will also send new paying Customers a Signup Confirmation Email, which you can customize from your Dashboard, under: <code>s2Member -› PayPal Options</code>. You may wish to customize these emails further, by providing details that are specifically geared to your site.</p>'."\n";
|
355 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_new_user_email", get_defined_vars());
|
356 |
+
|
357 |
+
echo '<div id="ws-plugin--s2member-new-user-email-details" style="display:none;">'."\n";
|
358 |
+
echo (c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '<p><em><strong>BuddyPress:</strong> please note that BuddyPress does NOT send this email to Users that register through the BuddyPress registration system. This is because BuddyPress sends each User an activation link; eliminating the need for this email all together. However, you CAN still customize s2Member\'s separate email to paying Members. See: <code>s2Member -› PayPal Options -› Signup Confirmation Email</code>.</em></p>'."\n" : '';
|
359 |
+
echo '<table class="form-table">'."\n";
|
360 |
+
echo '<tbody>'."\n";
|
361 |
+
echo '<tr>'."\n";
|
362 |
+
|
363 |
+
echo '<th>'."\n";
|
364 |
+
echo '<label for="ws-plugin--s2member-new-user-email-subject">'."\n";
|
365 |
+
echo 'New User Email Subject:'."\n";
|
366 |
+
echo '</label>'."\n";
|
367 |
+
echo '</th>'."\n";
|
368 |
+
|
369 |
+
echo '</tr>'."\n";
|
370 |
+
echo '<tr>'."\n";
|
371 |
+
|
372 |
+
echo '<td>'."\n";
|
373 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_new_user_email_subject" id="ws-plugin--s2member-new-user-email-subject" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["new_user_email_subject"]).'" /><br />'."\n";
|
374 |
+
echo 'Subject Line used in the email sent to new Users/Members.'."\n";
|
375 |
+
echo '</td>'."\n";
|
376 |
+
|
377 |
+
echo '</tr>'."\n";
|
378 |
+
echo '<tr>'."\n";
|
379 |
+
|
380 |
+
echo '<th>'."\n";
|
381 |
+
echo '<label for="ws-plugin--s2member-new-user-email-message">'."\n";
|
382 |
+
echo 'New User Email Message:'."\n";
|
383 |
+
echo '</label>'."\n";
|
384 |
+
echo '</th>'."\n";
|
385 |
+
|
386 |
+
echo '</tr>'."\n";
|
387 |
+
echo '<tr>'."\n";
|
388 |
+
|
389 |
+
echo '<td>'."\n";
|
390 |
+
echo '<textarea name="ws_plugin__s2member_new_user_email_message" id="ws-plugin--s2member-new-user-email-message" rows="10">'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["new_user_email_message"]).'</textarea><br />'."\n";
|
391 |
+
echo 'Message Body used in the email sent to new Users/Members.<br /><br />'."\n";
|
392 |
+
echo '<strong>You can also use these special Replacement Codes if you need them:</strong>'."\n";
|
393 |
+
echo '<ul>'."\n";
|
394 |
+
echo '<li><code>%%role%%</code> = The Role ID <code>(subscriber, s2member_level[0-9]+, administrator, editor, author, contributor)</code>.</li>'."\n";
|
395 |
+
echo '<li><code>%%label%%</code> = The Role ID Label <code>(Subscriber, s2Member Level 1, s2Member Level 2; or your own custom Labels — if configured)</code>.</li>'."\n";
|
396 |
+
echo '<li><code>%%level%%</code> = The Level number <code>(0, 1, 2, 3, 4)</code>. (<em>deprecated, no longer recommended; use <code>%%role%%</code></em>)</li>'."\n";
|
397 |
+
echo '<li><code>%%ccaps%%</code> = Custom Capabilities. Ex: <code>music,videos,free_gift</code> (<em>in comma-delimited format</em>).</li>'."\n";
|
398 |
+
echo '<li><code>%%user_first_name%%</code> = The First Name of the Member who registered their Username.</li>'."\n";
|
399 |
+
echo '<li><code>%%user_last_name%%</code> = The Last Name of the Member who registered their Username.</li>'."\n";
|
400 |
+
echo '<li><code>%%user_full_name%%</code> = The Full Name (First & Last) of the Member who registered their Username.</li>'."\n";
|
401 |
+
echo '<li><code>%%user_email%%</code> = The Email Address of the Member who registered their Username.</li>'."\n";
|
402 |
+
echo '<li><code>%%user_login%%</code> = The Username the Member selected during registration.</li>'."\n";
|
403 |
+
echo '<li><code>%%user_pass%%</code> = The Password selected or generated during registration.</li>'."\n";
|
404 |
+
echo '<li><code>%%user_ip%%</code> = The User\'s IP Address, detected via <code>$_SERVER["REMOTE_ADDR"]</code>.</li>'."\n";
|
405 |
+
echo '<li><code>%%user_id%%</code> = A unique WordPress User ID generated during registration.</li>'."\n";
|
406 |
+
echo '<li><code>%%wp_login_url%%</code> = The full URL where Users can get logged into your site.</li>'."\n";
|
407 |
+
echo '</ul>'."\n";
|
408 |
+
|
409 |
+
echo '<strong>Custom Registration/Profile Fields are also supported in this email:</strong>'."\n";
|
410 |
+
echo '<ul>'."\n";
|
411 |
+
echo '<li><code>%%date_of_birth%%</code> would be valid; if you have a Custom Registration/Profile Field with the ID <code>date_of_birth</code>.</li>'."\n";
|
412 |
+
echo '<li><code>%%street_address%%</code> would be valid; if you have a Custom Registration/Profile Field with the ID <code>street_address</code>.</li>'."\n";
|
413 |
+
echo '<li><code>%%country%%</code> would be valid; if you have a Custom Registration/Profile Field with the ID <code>country</code>.</li>'."\n";
|
414 |
+
echo '<li><em><code>%%etc, etc...%%</code> <strong>see:</strong> s2Member -› General Options -› Registration/Profile Fields</em>.</li>'."\n";
|
415 |
+
echo '</ul>'."\n";
|
416 |
+
|
417 |
+
echo '<strong>Custom Replacement Codes can also be inserted using these instructions:</strong>'."\n";
|
418 |
+
echo '<ul>'."\n";
|
419 |
+
echo '<li><code>%%cv0%%</code> = The domain of your site, which is passed through the `custom` attribute in your Shortcode.</li>'."\n";
|
420 |
+
echo '<li><code>%%cv1%%</code> = If you need to track additional custom variables, you can pipe delimit them into the `custom` attribute; inside your Shortcode, like this: <code>custom="'.esc_html($_SERVER["HTTP_HOST"]).'|cv1|cv2|cv3"</code>. You can have an unlimited number of custom variables. Obviously, this is for advanced webmasters; but the functionality has been made available for those who need it.</li>'."\n";
|
421 |
+
echo '</ul>'."\n";
|
422 |
+
echo '<strong>This example uses cv1 to record a special marketing campaign:</strong><br />'."\n";
|
423 |
+
echo '<em>(The campaign (i.e. christmas-promo) could be referenced using <code>%%cv1%%</code>)</em><br />'."\n";
|
424 |
+
echo '<code>custom="'.esc_html($_SERVER["HTTP_HOST"]).'|christmas-promo"</code>'."\n";
|
425 |
+
|
426 |
+
echo (!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site()) ?
|
427 |
+
'<div class="ws-menu-page-hr"></div>'."\n".
|
428 |
+
'<p style="margin:0;"><strong>PHP Code:</strong> It is also possible to use PHP tags — optional (for developers). If you use PHP tags, please run a test email with <code><?php print_r(get_defined_vars()); ?></code>. This will give you a full list of all PHP variables available to you in this email. The <code>$user</code> variable is the most important one. It\'s an instance of the <a href="http://codex.wordpress.org/Class_Reference/WP_User" target="_blank" rel="external"><code>WP_User</code></a> class (e.g. <code>$user->ID</code>, <code>$user->has_cap()</code>, etc). Please note that all Replacement Codes will be parsed first, and then any PHP tags that you\'ve included. Also, please remember that emails are sent in plain text format.</p>'."\n"
|
429 |
+
: '';
|
430 |
+
echo '</td>'."\n";
|
431 |
+
|
432 |
+
echo '</tr>'."\n";
|
433 |
+
echo '</tbody>'."\n";
|
434 |
+
echo '</table>'."\n";
|
435 |
+
echo '</div>'."\n";
|
436 |
+
|
437 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
438 |
+
|
439 |
+
echo '<h3 style="margin:0;">Administrative: New User Notification (<a href="#" onclick="jQuery(\'div#ws-plugin--s2member-new-user-admin-email-details\').toggle(); return false;" class="ws-dotted-link">click to customize</a>)</h3>'."\n";
|
440 |
+
echo '<p style="margin:0;">This email notification is sent to you, each time a new User/Member registers.</p>'."\n";
|
441 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_new_user_admin_email", get_defined_vars());
|
442 |
+
|
443 |
+
echo '<div id="ws-plugin--s2member-new-user-admin-email-details" style="display:none;">'."\n";
|
444 |
+
echo '<table class="form-table">'."\n";
|
445 |
+
echo '<tbody>'."\n";
|
446 |
+
echo '<tr>'."\n";
|
447 |
+
|
448 |
+
echo '<th>'."\n";
|
449 |
+
echo '<label for="ws-plugin--s2member-new-user-admin-email-recipients">'."\n";
|
450 |
+
echo 'New User Notification Recipients:'."\n";
|
451 |
+
echo '</label>'."\n";
|
452 |
+
echo '</th>'."\n";
|
453 |
+
|
454 |
+
echo '</tr>'."\n";
|
455 |
+
echo '<tr>'."\n";
|
456 |
+
|
457 |
+
echo '<td>'."\n";
|
458 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_new_user_admin_email_recipients" id="ws-plugin--s2member-new-user-admin-email-recipients" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["new_user_admin_email_recipients"]).'" /><br />'."\n";
|
459 |
+
echo 'This is a semicolon ( ; ) delimited list of Recipients. Here is an example:<br />'."\n";
|
460 |
+
echo '<code>"Name" <user@example.com>; admin@example.com; "Webmaster" <webmaster@example.com></code>'."\n";
|
461 |
+
echo '</td>'."\n";
|
462 |
+
|
463 |
+
echo '</tr>'."\n";
|
464 |
+
echo '<tr>'."\n";
|
465 |
+
|
466 |
+
echo '<th>'."\n";
|
467 |
+
echo '<label for="ws-plugin--s2member-new-user-admin-email-subject">'."\n";
|
468 |
+
echo 'New User Notification Subject:'."\n";
|
469 |
+
echo '</label>'."\n";
|
470 |
+
echo '</th>'."\n";
|
471 |
+
|
472 |
+
echo '</tr>'."\n";
|
473 |
+
echo '<tr>'."\n";
|
474 |
+
|
475 |
+
echo '<td>'."\n";
|
476 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_new_user_admin_email_subject" id="ws-plugin--s2member-new-user-admin-email-subject" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["new_user_admin_email_subject"]).'" /><br />'."\n";
|
477 |
+
echo 'Subject Line used in the email notification sent to Administrator.'."\n";
|
478 |
+
echo '</td>'."\n";
|
479 |
+
|
480 |
+
echo '</tr>'."\n";
|
481 |
+
echo '<tr>'."\n";
|
482 |
+
|
483 |
+
echo '<th>'."\n";
|
484 |
+
echo '<label for="ws-plugin--s2member-new-user-admin-email-message">'."\n";
|
485 |
+
echo 'New User Notification Message:'."\n";
|
486 |
+
echo '</label>'."\n";
|
487 |
+
echo '</th>'."\n";
|
488 |
+
|
489 |
+
echo '</tr>'."\n";
|
490 |
+
echo '<tr>'."\n";
|
491 |
+
|
492 |
+
echo '<td>'."\n";
|
493 |
+
echo '<textarea name="ws_plugin__s2member_new_user_admin_email_message" id="ws-plugin--s2member-new-user-admin-email-message" rows="10">'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["new_user_admin_email_message"]).'</textarea><br />'."\n";
|
494 |
+
echo 'Message Body used in the email notification sent to Administrator.<br /><br />'."\n";
|
495 |
+
echo '<strong>You can also use these special Replacement Codes if you need them:</strong>'."\n";
|
496 |
+
echo '<ul>'."\n";
|
497 |
+
echo '<li><code>%%role%%</code> = The Role ID <code>(subscriber, s2member_level[0-9]+, administrator, editor, author, contributor)</code>.</li>'."\n";
|
498 |
+
echo '<li><code>%%label%%</code> = The Role ID Label <code>(Subscriber, s2Member Level 1, s2Member Level 2; or your own custom Labels — if configured)</code>.</li>'."\n";
|
499 |
+
echo '<li><code>%%level%%</code> = The Level number <code>(0, 1, 2, 3, 4)</code>. (<em>deprecated, no longer recommended; use <code>%%role%%</code></em>)</li>'."\n";
|
500 |
+
echo '<li><code>%%ccaps%%</code> = Custom Capabilities. Ex: <code>music,videos,free_gift</code> (<em>in comma-delimited format</em>).</li>'."\n";
|
501 |
+
echo '<li><code>%%user_first_name%%</code> = The First Name of the Member who registered their Username.</li>'."\n";
|
502 |
+
echo '<li><code>%%user_last_name%%</code> = The Last Name of the Member who registered their Username.</li>'."\n";
|
503 |
+
echo '<li><code>%%user_full_name%%</code> = The Full Name (First & Last) of the Member who registered their Username.</li>'."\n";
|
504 |
+
echo '<li><code>%%user_email%%</code> = The Email Address of the Member who registered their Username.</li>'."\n";
|
505 |
+
echo '<li><code>%%user_login%%</code> = The Username the Member selected during registration.</li>'."\n";
|
506 |
+
echo '<li><code>%%user_pass%%</code> = The Password selected or generated during registration.</li>'."\n";
|
507 |
+
echo '<li><code>%%user_ip%%</code> = The User\'s IP Address, detected via <code>$_SERVER["REMOTE_ADDR"]</code>.</li>'."\n";
|
508 |
+
echo '<li><code>%%user_id%%</code> = A unique WordPress User ID generated during registration.</li>'."\n";
|
509 |
+
echo '<li><code>%%wp_login_url%%</code> = The full URL where Users can get logged into your site.</li>'."\n";
|
510 |
+
echo '</ul>'."\n";
|
511 |
+
|
512 |
+
echo '<strong>Custom Registration/Profile Fields are also supported in this email:</strong>'."\n";
|
513 |
+
echo '<ul>'."\n";
|
514 |
+
echo '<li><code>%%date_of_birth%%</code> would be valid; if you have a Custom Registration/Profile Field with the ID <code>date_of_birth</code>.</li>'."\n";
|
515 |
+
echo '<li><code>%%street_address%%</code> would be valid; if you have a Custom Registration/Profile Field with the ID <code>street_address</code>.</li>'."\n";
|
516 |
+
echo '<li><code>%%country%%</code> would be valid; if you have a Custom Registration/Profile Field with the ID <code>country</code>.</li>'."\n";
|
517 |
+
echo '<li><em><code>%%etc, etc...%%</code> <strong>see:</strong> s2Member -› General Options -› Registration/Profile Fields</em>.</li>'."\n";
|
518 |
+
echo '</ul>'."\n";
|
519 |
+
|
520 |
+
echo '<strong>Custom Replacement Codes can also be inserted using these instructions:</strong>'."\n";
|
521 |
+
echo '<ul>'."\n";
|
522 |
+
echo '<li><code>%%cv0%%</code> = The domain of your site, which is passed through the `custom` attribute in your Shortcode.</li>'."\n";
|
523 |
+
echo '<li><code>%%cv1%%</code> = If you need to track additional custom variables, you can pipe delimit them into the `custom` attribute; inside your Shortcode, like this: <code>custom="'.esc_html($_SERVER["HTTP_HOST"]).'|cv1|cv2|cv3"</code>. You can have an unlimited number of custom variables. Obviously, this is for advanced webmasters; but the functionality has been made available for those who need it.</li>'."\n";
|
524 |
+
echo '</ul>'."\n";
|
525 |
+
echo '<strong>This example uses cv1 to record a special marketing campaign:</strong><br />'."\n";
|
526 |
+
echo '<em>(The campaign (i.e. christmas-promo) could be referenced using <code>%%cv1%%</code>)</em><br />'."\n";
|
527 |
+
echo '<code>custom="'.esc_html($_SERVER["HTTP_HOST"]).'|christmas-promo"</code>'."\n";
|
528 |
+
|
529 |
+
echo (!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site()) ?
|
530 |
+
'<div class="ws-menu-page-hr"></div>'."\n".
|
531 |
+
'<p style="margin:0;"><strong>PHP Code:</strong> It is also possible to use PHP tags — optional (for developers). If you use PHP tags, please run a test email with <code><?php print_r(get_defined_vars()); ?></code>. This will give you a full list of all PHP variables available to you in this email. The <code>$user</code> variable is the most important one. It\'s an instance of the <a href="http://codex.wordpress.org/Class_Reference/WP_User" target="_blank" rel="external"><code>WP_User</code></a> class (e.g. <code>$user->ID</code>, <code>$user->has_cap()</code>, etc). Please note that all Replacement Codes will be parsed first, and then any PHP tags that you\'ve included. Also, please remember that emails are sent in plain text format.</p>'."\n"
|
532 |
+
: '';
|
533 |
+
echo '</td>'."\n";
|
534 |
+
|
535 |
+
echo '</tr>'."\n";
|
536 |
+
echo '</tbody>'."\n";
|
537 |
+
echo '</table>'."\n";
|
538 |
+
echo '</div>'."\n";
|
539 |
+
echo '</div>'."\n";
|
540 |
+
|
541 |
+
echo '</div>'."\n";
|
542 |
+
|
543 |
+
echo '</div>'."\n";
|
544 |
+
|
545 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_email_config", get_defined_vars());
|
546 |
+
}
|
547 |
+
|
548 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_open_registration", TRUE, get_defined_vars()))
|
549 |
+
{
|
550 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_open_registration", get_defined_vars());
|
551 |
+
|
552 |
+
if(is_multisite() && is_main_site()) // A Multisite Network, and we're on the Main Site?
|
553 |
+
{
|
554 |
+
echo '<div class="ws-menu-page-group" title="Open Registration">'."\n";
|
555 |
+
|
556 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-open-registration-section">'."\n";
|
557 |
+
echo '<h3>Open Registration / Free Subscribers (optional)</h3>'."\n";
|
558 |
+
echo '<p>On the Main Site of a Multisite Network, the settings for Open Registration are consolidated into the <code>s2Member -› Multisite (Config)</code> panel.</p>'."\n";
|
559 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_open_registration", get_defined_vars());
|
560 |
+
echo '</div>'."\n";
|
561 |
+
|
562 |
+
echo '</div>'."\n";
|
563 |
+
}
|
564 |
+
else // Else we display this section normally. No special considerations are required in this case.
|
565 |
+
{
|
566 |
+
echo '<div class="ws-menu-page-group" title="Open Registration">'."\n";
|
567 |
+
|
568 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-open-registration-section">'."\n";
|
569 |
+
echo '<h3>Open Registration / Free Subscribers (optional)</h3>'."\n";
|
570 |
+
echo '<p>s2Member supports Free Subscribers (at Level #0), along with four Primary Levels [1-4] of paid Membership. If you want your visitors to be capable of registering absolutely free, you will want to "allow" Open Registration. Whenever a visitor registers without paying, they\'ll automatically become a Free Subscriber, at Level #0.</p>'."\n";
|
571 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_open_registration", get_defined_vars());
|
572 |
+
|
573 |
+
echo '<table class="form-table">'."\n";
|
574 |
+
echo '<tbody>'."\n";
|
575 |
+
echo '<tr>'."\n";
|
576 |
+
|
577 |
+
echo '<th>'."\n";
|
578 |
+
echo '<label for="ws-plugin--s2member-allow-subscribers-in">'."\n";
|
579 |
+
echo 'Allow Open Registration? (Free Subscribers)'."\n";
|
580 |
+
echo '</label>'."\n";
|
581 |
+
echo '</th>'."\n";
|
582 |
+
|
583 |
+
echo '</tr>'."\n";
|
584 |
+
echo '<tr>'."\n";
|
585 |
+
|
586 |
+
echo '<td>'."\n";
|
587 |
+
echo '<select name="ws_plugin__s2member_allow_subscribers_in" id="ws-plugin--s2member-allow-subscribers-in">'."\n";
|
588 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["allow_subscribers_in"]) ? ' selected="selected"' : '').'>No (do NOT allow Open Registration)</option>'."\n";
|
589 |
+
echo '<option value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["allow_subscribers_in"]) ? ' selected="selected"' : '').'>Yes (allow Open Registration; Free Subscribers at Level #0)</option>'."\n";
|
590 |
+
echo '</select><br />'."\n";
|
591 |
+
echo 'If you set this to <code>Yes</code>, you\'re unlocking <a href="'.esc_attr(c_ws_plugin__s2member_utils_urls::wp_register_url()).'" target="_blank" rel="external" onclick="alert(\'s2Member will now open your Standard Registration Form.\\n* s2Member makes this form available to logged-in Administrators, at all times (for testing purposes), regardless of configuration.'.((c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '\\n\\nBuddyPress: * BuddyPress will use its own Registration Form. Please note, you will probably be redirected away from the BuddyPress Registration Form ( '.c_ws_plugin__s2member_utils_strings::esc_js_sq(c_ws_plugin__s2member_utils_urls::bp_register_url()).' ), because you\\\'re ALREADY logged-in. Please log out before testing BuddyPress registration.' : '').'\');">/wp-login.php?action=register</a>. When a visitor registers without paying, they\'ll automatically become a Free Subscriber, at Level #0. The s2Member software reserves Level #0; to be used ONLY for Free Subscribers. All other Membership Levels [1-4] require payment.'."\n";
|
592 |
+
echo (c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '<br /><br /><em><strong>BuddyPress:</strong> BuddyPress will use its own Registration Form <a href="'.esc_attr(c_ws_plugin__s2member_utils_urls::bp_register_url()).'" target="_blank" rel="external" onclick="alert(\'s2Member will now open your BuddyPress Registration Form.\\n* However, you will probably be redirected away from this BuddyPress Registration Form ( '.c_ws_plugin__s2member_utils_strings::esc_js_sq(c_ws_plugin__s2member_utils_urls::bp_register_url()).' ), because you\\\'re ALREADY logged-in. Please log out before testing BuddyPress registration.\');">here</a>.<br />s2Member integrates with BuddyPress, and the above setting will control Open Regisration for BuddyPress too.</em>'."\n" : '';
|
593 |
+
echo '</td>'."\n";
|
594 |
+
|
595 |
+
echo '</tr>'."\n";
|
596 |
+
echo '</tbody>'."\n";
|
597 |
+
echo '</table>'."\n";
|
598 |
+
echo '</div>'."\n";
|
599 |
+
|
600 |
+
echo '</div>'."\n";
|
601 |
+
}
|
602 |
+
|
603 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_open_registration", get_defined_vars());
|
604 |
+
}
|
605 |
+
|
606 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_membership_levels", TRUE, get_defined_vars()))
|
607 |
+
{
|
608 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_membership_levels", get_defined_vars());
|
609 |
+
|
610 |
+
echo '<div class="ws-menu-page-group" title="Membership Levels/Labels">'."\n";
|
611 |
+
|
612 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-membership-levels-section">'."\n";
|
613 |
+
echo '<h3>Membership Levels (required, please customize these)</h3>'."\n";
|
614 |
+
echo '<p>The default Membership Levels are labeled generically; feel free to modify them as needed. s2Member supports Free Subscribers <em>(at Level #0)</em>, along with several Primary Roles for paid Membership <em>(i.e. Levels 1-4)</em>, created by the s2Member plugin.'.((!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site()) ? ' s2Member also supports unlimited Custom Capability Packages <em>(see <code>s2Member -› API Scripting -› Custom Capabilities</code>)</em>' : '').'. That being said, you don\'t have to use all of the Membership Levels if you don\'t want to. To use only 1 or 2 of these Levels, just design your Membership Options Page, so it only includes Payment Buttons for the Levels being used.</p>'."\n";
|
615 |
+
echo (!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site()) ? '<p><em><strong>TIP:</strong> <strong>Unlimited Membership Levels</strong> are only possible with <a href="'.esc_attr(c_ws_plugin__s2member_readmes::parse_readme_value("Pro Module / Prices")).'" target="_blank" rel="external">s2Member Pro</a>. However, Custom Capabilities are possible in all versions of s2Member, including the free version. Custom Capabilities are a great way to extend s2Member in creative ways. If you\'re an advanced site owner, a theme designer, or a web developer integrating s2Member for a client, please check your Dashboard, under: <code>s2Member -› API Scripting -› Custom Capabilities</code>. We also recommend <a href="http://www.s2member.com/videos/A2C07377CF60025E/" target="_blank" rel="external">this video tutorial</a>.</em></p>'."\n" : '';
|
616 |
+
echo (!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site()) ? '<p><strong>See also:</strong> These KB articles: <a href="http://www.s2member.com/kb/roles-caps/" target="_blank" rel="external">s2Member Roles/Capabilities</a> and <a href="http://www.s2member.com/kb/simple-shortcode-conditionals/" target="_blank" rel="external">Simple Shortcode Conditionals</a>.</p>'."\n" : '';
|
617 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_membership_levels", get_defined_vars());
|
618 |
+
|
619 |
+
echo '<table class="form-table">'."\n";
|
620 |
+
echo '<tbody>'."\n";
|
621 |
+
|
622 |
+
for($n = 0; $n <= $GLOBALS["WS_PLUGIN__"]["s2member"]["c"]["levels"]; $n++)
|
623 |
+
{
|
624 |
+
echo '<tr>'."\n";
|
625 |
+
|
626 |
+
echo '<th>'."\n";
|
627 |
+
echo '<label for="ws-plugin--s2member-level'.$n.'-label">'."\n";
|
628 |
+
echo ($n === 0) ? 'Level #'.$n.' <em>(Free Subscribers)</em>:'."\n" : 'Level #'.$n.' Members:'."\n";
|
629 |
+
echo '</label>'."\n";
|
630 |
+
echo '</th>'."\n";
|
631 |
+
|
632 |
+
echo '</tr>'."\n";
|
633 |
+
echo '<tr>'."\n";
|
634 |
|
635 |
+
echo '<td>'."\n";
|
636 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_level'.$n.'_label" id="ws-plugin--s2member-level'.$n.'-label" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["level".$n."_label"]).'" /><br />'."\n";
|
637 |
+
echo 'This is the Label for Level #'.$n.(($n === 0) ? ' (Free Subscribers)' : ' Members').'.<br />'."\n";
|
638 |
+
echo '</td>'."\n";
|
639 |
|
640 |
+
echo '</tr>'."\n";
|
641 |
+
}
|
642 |
|
643 |
+
echo '</tbody>'."\n";
|
644 |
+
echo '</table>'."\n";
|
645 |
+
|
646 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
647 |
+
|
648 |
+
echo '<table class="form-table" style="margin-top:0;">'."\n";
|
649 |
+
echo '<tbody>'."\n";
|
650 |
+
echo '<tr>'."\n";
|
651 |
+
|
652 |
+
echo '<th style="padding-top:0;">'."\n";
|
653 |
+
echo '<label for="ws-plugin--s2member-apply-label-translations">'."\n";
|
654 |
+
echo 'Force WordPress to use your Labels?'."\n";
|
655 |
+
echo '</label>'."\n";
|
656 |
+
echo '</th>'."\n";
|
657 |
+
|
658 |
+
echo '</tr>'."\n";
|
659 |
+
echo '<tr>'."\n";
|
660 |
|
661 |
+
echo '<td>'."\n";
|
662 |
+
echo '<input type="radio" name="ws_plugin__s2member_apply_label_translations" id="ws-plugin--s2member-apply-label-translations-0" value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["apply_label_translations"]) ? ' checked="checked"' : '').' /> <label for="ws-plugin--s2member-apply-label-translations-0">No</label> <input type="radio" name="ws_plugin__s2member_apply_label_translations" id="ws-plugin--s2member-apply-label-translations-1" value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["apply_label_translations"]) ? ' checked="checked"' : '').' /> <label for="ws-plugin--s2member-apply-label-translations-1">Yes, force WordPress to use my Labels.</label><br />'."\n";
|
663 |
+
echo 'This affects your administrative Dashboard only <em>(i.e. your list of Users)</em>.<br />s2Member can force WordPress to use your Labels instead of referencing Roles by `s2Member Level #`. If this is your first installation of s2Member, we suggest leaving this set to <code>no</code> until you\'ve had a chance to get acclimated with s2Member\'s functionality. In fact, many site owners choose to leave this off, because they find it less confusing when Roles are referred to by their s2Member Level #.'."\n";
|
664 |
+
echo '</td>'."\n";
|
665 |
+
|
666 |
+
echo '</tr>'."\n";
|
667 |
+
echo '</tbody>'."\n";
|
668 |
+
echo '</table>'."\n";
|
669 |
|
670 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
671 |
|
672 |
+
echo '<input type="button" value="Reset Roles/Capabilities" class="ws-menu-page-right ws-plugin--s2member-reset-roles-button" style="min-width:175px;" />'."\n";
|
673 |
+
echo '<p>The button to the right, is a nifty tool, which allows you to reset s2Member\'s internal Roles and Capabilities that integrate with WordPress. If you, or a developer working with you, has made attempts to alter the default <em>internal</em> Role/Capability sets that come with s2Member, and you need to reset them back to the way s2Member expects them to be, please use this tool. <em>Attn Developers: it is also possible lock-in your modified Roles/Capabilities with an s2Member Filter. Please see <a href="http://www.s2member.com/kb/roles-caps/#modifying-roles-caps" target="_blank" rel="external">this KB article for details</a>.</em></p>'."\n";
|
674 |
|
675 |
+
echo '</div>'."\n";
|
676 |
|
677 |
+
echo '</div>'."\n";
|
678 |
|
679 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_membership_levels", get_defined_vars());
|
680 |
+
}
|
681 |
|
682 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_login_registration", TRUE, get_defined_vars()))
|
683 |
+
{
|
684 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_login_registration", get_defined_vars());
|
685 |
|
686 |
+
echo '<div class="ws-menu-page-group" title="Login/Registration Design">'."\n";
|
687 |
|
688 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-login-registration-section">'."\n";
|
689 |
+
echo '<h3>Login/Registration Page Customization (optional)</h3>'."\n";
|
690 |
+
echo '<p>These settings customize your Standard Login/Registration Pages:<br />(<a href="'.esc_attr(c_ws_plugin__s2member_utils_urls::wp_register_url()).'" target="_blank" rel="external" onclick="alert(\'s2Member will now open your Standard Registration Form.\\n* s2Member makes this form available to logged-in Administrators, at all times (for testing purposes), regardless of configuration.'.((c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '\\n\\nBuddyPress: * BuddyPress will use its own Registration Form. Please note, you will probably be redirected away from the BuddyPress Registration Form ( '.c_ws_plugin__s2member_utils_strings::esc_js_sq(c_ws_plugin__s2member_utils_urls::bp_register_url()).' ), because you\\\'re ALREADY logged-in. Please log out before testing BuddyPress registration.' : '').'\');">'.esc_html(c_ws_plugin__s2member_utils_urls::wp_register_url()).'</a>)</p>'."\n";
|
691 |
+
echo (is_multisite() && c_ws_plugin__s2member_utils_conds::is_multisite_farm() && is_main_site()) ? '<p><em>The Main Site of a Multisite Blog Farm uses this Form instead, powered by your theme.<br />(<a href="'.esc_attr(c_ws_plugin__s2member_utils_urls::wp_signup_url()).'" target="_blank" rel="external" onclick="alert(\'s2Member will now open your Multisite Registration Form.\\n* s2Member makes this form available to logged-in Super Administrators, at all times (for testing purposes), regardless of configuration.'.((c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '\\n\\nBuddyPress: * BuddyPress will use its own Registration Form. Please note, you will probably be redirected away from the BuddyPress Registration Form ( '.c_ws_plugin__s2member_utils_strings::esc_js_sq(c_ws_plugin__s2member_utils_urls::bp_register_url()).' ), because you\\\'re ALREADY logged-in. Please log out before testing BuddyPress registration.' : '').'\');">'.esc_html(c_ws_plugin__s2member_utils_urls::wp_signup_url()).'</a>)</em></p>'."\n" : '';
|
692 |
+
echo (c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '<p><em><strong>BuddyPress:</strong> BuddyPress will use its own Registration Form, powered by your theme.<br />(<a href="'.esc_attr(c_ws_plugin__s2member_utils_urls::bp_register_url()).'" target="_blank" rel="external" onclick="alert(\'s2Member will now open your BuddyPress Registration Form.\\n* However, you will probably be redirected away from this BuddyPress Registration Form ( '.c_ws_plugin__s2member_utils_strings::esc_js_sq(c_ws_plugin__s2member_utils_urls::bp_register_url()).' ), because you\\\'re ALREADY logged-in. Please log out before testing BuddyPress registration.\');">'.esc_html(c_ws_plugin__s2member_utils_urls::bp_register_url()).'</a>)</em></p>'."\n" : '';
|
693 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_login_registration", get_defined_vars());
|
694 |
|
695 |
+
echo '<table class="form-table">'."\n";
|
696 |
+
echo '<tbody>'."\n";
|
697 |
+
echo '<tr>'."\n";
|
698 |
|
699 |
+
echo '<td>'."\n";
|
700 |
+
echo '<h3 style="margin:0;">Enable This Functionality?</h3>'."\n";
|
701 |
+
echo '<select name="ws_plugin__s2member_login_reg_design_enabled" id="ws-plugin--s2member-login-reg-design-enabled">'."\n";
|
702 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_design_enabled"]) ? ' selected="selected"' : '').'>No (default, use WordPress defaults)</option>'."\n";
|
703 |
+
echo '<option value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_design_enabled"]) ? ' selected="selected"' : '').'>Yes (customize Login/Registration with s2Member)</option>'."\n";
|
704 |
+
echo '</select>'."\n";
|
705 |
+
echo '</td>'."\n";
|
706 |
|
707 |
+
echo '</tr>'."\n";
|
708 |
+
echo '</tbody>'."\n";
|
709 |
+
echo '</table>'."\n";
|
710 |
|
711 |
+
echo '<div id="ws-plugin--s2member-login-reg-design"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_design_enabled"]) ? ' style="display:none;"' : '').'>'."\n";
|
712 |
|
713 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
714 |
|
715 |
+
echo '<table class="form-table">'."\n";
|
716 |
+
echo '<tbody>'."\n";
|
717 |
+
echo '<tr>'."\n";
|
718 |
|
719 |
+
echo '<td>'."\n";
|
720 |
+
echo '<h3 style="margin:0;">Overall Font/Size Configuration</h3>'."\n";
|
721 |
+
echo '<p style="margin:0;">These settings are all focused on your Login/Registration Fonts.</p>'."\n";
|
722 |
+
echo '</td>'."\n";
|
723 |
|
724 |
+
echo '</tr>'."\n";
|
725 |
+
echo '<tr>'."\n";
|
726 |
|
727 |
+
echo '<th>'."\n";
|
728 |
+
echo '<label for="ws-plugin--s2member-login-reg-font-size">'."\n";
|
729 |
+
echo 'Overall Font Size:'."\n";
|
730 |
+
echo '</label>'."\n";
|
731 |
+
echo '</th>'."\n";
|
732 |
|
733 |
+
echo '</tr>'."\n";
|
734 |
+
echo '<tr>'."\n";
|
735 |
|
736 |
+
echo '<td>'."\n";
|
737 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_font_size" id="ws-plugin--s2member-login-reg-font-size" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_font_size"]).'" /><br />'."\n";
|
738 |
+
echo 'Set this to a numeric value, calculated in pixels.'."\n";
|
739 |
+
echo '</td>'."\n";
|
740 |
|
741 |
+
echo '</tr>'."\n";
|
742 |
+
echo '<tr>'."\n";
|
743 |
+
|
744 |
+
echo '<th>'."\n";
|
745 |
+
echo '<label for="ws-plugin--s2member-login-reg-font-family">'."\n";
|
746 |
+
echo 'Overall Font Family:'."\n";
|
747 |
+
echo '</label>'."\n";
|
748 |
+
echo '</th>'."\n";
|
749 |
+
|
750 |
+
echo '</tr>'."\n";
|
751 |
+
echo '<tr>'."\n";
|
752 |
+
|
753 |
+
echo '<td>'."\n";
|
754 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_font_family" id="ws-plugin--s2member-login-reg-font-family" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_font_family"]).'" /><br />'."\n";
|
755 |
+
echo 'Set this to a web-safe font family.'."\n";
|
756 |
+
echo '</td>'."\n";
|
757 |
+
|
758 |
+
echo '</tr>'."\n";
|
759 |
+
echo '<tr>'."\n";
|
760 |
+
|
761 |
+
echo '<th>'."\n";
|
762 |
+
echo '<label for="ws-plugin--s2member-login-reg-font-field-size">'."\n";
|
763 |
+
echo 'Form Field Font Size:'."\n";
|
764 |
+
echo '</label>'."\n";
|
765 |
+
echo '</th>'."\n";
|
766 |
+
|
767 |
+
echo '</tr>'."\n";
|
768 |
+
echo '<tr>'."\n";
|
769 |
+
|
770 |
+
echo '<td>'."\n";
|
771 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_font_field_size" id="ws-plugin--s2member-login-reg-font-field-size" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_font_field_size"]).'" /><br />'."\n";
|
772 |
+
echo 'Set this to a numeric value, calculated in pixels.'."\n";
|
773 |
+
echo '</td>'."\n";
|
774 |
+
|
775 |
+
echo '</tr>'."\n";
|
776 |
+
echo '</tbody>'."\n";
|
777 |
+
echo '</table>'."\n";
|
778 |
+
|
779 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
780 |
+
|
781 |
+
echo '<table class="form-table" style="margin-top:0;">'."\n";
|
782 |
+
echo '<tbody>'."\n";
|
783 |
+
echo '<tr>'."\n";
|
784 |
+
|
785 |
+
echo '<td>'."\n";
|
786 |
+
echo '<h3 style="margin:0;">Background Configuration</h3>'."\n";
|
787 |
+
echo '<p style="margin:0;">These settings are all focused on your Login/Registration Background.</p>'."\n";
|
788 |
+
echo '</td>'."\n";
|
789 |
+
|
790 |
+
echo '</tr>'."\n";
|
791 |
+
echo '<tr>'."\n";
|
792 |
+
|
793 |
+
echo '<th>'."\n";
|
794 |
+
echo '<label for="ws-plugin--s2member-login-reg-background-color">'."\n";
|
795 |
+
echo 'Background Color:'."\n";
|
796 |
+
echo '</label>'."\n";
|
797 |
+
echo '</th>'."\n";
|
798 |
+
|
799 |
+
echo '</tr>'."\n";
|
800 |
+
echo '<tr>'."\n";
|
801 |
+
|
802 |
+
echo '<td>'."\n";
|
803 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_background_color" id="ws-plugin--s2member-login-reg-background-color" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_background_color"]).'" /><br />'."\n";
|
804 |
+
echo 'Set this to a 6-digit hex color code.'."\n";
|
805 |
+
echo '</td>'."\n";
|
806 |
+
|
807 |
+
echo '</tr>'."\n";
|
808 |
+
echo '<tr>'."\n";
|
809 |
+
|
810 |
+
echo '<th>'."\n";
|
811 |
+
echo '<label for="ws-plugin--s2member-login-reg-background-image">'."\n";
|
812 |
+
echo 'Background Image:'."\n";
|
813 |
+
echo '</label>'."\n";
|
814 |
+
echo '</th>'."\n";
|
815 |
+
|
816 |
+
echo '</tr>'."\n";
|
817 |
+
echo '<tr>'."\n";
|
818 |
+
|
819 |
+
echo '<td>'."\n";
|
820 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_background_image" id="ws-plugin--s2member-login-reg-background-image" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_background_image"]).'" /><br />'."\n";
|
821 |
+
echo '<input type="button" id="ws-plugin--s2member-login-reg-background-image-media-btn" value="Open Media Library" class="ws-menu-page-media-btn" rel="ws-plugin--s2member-login-reg-background-image" />'."\n";
|
822 |
+
echo 'Set this to the URL of your Background Image. (this is optional)<br />';
|
823 |
+
echo 'If supplied, your Background Image will be tiled.'."\n";
|
824 |
+
echo '</td>'."\n";
|
825 |
+
|
826 |
+
echo '</tr>'."\n";
|
827 |
+
echo '<tr>'."\n";
|
828 |
+
|
829 |
+
echo '<th>'."\n";
|
830 |
+
echo '<label for="ws-plugin--s2member-login-reg-background-image-repeat">'."\n";
|
831 |
+
echo 'Background Image Tile:'."\n";
|
832 |
+
echo '</label>'."\n";
|
833 |
+
echo '</th>'."\n";
|
834 |
+
|
835 |
+
echo '</tr>'."\n";
|
836 |
+
echo '<tr>'."\n";
|
837 |
+
|
838 |
+
echo '<td>'."\n";
|
839 |
+
echo '<select name="ws_plugin__s2member_login_reg_background_image_repeat" id="ws-plugin--s2member-login-reg-background-image-repeat">'."\n";
|
840 |
+
echo '<option value="repeat"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_background_image_repeat"] === "repeat") ? ' selected="selected"' : '').'>Seamless Tile ( background-repeat: repeat; )</option>'."\n";
|
841 |
+
echo '<option value="repeat-x"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_background_image_repeat"] === "repeat-x") ? ' selected="selected"' : '').'>Tile Horizontally ( background-repeat: repeat-x; )</option>'."\n";
|
842 |
+
echo '<option value="repeat-y"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_background_image_repeat"] === "repeat-y") ? ' selected="selected"' : '').'>Tile Vertically ( background-repeat: repeat-y; )</option>'."\n";
|
843 |
+
echo '<option value="no-repeat"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_background_image_repeat"] === "no-repeat") ? ' selected="selected"' : '').'>No Tiles ( background-repeat: no-repeat; )</option>'."\n";
|
844 |
+
echo '</select><br />'."\n";
|
845 |
+
echo 'This controls the way your Background Image is styled with CSS. [ <a href="http://www.w3schools.com/css/pr_background-repeat.asp" target="_blank" rel="external">learn more</a> ]'."\n";
|
846 |
+
echo '</td>'."\n";
|
847 |
+
|
848 |
+
echo '</tr>'."\n";
|
849 |
+
echo '<tr>'."\n";
|
850 |
+
|
851 |
+
echo '<th>'."\n";
|
852 |
+
echo '<label for="ws-plugin--s2member-login-reg-background-text-color">'."\n";
|
853 |
+
echo 'Color of Text on top of your Background:'."\n";
|
854 |
+
echo '</label>'."\n";
|
855 |
+
echo '</th>'."\n";
|
856 |
+
|
857 |
+
echo '</tr>'."\n";
|
858 |
+
echo '<tr>'."\n";
|
859 |
+
|
860 |
+
echo '<td>'."\n";
|
861 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_background_text_color" id="ws-plugin--s2member-login-reg-background-text-color" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_background_text_color"]).'" /><br />'."\n";
|
862 |
+
echo 'Set this to a 6-digit hex color code.'."\n";
|
863 |
+
echo '</td>'."\n";
|
864 |
+
|
865 |
+
echo '</tr>'."\n";
|
866 |
+
echo '<tr>'."\n";
|
867 |
+
|
868 |
+
echo '<th>'."\n";
|
869 |
+
echo '<label for="ws-plugin--s2member-login-reg-background-text-shadow-color">'."\n";
|
870 |
+
echo 'Shadow Color for Text on top of your Background:'."\n";
|
871 |
+
echo '</label>'."\n";
|
872 |
+
echo '</th>'."\n";
|
873 |
+
|
874 |
+
echo '</tr>'."\n";
|
875 |
+
echo '<tr>'."\n";
|
876 |
+
|
877 |
+
echo '<td>'."\n";
|
878 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_background_text_shadow_color" id="ws-plugin--s2member-login-reg-background-text-shadow-color" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_background_text_shadow_color"]).'" /><br />'."\n";
|
879 |
+
echo 'Set this to a 6-digit hex color code.'."\n";
|
880 |
+
echo '</td>'."\n";
|
881 |
+
|
882 |
+
echo '</tr>'."\n";
|
883 |
+
echo '<tr>'."\n";
|
884 |
+
|
885 |
+
echo '<th>'."\n";
|
886 |
+
echo '<label for="ws-plugin--s2member-login-reg-background-box-shadow-color">'."\n";
|
887 |
+
echo 'Shadow Color for Boxes on top of your Background:'."\n";
|
888 |
+
echo '</label>'."\n";
|
889 |
+
echo '</th>'."\n";
|
890 |
+
|
891 |
+
echo '</tr>'."\n";
|
892 |
+
echo '<tr>'."\n";
|
893 |
+
|
894 |
+
echo '<td>'."\n";
|
895 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_background_box_shadow_color" id="ws-plugin--s2member-login-reg-background-box-shadow-color" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_background_box_shadow_color"]).'" /><br />'."\n";
|
896 |
+
echo 'Set this to a 6-digit hex color code.'."\n";
|
897 |
+
echo '</td>'."\n";
|
898 |
+
|
899 |
+
echo '</tr>'."\n";
|
900 |
+
echo '</tbody>'."\n";
|
901 |
+
echo '</table>'."\n";
|
902 |
+
|
903 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
904 |
+
|
905 |
+
echo '<table class="form-table" style="margin-top:0;">'."\n";
|
906 |
+
echo '<tbody>'."\n";
|
907 |
+
echo '<tr>'."\n";
|
908 |
+
|
909 |
+
echo '<td>'."\n";
|
910 |
+
echo '<h3 style="margin:0;">Logo Image Configuration</h3>'."\n";
|
911 |
+
echo '<p style="margin:0;">These settings are all focused on your Login/Registration Logo.</p>'."\n";
|
912 |
+
echo '</td>'."\n";
|
913 |
+
|
914 |
+
echo '</tr>'."\n";
|
915 |
+
echo '<tr>'."\n";
|
916 |
+
|
917 |
+
echo '<th>'."\n";
|
918 |
+
echo '<label for="ws-plugin--s2member-login-reg-logo-src">'."\n";
|
919 |
+
echo 'Logo Image Location:'."\n";
|
920 |
+
echo '</label>'."\n";
|
921 |
+
echo '</th>'."\n";
|
922 |
+
|
923 |
+
echo '</tr>'."\n";
|
924 |
+
echo '<tr>'."\n";
|
925 |
+
|
926 |
+
echo '<td>'."\n";
|
927 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_logo_src" id="ws-plugin--s2member-login-reg-logo-src" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_logo_src"]).'" /><br />'."\n";
|
928 |
+
echo '<input type="button" id="ws-plugin--s2member-login-reg-logo-src-media-btn" value="Open Media Library" class="ws-menu-page-media-btn" rel="ws-plugin--s2member-login-reg-logo-src" />'."\n";
|
929 |
+
echo 'Set this to the URL of your Logo Image.<br />'."\n";
|
930 |
+
echo 'Suggested size is around 500 x 100.'."\n";
|
931 |
+
echo '</td>'."\n";
|
932 |
+
|
933 |
+
echo '</tr>'."\n";
|
934 |
+
echo '<tr>'."\n";
|
935 |
+
|
936 |
+
echo '<th>'."\n";
|
937 |
+
echo '<label for="ws-plugin--s2member-login-reg-logo-src-width">'."\n";
|
938 |
+
echo 'Logo Image Width:'."\n";
|
939 |
+
echo '</label>'."\n";
|
940 |
+
echo '</th>'."\n";
|
941 |
+
|
942 |
+
echo '</tr>'."\n";
|
943 |
+
echo '<tr>'."\n";
|
944 |
+
|
945 |
+
echo '<td>'."\n";
|
946 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_logo_src_width" id="ws-plugin--s2member-login-reg-logo-src-width" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_logo_src_width"]).'" /><br />'."\n";
|
947 |
+
echo 'The pixel Width of your Logo Image. <em>* This ALSO affects the overall width of your Login/Registration forms. If you want wider form fields, use a wider Logo.</em>'."\n";
|
948 |
+
echo '</td>'."\n";
|
949 |
+
|
950 |
+
echo '</tr>'."\n";
|
951 |
+
echo '<tr>'."\n";
|
952 |
+
|
953 |
+
echo '<th>'."\n";
|
954 |
+
echo '<label for="ws-plugin--s2member-login-reg-logo-src-height">'."\n";
|
955 |
+
echo 'Logo Image Height:'."\n";
|
956 |
+
echo '</label>'."\n";
|
957 |
+
echo '</th>'."\n";
|
958 |
+
|
959 |
+
echo '</tr>'."\n";
|
960 |
+
echo '<tr>'."\n";
|
961 |
+
|
962 |
+
echo '<td>'."\n";
|
963 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_logo_src_height" id="ws-plugin--s2member-login-reg-logo-src-height" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_logo_src_height"]).'" /><br />'."\n";
|
964 |
+
echo 'The pixel Height of your Logo Image.'."\n";
|
965 |
+
echo '</td>'."\n";
|
966 |
+
|
967 |
+
echo '</tr>'."\n";
|
968 |
+
echo '<tr>'."\n";
|
969 |
+
|
970 |
+
echo '<th>'."\n";
|
971 |
+
echo '<label for="ws-plugin--s2member-login-reg-logo-url">'."\n";
|
972 |
+
echo 'Logo Image Click URL:'."\n";
|
973 |
+
echo '</label>'."\n";
|
974 |
+
echo '</th>'."\n";
|
975 |
+
|
976 |
+
echo '</tr>'."\n";
|
977 |
+
echo '<tr>'."\n";
|
978 |
+
|
979 |
+
echo '<td>'."\n";
|
980 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_logo_url" id="ws-plugin--s2member-login-reg-logo-url" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_logo_url"]).'" /><br />'."\n";
|
981 |
+
echo 'Set this to the Click URL for your Logo Image.'."\n";
|
982 |
+
echo '</td>'."\n";
|
983 |
+
|
984 |
+
echo '</tr>'."\n";
|
985 |
+
echo '<tr>'."\n";
|
986 |
+
|
987 |
+
echo '<th>'."\n";
|
988 |
+
echo '<label for="ws-plugin--s2member-login-reg-logo-title">'."\n";
|
989 |
+
echo 'Logo Image Title Attribute:'."\n";
|
990 |
+
echo '</label>'."\n";
|
991 |
+
echo '</th>'."\n";
|
992 |
+
|
993 |
+
echo '</tr>'."\n";
|
994 |
+
echo '<tr>'."\n";
|
995 |
+
|
996 |
+
echo '<td>'."\n";
|
997 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_reg_logo_title" id="ws-plugin--s2member-login-reg-logo-title" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_logo_title"]).'" /><br />'."\n";
|
998 |
+
echo 'Used as the <code>title=""</code> attribute for your Logo Image.'."\n";
|
999 |
+
echo '</td>'."\n";
|
1000 |
+
|
1001 |
+
echo '</tr>'."\n";
|
1002 |
+
echo '</tbody>'."\n";
|
1003 |
+
echo '</table>'."\n";
|
1004 |
+
|
1005 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
1006 |
+
|
1007 |
+
echo '<table class="form-table" style="margin-top:0;">'."\n";
|
1008 |
+
echo '<tbody>'."\n";
|
1009 |
+
echo '<tr>'."\n";
|
1010 |
+
|
1011 |
+
echo '<th>'."\n";
|
1012 |
+
echo '<label for="ws-plugin--s2member-login-reg-footer-backtoblog">'."\n";
|
1013 |
+
echo 'Display [Back to Home Page] Link At Bottom?'."\n";
|
1014 |
+
echo '</label>'."\n";
|
1015 |
+
echo '</th>'."\n";
|
1016 |
+
|
1017 |
+
echo '</tr>'."\n";
|
1018 |
+
echo '<tr>'."\n";
|
1019 |
+
|
1020 |
+
echo '<td>'."\n";
|
1021 |
+
echo '<select name="ws_plugin__s2member_login_reg_footer_backtoblog" id="ws-plugin--s2member-login-reg-footer-backtoblog">'."\n";
|
1022 |
+
echo '<option value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_footer_backtoblog"]) ? ' selected="selected"' : '').'>Yes, display link at bottom pointing visitors back to the home page</option>'."\n";
|
1023 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_footer_backtoblog"]) ? ' selected="selected"' : '').'>No, hide this link (I\'ll create my own custom footer w/ the details I prefer)</option>'."\n";
|
1024 |
+
echo '</select>'."\n";
|
1025 |
+
echo '</td>'."\n";
|
1026 |
+
|
1027 |
+
echo '</tr>'."\n";
|
1028 |
+
echo '<tr>'."\n";
|
1029 |
+
|
1030 |
+
echo '<td>'."\n";
|
1031 |
+
echo '<h3 style="margin:0;">Footer Design (i.e. Bottom)</h3>'."\n";
|
1032 |
+
echo '<p style="margin:0;">This field accepts raw HTML'.((!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site()) ? ' (and/or PHP)' : '').' code.</p>'."\n";
|
1033 |
+
echo '</td>'."\n";
|
1034 |
+
|
1035 |
+
echo '</tr>'."\n";
|
1036 |
+
echo '<tr>'."\n";
|
1037 |
+
|
1038 |
+
echo '<th>'."\n";
|
1039 |
+
echo '<label for="ws-plugin--s2member-login-reg-footer-design">'."\n";
|
1040 |
+
echo 'Login/Registration Footer Design (optional):'."\n";
|
1041 |
+
echo '</label>'."\n";
|
1042 |
+
echo '</th>'."\n";
|
1043 |
+
|
1044 |
+
echo '</tr>'."\n";
|
1045 |
+
echo '<tr>'."\n";
|
1046 |
+
|
1047 |
+
echo '<td>'."\n";
|
1048 |
+
echo '<textarea name="ws_plugin__s2member_login_reg_footer_design" id="ws-plugin--s2member-login-reg-footer-design" rows="3" wrap="off" spellcheck="false">'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_reg_footer_design"]).'</textarea><br />'."\n";
|
1049 |
+
echo 'This optional HTML'.((!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site()) ? ' (and/or PHP)' : '').' code will appear at the very bottom of your Login/Registration Forms.'."\n";
|
1050 |
+
echo '</td>'."\n";
|
1051 |
+
|
1052 |
+
echo '</tr>'."\n";
|
1053 |
+
echo '</tbody>'."\n";
|
1054 |
+
echo '</table>'."\n";
|
1055 |
+
echo '</div>'."\n";
|
1056 |
+
|
1057 |
+
echo '</div>'."\n";
|
1058 |
+
|
1059 |
+
echo '</div>'."\n";
|
1060 |
+
|
1061 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_login_registration", get_defined_vars());
|
1062 |
+
}
|
1063 |
+
|
1064 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_custom_reg_fields", TRUE, get_defined_vars()))
|
1065 |
+
{
|
1066 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_custom_reg_fields", get_defined_vars());
|
1067 |
+
|
1068 |
+
echo '<div class="ws-menu-page-group" title="Registration/Profile Fields & Options">'."\n";
|
1069 |
+
|
1070 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-custom-reg-fields-section">'."\n";
|
1071 |
+
echo '<h3>Custom Registration/Profile Fields (optional, for further customization)</h3>'."\n";
|
1072 |
+
echo '<p>Some fields are already built-in by default. The defaults are: <code>*Username*, *Email*, *First Name*, *Last Name*</code>.</p>'."\n";
|
1073 |
+
|
1074 |
+
echo '<p>Custom Fields will appear in your Standard Registration Form, and in User/Member Profiles:<br />(<a href="'.esc_attr(c_ws_plugin__s2member_utils_urls::wp_register_url()).'" target="_blank" rel="external" onclick="alert(\'s2Member will now open your Standard Registration Form.\\n* s2Member makes this form available to logged-in Administrators, at all times (for testing purposes), regardless of configuration.'.((c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '\\n\\nBuddyPress: * BuddyPress will use its own Registration Form. Please note, you will probably be redirected away from the BuddyPress Registration Form ( '.c_ws_plugin__s2member_utils_strings::esc_js_sq(c_ws_plugin__s2member_utils_urls::bp_register_url()).' ), because you\\\'re ALREADY logged-in. Please log out before testing BuddyPress registration.' : '').'\');">'.esc_html(c_ws_plugin__s2member_utils_urls::wp_register_url()).'</a>)</p>'."\n";
|
1075 |
+
echo (is_multisite() && c_ws_plugin__s2member_utils_conds::is_multisite_farm() && is_main_site()) ? '<p><em>The Main Site of a Multisite Blog Farm uses this Form. s2Member supports Custom Fields here too.<br />(<a href="'.esc_attr(c_ws_plugin__s2member_utils_urls::wp_signup_url()).'" target="_blank" rel="external" onclick="alert(\'s2Member will now open your Multisite Registration Form.\\n* s2Member makes this form available to logged-in Super Administrators, at all times (for testing purposes), regardless of configuration.'.((c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '\\n\\nBuddyPress: * BuddyPress will use its own Registration Form. Please note, you will probably be redirected away from the BuddyPress Registration Form ( '.c_ws_plugin__s2member_utils_strings::esc_js_sq(c_ws_plugin__s2member_utils_urls::bp_register_url()).' ), because you\\\'re ALREADY logged-in. Please log out before testing BuddyPress registration.' : '').'\');">'.esc_html(c_ws_plugin__s2member_utils_urls::wp_signup_url()).'</a>)</em></p>'."\n" : '';
|
1076 |
+
echo (c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '<p><em><strong>BuddyPress:</strong> BuddyPress will use its own Registration Form <a href="'.esc_attr(c_ws_plugin__s2member_utils_urls::bp_register_url()).'" target="_blank" rel="external" onclick="alert(\'s2Member will now open your BuddyPress Registration Form.\\n* However, you will probably be redirected away from this BuddyPress Registration Form ( '.c_ws_plugin__s2member_utils_strings::esc_js_sq(c_ws_plugin__s2member_utils_urls::bp_register_url()).' ), because you\\\'re ALREADY logged-in. Please log out before testing BuddyPress registration.\');">here</a>.<br />s2Member can integrate your Custom Fields with BuddyPress too, please see options below.</em></p>'."\n" : '';
|
1077 |
+
echo '<p><strong>Regarding registration...</strong> Custom Fields do NOT appear during repeat registration and/or checkout attempts (e.g. they do NOT appear for any user that is currently logged into the site). Please make sure that you test registration and/or checkout forms while NOT logged in (e.g. please test as a first-time customer). Existing users/members/customers may update Custom Fields by editing their Profile.</p>'."\n";
|
1078 |
+
|
1079 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_custom_reg_fields", get_defined_vars());
|
1080 |
+
|
1081 |
+
echo '<table class="form-table">'."\n";
|
1082 |
+
echo '<tbody>'."\n";
|
1083 |
+
echo '<tr>'."\n";
|
1084 |
+
|
1085 |
+
echo '<th>'."\n";
|
1086 |
+
echo '<label>'."\n";
|
1087 |
+
echo 'Custom Registration/Profile Fields:'."\n";
|
1088 |
+
echo '</label>'."\n";
|
1089 |
+
echo '</th>'."\n";
|
1090 |
+
|
1091 |
+
echo '</tr>'."\n";
|
1092 |
+
echo '<tr>'."\n";
|
1093 |
+
|
1094 |
+
echo '<td>'."\n";
|
1095 |
+
echo '<input type="hidden" name="ws_plugin__s2member_custom_reg_fields" id="ws-plugin--s2member-custom-reg-fields" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["custom_reg_fields"]).'" />'."\n";
|
1096 |
+
echo '<div id="ws-plugin--s2member-custom-reg-field-configuration"></div>'."\n"; // This is filled by JavaScript routines.
|
1097 |
+
echo '</td>'."\n";
|
1098 |
+
|
1099 |
+
echo '</tr>'."\n";
|
1100 |
+
echo '<tr>'."\n";
|
1101 |
+
|
1102 |
+
echo '<th>'."\n";
|
1103 |
+
echo '<label for="ws-plugin--s2member-custom-reg-names">'."\n";
|
1104 |
+
echo 'Collect First/Last Names during Registration?'."\n";
|
1105 |
+
echo '</label>'."\n";
|
1106 |
+
echo '</th>'."\n";
|
1107 |
+
|
1108 |
+
echo '</tr>'."\n";
|
1109 |
+
echo '<tr>'."\n";
|
1110 |
+
|
1111 |
+
echo '<td>'."\n";
|
1112 |
+
echo '<select name="ws_plugin__s2member_custom_reg_names" id="ws-plugin--s2member-custom-reg-names">'."\n";
|
1113 |
+
echo '<option value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["custom_reg_password"]) ? ' selected="selected"' : '').'>Yes (always collect First/Last Names during registration)</option>'."\n";
|
1114 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["custom_reg_names"]) ? ' selected="selected"' : '').'>No (do NOT collect First/Last Names during registration)</option>'."\n";
|
1115 |
+
echo '</select><br />'."\n";
|
1116 |
+
echo 'Recommended setting (<code>Yes</code>). It\'s usually a good idea to leave this on.'."\n";
|
1117 |
+
echo (c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '<br /><em>* Has NO affect on BuddyPress registration form (BuddyPress always collects a full <code>Name</code> field).</em>'."\n" : '';
|
1118 |
+
echo (c_ws_plugin__s2member_utils_conds::pro_is_installed()) ? '<br /><em>* s2Member Pro (Checkout) Forms always require a First/Last Name for billing.</em>'."\n" : '';
|
1119 |
+
echo '</td>'."\n";
|
1120 |
+
|
1121 |
+
echo '</tr>'."\n";
|
1122 |
+
echo '<tr>'."\n";
|
1123 |
+
|
1124 |
+
echo '<th>'."\n";
|
1125 |
+
echo '<label for="ws-plugin--s2member-custom-reg-display-name">'."\n";
|
1126 |
+
echo 'Set "Display Name" during Registration?'."\n";
|
1127 |
+
echo '</label>'."\n";
|
1128 |
+
echo '</th>'."\n";
|
1129 |
+
|
1130 |
+
echo '</tr>'."\n";
|
1131 |
+
echo '<tr>'."\n";
|
1132 |
+
|
1133 |
+
echo '<td>'."\n";
|
1134 |
+
echo '<select name="ws_plugin__s2member_custom_reg_display_name" id="ws-plugin--s2member-custom-reg-display-name">'."\n";
|
1135 |
+
echo '<option value="full"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["custom_reg_display_name"] === "full") ? ' selected="selected"' : '').'>Yes (set Display Name to User\'s Full Name)</option>'."\n";
|
1136 |
+
echo '<option value="first"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["custom_reg_display_name"] === "first") ? ' selected="selected"' : '').'>Yes (set Display Name to User\'s First Name)</option>'."\n";
|
1137 |
+
echo '<option value="last"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["custom_reg_display_name"] === "last") ? ' selected="selected"' : '').'>Yes (set Display Name to User\'s Last Name)</option>'."\n";
|
1138 |
+
echo '<option value="login"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["custom_reg_display_name"] === "login") ? ' selected="selected"' : '').'>Yes (set Display Name to User\'s Username)</option>'."\n";
|
1139 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["custom_reg_display_name"]) ? ' selected="selected"' : '').'>No (leave Display Name at default WordPress value)</option>'."\n";
|
1140 |
+
echo '</select>'."\n";
|
1141 |
+
echo (c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '<br /><em>* Has NO affect on BuddyPress registration form (BuddyPress always uses its full <code>Name</code> field).</em>'."\n" : '';
|
1142 |
+
echo '</td>'."\n";
|
1143 |
+
|
1144 |
+
echo '</tr>'."\n";
|
1145 |
+
echo '<tr>'."\n";
|
1146 |
+
|
1147 |
+
echo '<th>'."\n";
|
1148 |
+
echo '<label for="ws-plugin--s2member-custom-reg-password">'."\n";
|
1149 |
+
echo 'Allow Custom Passwords during Registration?'."\n";
|
1150 |
+
echo '</label>'."\n";
|
1151 |
+
echo '</th>'."\n";
|
1152 |
+
|
1153 |
+
echo '</tr>'."\n";
|
1154 |
+
echo '<tr>'."\n";
|
1155 |
+
|
1156 |
+
echo '<td>'."\n";
|
1157 |
+
echo '<select name="ws_plugin__s2member_custom_reg_password" id="ws-plugin--s2member-custom-reg-password"'.((is_multisite() && c_ws_plugin__s2member_utils_conds::is_multisite_farm() && is_main_site() && !c_ws_plugin__s2member_utils_conds::pro_is_installed()) ? ' disabled="disabled"' : '').'>'."\n";
|
1158 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["custom_reg_password"]) ? ' selected="selected"' : '').'>No (send auto-generated passwords via email; after registration)</option>'."\n";
|
1159 |
+
echo '<option value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["custom_reg_password"]) ? ' selected="selected"' : '').'>Yes (allow members to create their own password during registration)</option>'."\n";
|
1160 |
+
echo '</select><br />'."\n";
|
1161 |
+
echo 'Auto-generated Passwords are recommended for best security; because, this also serves as a form of email confirmation.'."\n";
|
1162 |
+
echo (is_multisite() && c_ws_plugin__s2member_utils_conds::is_multisite_farm() && is_main_site()) ? '<br /><em>* For security purposes, Custom Passwords are NOT possible on the Main Site of a Blog Farm. <a href="#" onclick="alert(\'For security purposes, Custom Passwords are NOT possible on the Main Site of a Blog Farm. A User MUST wait for the activation/confirmation email; where a randomly generated Password will be assigned. Please note, this limitation only affects your Main Site, via `/wp-signup.php`. In other words, your Customers (i.e. other Blog Owners) will still have the ability to allow Custom Passwords with s2Member. YOU are affected by this limitation, NOT them.\\n\\n* NOTE: s2Member (Pro) removes this limitation.\\nIf you install the s2Member Pro Module, you WILL be able to allow Custom Passwords through s2Member Pro Forms; even on a Multisite Blog Farm.\'); return false;" tabindex="-1">[?]</a></em>'."\n" : '';
|
1163 |
+
echo (c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '<br /><em>* Does NOT affect BuddyPress registration form (always <code>yes</code> with BuddyPress registration).</em>'."\n" : '';
|
1164 |
+
echo '</td>'."\n";
|
1165 |
+
|
1166 |
+
echo '</tr>'."\n";
|
1167 |
+
echo '<tr>'."\n";
|
1168 |
+
|
1169 |
+
echo '<th>'."\n";
|
1170 |
+
echo '<label for="ws-plugin--s2member-custom-reg-force-personal-emails">'."\n";
|
1171 |
+
echo 'Force Personal Emails during Registration?'."\n";
|
1172 |
+
echo '</label>'."\n";
|
1173 |
+
echo '</th>'."\n";
|
1174 |
+
|
1175 |
+
echo '</tr>'."\n";
|
1176 |
+
echo '<tr>'."\n";
|
1177 |
+
|
1178 |
+
echo '<td>'."\n";
|
1179 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_custom_reg_force_personal_emails" id="ws-plugin--s2member-custom-reg-force-personal-emails" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["custom_reg_force_personal_emails"]).'" /><br />'."\n";
|
1180 |
+
echo 'To force personal email addresses, provide a comma-delimited list of email users to reject. <a href="#" onclick="alert(\'s2Member will reject [user]@ (based on your configuration here). A JavaScript alert message will be issued, asking the User to, `please use a personal email address`.\'); return false;" tabindex="-1">[?]</a><br />'."\n";
|
1181 |
+
echo 'Ex: <code>info,help,admin,webmaster,hostmaster,sales,support,spam</code><br />'."\n";
|
1182 |
+
echo 'See: <a href="http://kb.mailchimp.com/article/what-role-addresses-does-mailchimp-specifically-block-from-bulk-importing/" target="_blank" rel="external">this article</a> for a more complete list.'."\n";
|
1183 |
+
echo (c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '<br /><em>* Affects BuddyPress registration form too.</em>'."\n" : '';
|
1184 |
+
echo '</td>'."\n";
|
1185 |
+
|
1186 |
+
echo '</tr>'."\n";
|
1187 |
+
echo '<tr>'."\n";
|
1188 |
+
|
1189 |
+
echo '<th>'."\n";
|
1190 |
+
echo '<label for="ws-plugin--s2member-custom-reg-fields-4bp">'."\n";
|
1191 |
+
echo 'Integrate Custom Registration/Profile Fields with BuddyPress?'."\n";
|
1192 |
+
echo '</label>'."\n";
|
1193 |
+
echo '</th>'."\n";
|
1194 |
+
|
1195 |
+
echo '</tr>'."\n";
|
1196 |
+
echo '<tr>'."\n";
|
1197 |
+
|
1198 |
+
echo '<td>'."\n";
|
1199 |
+
echo '<div class="ws-menu-page-scrollbox" style="height:65px;">'."\n";
|
1200 |
+
echo '<input type="hidden" name="ws_plugin__s2member_custom_reg_fields_4bp[]" value="update-signal"'.((!c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? ' disabled="disabled"' : '').' />'."\n";
|
1201 |
+
foreach(array("profile-view" => "Yes, integrate with BuddyPress Public Profiles.", "registration" => "Yes, integrate with BuddyPress Registration Form.", "profile" => "Yes, integrate with BuddyPress Profile Editing Panel.") as $ws_plugin__s2member_temp_s_value => $ws_plugin__s2member_temp_s_label)
|
1202 |
+
echo '<input type="checkbox" name="ws_plugin__s2member_custom_reg_fields_4bp[]" id="ws-plugin--s2member-custom-reg-fields-4bp-'.esc_attr(preg_replace("/[^a-z0-9_\-]/", "-", $ws_plugin__s2member_temp_s_value)).'" value="'.esc_attr($ws_plugin__s2member_temp_s_value).'"'.((in_array($ws_plugin__s2member_temp_s_value, $GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["custom_reg_fields_4bp"])) ? ' checked="checked"' : '').((!c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? ' disabled="disabled"' : '').' /> <label for="ws-plugin--s2member-custom-reg-fields-4bp-'.esc_attr(preg_replace("/[^a-z0-9_\-]/", "-", $ws_plugin__s2member_temp_s_value)).'">'.$ws_plugin__s2member_temp_s_label.'</label><br />'."\n";
|
1203 |
+
echo '</div>'."\n";
|
1204 |
+
echo (!c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '<em>* BuddyPress is NOT installed; which is perfectly OK. BuddyPress is NOT a requirement.</em>'."\n" : '<em>* The options above, make it possible to integrate Custom Registration/Profile Fields (i.e. those configured with s2Member) into BuddyPress as well. However, if you configure Profile Fields with BuddyPress, those will NOT be integrated with s2Member. Therefore, if you need Custom Registration/Profile Fields to work with both s2Member and with BuddyPress, please configure them with s2Member.</em>';
|
1205 |
+
echo '</td>'."\n";
|
1206 |
+
|
1207 |
+
echo '</tr>'."\n";
|
1208 |
+
echo '</tbody>'."\n";
|
1209 |
+
echo '</table>'."\n";
|
1210 |
+
echo '</div>'."\n";
|
1211 |
+
|
1212 |
+
echo '</div>'."\n";
|
1213 |
+
|
1214 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_custom_reg_fields", get_defined_vars());
|
1215 |
+
}
|
1216 |
+
|
1217 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_login_welcome_page", TRUE, get_defined_vars()))
|
1218 |
+
{
|
1219 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_login_welcome_page", get_defined_vars());
|
1220 |
+
|
1221 |
+
echo '<div class="ws-menu-page-group" title="Login Welcome Page">'."\n";
|
1222 |
+
|
1223 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-login-welcome-page-section">'."\n";
|
1224 |
+
echo '<h3>Login Welcome Page (required, please customize this)</h3>'."\n";
|
1225 |
+
echo '<p>Please create and/or choose an existing Page to use as the first page Members will see after logging in.</p>'."\n";
|
1226 |
+
echo (c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '<p><em><strong>BuddyPress:</strong> s2Member integrates with BuddyPress. Your Login Welcome Page affects BuddyPress too.</em></p>'."\n" : '';
|
1227 |
+
echo '<p><em><strong>*Tips*</strong> This special Page will be protected from public access (automatically) by s2Member. Also, please remember this option CANNOT be set to your Front Page (e.g. your Home Page), or to your Posts Page (e.g. your main Blog page). Please create a separate Page in WordPress & designate it here as your Login Welcome Page.</em></p>'."\n";
|
1228 |
+
echo '<p><strong>See also:</strong> This KB article: <a href="http://www.s2member.com/kb/customizing-your-lwp/" target="_blank" rel="external">Customizing Your Login Welcome Page</a>.</p>'."\n";
|
1229 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_login_welcome_page", get_defined_vars());
|
1230 |
+
|
1231 |
+
echo '<table class="form-table">'."\n";
|
1232 |
+
echo '<tbody>'."\n";
|
1233 |
+
echo '<tr>'."\n";
|
1234 |
+
|
1235 |
+
echo '<th>'."\n";
|
1236 |
+
echo '<label for="ws-plugin--s2member-login-welcome-page">'."\n";
|
1237 |
+
echo 'Login Welcome Page:'."\n";
|
1238 |
+
echo '</label>'."\n";
|
1239 |
+
echo '</th>'."\n";
|
1240 |
+
|
1241 |
+
echo '</tr>'."\n";
|
1242 |
+
echo '<tr>'."\n";
|
1243 |
+
|
1244 |
+
echo '<td>'."\n";
|
1245 |
+
echo '<select name="ws_plugin__s2member_login_welcome_page" id="ws-plugin--s2member-login-welcome-page">'."\n";
|
1246 |
+
echo '<option value="">— Select —</option>'."\n";
|
1247 |
+
foreach(($ws_plugin__s2member_temp_a = array_merge((array)get_pages())) as $ws_plugin__s2member_temp_o)
|
1248 |
+
echo '<option value="'.esc_attr($ws_plugin__s2member_temp_o->ID).'"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_redirection_override"] && $ws_plugin__s2member_temp_o->ID == $GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_welcome_page"]) ? ' selected="selected"' : '').'>'.esc_html($ws_plugin__s2member_temp_o->post_title).'</option>'."\n";
|
1249 |
+
echo '</select><br />'."\n";
|
1250 |
+
echo 'Please choose a Page to be used as the first page Members will see after logging in. This Page can contain anything you like. We recommend the following title: <code>Welcome To Our Members Area</code>.'."\n";
|
1251 |
+
echo '</td>'."\n";
|
1252 |
+
|
1253 |
+
echo '</tr>'."\n";
|
1254 |
+
echo '<tr>'."\n";
|
1255 |
+
|
1256 |
+
echo '<th>'."\n";
|
1257 |
+
echo '<label for="ws-plugin--s2member-login-redirection-override">'."\n";
|
1258 |
+
echo 'Or, a Special Redirection URL?'."\n";
|
1259 |
+
echo '</label>'."\n";
|
1260 |
+
echo '</th>'."\n";
|
1261 |
+
|
1262 |
+
echo '</tr>'."\n";
|
1263 |
+
echo '<tr>'."\n";
|
1264 |
+
|
1265 |
+
echo '<td>'."\n";
|
1266 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_login_redirection_override" id="ws-plugin--s2member-login-redirection-override" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_redirection_override"]).'" /><br />'."\n";
|
1267 |
+
echo 'Or, you may configure a Special Redirection URL, if you prefer. You\'ll need to type in the full URL, starting with: <code>http://</code>. <em>A few <a href="#" onclick="alert(\'Replacement Codes:\\n\\n%%current_user_login%% = The current User\\\'s Username, lowercase.\\n%%current_user_id%% = The current User\\\'s ID.\\n%%current_user_level%% = The current User\\\'s s2Member Level.\\n%%current_user_role%% = The current User\\\'s WordPress Role.'.((!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site()) ? '\\n%%current_user_ccaps%% = The current User\\\'s Custom Capabilities.' : '').'\\n%%current_user_logins%% = Number of times the current User has logged in.\\n\\nFor example, if you\\\'re using BuddyPress, and you want to redirect Members to their BuddyPress Profile page after logging in, you would setup a Special Redirection URL, like this: '.site_url("/members/%%current_user_login%%/profile/").'\\n\\nOr ... using %%current_user_level%%, you could have a separate Login Welcome Page for each Membership Level that you plan to offer. BuddyPress not required.\'); return false;">Replacement Codes</a> are also supported here.</em>'."\n";
|
1268 |
+
echo '</td>'."\n";
|
1269 |
+
|
1270 |
+
echo '</tr>'."\n";
|
1271 |
+
echo '</tbody>'."\n";
|
1272 |
+
echo '</table>'."\n";
|
1273 |
+
|
1274 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
1275 |
+
|
1276 |
+
echo '<table class="form-table" style="margin-top:0;">'."\n";
|
1277 |
+
echo '<tbody>'."\n";
|
1278 |
+
echo '<tr>'."\n";
|
1279 |
+
|
1280 |
+
echo '<th>'."\n";
|
1281 |
+
echo '<label for="ws-plugin--s2member-login-redirection-always-http">'."\n";
|
1282 |
+
echo 'Always Redirect non-Administrative Users (after login) using HTTP?'."\n";
|
1283 |
+
echo '</label>'."\n";
|
1284 |
+
echo '</th>'."\n";
|
1285 |
+
|
1286 |
+
echo '</tr>'."\n";
|
1287 |
+
echo '<tr>'."\n";
|
1288 |
+
|
1289 |
+
echo '<td>'."\n";
|
1290 |
+
echo '<select name="ws_plugin__s2member_login_redirection_always_http" id="ws-plugin--s2member-login-redirection-always-http">'."\n";
|
1291 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_redirection_always_http"]) ? ' selected="selected"' : '').'>No, do NOT modify (use WordPress default behavior; e.g. detect URL scheme automatically)</option>'."\n";
|
1292 |
+
echo '<option value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["login_redirection_always_http"]) ? ' selected="selected"' : '').'>Yes, always redirect non-administrative users to non-SSL version (e.g. always use http://)</option>'."\n";
|
1293 |
+
echo '</select><br />'."\n";
|
1294 |
+
echo 'Recommended setting: <code>Yes</code>. This is compatible w/ <a href="http://codex.wordpress.org/Administration_Over_SSL" target="_blank" rel="external"><code>FORCE_SSL_LOGIN</code></a> and/or <a href="http://codex.wordpress.org/Administration_Over_SSL" target="_blank" rel="external"><code>FORCE_SSL_ADMIN</code></a>.'."\n";
|
1295 |
+
echo '</td>'."\n";
|
1296 |
+
|
1297 |
+
echo '</tr>'."\n";
|
1298 |
+
echo '</tbody>'."\n";
|
1299 |
+
echo '</table>'."\n";
|
1300 |
+
echo '</div>'."\n";
|
1301 |
+
|
1302 |
+
echo '</div>'."\n";
|
1303 |
+
|
1304 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_login_welcome_page", get_defined_vars());
|
1305 |
+
}
|
1306 |
+
|
1307 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_membership_options_page", TRUE, get_defined_vars()))
|
1308 |
+
{
|
1309 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_membership_options_page", get_defined_vars());
|
1310 |
+
|
1311 |
+
echo '<div class="ws-menu-page-group" title="Membership Options Page">'."\n";
|
1312 |
+
|
1313 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-membership-options-page-section">'."\n";
|
1314 |
+
echo '<h3>Membership Options Page (required, please customize this)</h3>'."\n";
|
1315 |
+
echo '<p>Please create and/or choose an existing Page that showcases your Membership subscription options. This special Page is where you will insert the Payment Button(s) generated for you by s2Member. This Page serves as your lead-in signup page <em>(i.e. you\'ll give visitors one or more registration options here, and they\'ll be redirected to your Payment Gateway, to pay for the option they choose)</em>.</p>'."\n";
|
1316 |
+
echo '<p>Your Membership Options Page should detail all of the features that come with Membership to your site, and provide a Payment Button for each Level of access you plan to offer. This is also the Page that anyone could be redirected to <em>(by s2Member)</em>, should they attempt to access an area of your site, which may require access to something they\'re NOT currenty allowed to view.'.((!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site()) ? ' For more on this advanced topic, please check your Dashboard here: <code>s2Member -› API Scripting -› Membership Options Page / Variables</code>.' : '').'</p>'."\n";
|
1317 |
+
echo '<p><em><strong>*Tip*</strong> If you allow Open Registration (i.e. Free Subscribers), you might want to place a link on your Membership Options Page, which points directly to your free Registration Form, instead of routing a Customer through your Payment Gateway first. It\'s a matter of preference though. For further details, please check the section above: <code>s2Member -› General Options -› Open Registration</code>.</em></p>'."\n";
|
1318 |
+
echo (c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '<p><em><strong>BuddyPress:</strong> Even with BuddyPress, s2Member still needs a Membership Options Page. This is where your Payment Button(s) will go, giving people the ability to pay you. And again, this is also the Page that anyone could be redirected to <em>(by s2Member)</em>, should they attempt to access an area of your site, which may require access to something they are currenty NOT allowed to view.'.((!is_multisite() || !c_ws_plugin__s2member_utils_conds::is_multisite_farm() || is_main_site()) ? ' For more on this advanced topic, please check your Dashboard here: <code>s2Member -› API Scripting -› Membership Options Page / Variables</code>.' : '').'</em></p>'."\n" : '';
|
1319 |
+
echo '<p><em><strong>*Tip*</strong> s2Member will NEVER allow this Page to be protected from public access.</em></p>'."\n";
|
1320 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_membership_options_page", get_defined_vars());
|
1321 |
+
|
1322 |
+
echo '<table class="form-table">'."\n";
|
1323 |
+
echo '<tbody>'."\n";
|
1324 |
+
echo '<tr>'."\n";
|
1325 |
+
|
1326 |
+
echo '<th>'."\n";
|
1327 |
+
echo '<label for="ws-plugin--s2member-membership-options-page">'."\n";
|
1328 |
+
echo 'Membership Options Page:'."\n";
|
1329 |
+
echo '</label>'."\n";
|
1330 |
+
echo '</th>'."\n";
|
1331 |
+
|
1332 |
+
echo '</tr>'."\n";
|
1333 |
+
echo '<tr>'."\n";
|
1334 |
+
|
1335 |
+
echo '<td>'."\n";
|
1336 |
+
echo '<select name="ws_plugin__s2member_membership_options_page" id="ws-plugin--s2member-membership-options-page">'."\n";
|
1337 |
+
echo '<option value="">— Select —</option>'."\n";
|
1338 |
+
foreach(($ws_plugin__s2member_temp_a = array_merge((array)get_pages())) as $ws_plugin__s2member_temp_o)
|
1339 |
+
echo '<option value="'.esc_attr($ws_plugin__s2member_temp_o->ID).'"'.(($ws_plugin__s2member_temp_o->ID == $GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["membership_options_page"]) ? ' selected="selected"' : '').'>'.esc_html($ws_plugin__s2member_temp_o->post_title).'</option>'."\n";
|
1340 |
+
echo '</select><br />'."\n";
|
1341 |
+
echo 'Please choose a Page that provides Users a way to signup for Membership. This Page should also contain your Payment Button(s). We recommend the following title: <code>Membership Signup</code>'."\n";
|
1342 |
+
echo '</td>'."\n";
|
1343 |
+
|
1344 |
+
echo '</tr>'."\n";
|
1345 |
+
echo '</tbody>'."\n";
|
1346 |
+
echo '</table>'."\n";
|
1347 |
+
|
1348 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
1349 |
+
|
1350 |
+
echo '<table class="form-table">'."\n";
|
1351 |
+
echo '<tbody>'."\n";
|
1352 |
+
echo '<tr>'."\n";
|
1353 |
+
|
1354 |
+
echo '<th>'."\n";
|
1355 |
+
echo '<label for="ws-plugin--s2member-membership-options-page-vars-enable">'."\n";
|
1356 |
+
echo 'Enable MOP Vars (i.e. Membership Options Page Variables)?'."\n";
|
1357 |
+
echo '</label>'."\n";
|
1358 |
+
echo '</th>'."\n";
|
1359 |
+
|
1360 |
+
echo '</tr>'."\n";
|
1361 |
+
echo '<tr>'."\n";
|
1362 |
+
|
1363 |
+
echo '<td>'."\n";
|
1364 |
+
echo '<select name="ws_plugin__s2member_membership_options_page_vars_enable" id="ws-plugin--s2member-membership-options-page-vars-enable">'."\n";
|
1365 |
+
echo '<option value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["membership_options_page_vars_enable"]) ? ' selected="selected"' : '').'>Yes (enable MOP Vars in all redirections; recommended behavior)</option>'."\n";
|
1366 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["membership_options_page_vars_enable"]) ? ' selected="selected"' : '').'>No (don\'t include the additional details provided by MOP Vars)</option>'."\n";
|
1367 |
+
echo '</select><br />'."\n";
|
1368 |
+
echo 'See: <code>Dashboard ⥱ s2Member ⥱ API / Scripting ⥱ Membership Options Page / Variables</code><br />'."\n";
|
1369 |
+
echo 'Recommended setting: (<code>Yes, enable MOP Vars</code>)'."\n";
|
1370 |
+
echo '</td>'."\n";
|
1371 |
+
|
1372 |
+
echo '</tr>'."\n";
|
1373 |
+
echo '</tbody>'."\n";
|
1374 |
+
echo '</table>'."\n";
|
1375 |
+
echo '</div>'."\n";
|
1376 |
+
|
1377 |
+
echo '</div>'."\n";
|
1378 |
+
|
1379 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_membership_options_page", get_defined_vars());
|
1380 |
+
}
|
1381 |
+
|
1382 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_profile_modifications", TRUE, get_defined_vars()))
|
1383 |
+
{
|
1384 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_profile_modifications", get_defined_vars());
|
1385 |
+
|
1386 |
+
echo '<div class="ws-menu-page-group" title="Member Profile Modifications">'."\n";
|
1387 |
+
|
1388 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-profile-modifications-section">'."\n";
|
1389 |
+
echo '<h3>Giving Members The Ability To Modify Their Profile</h3>'."\n";
|
1390 |
+
echo '<p>s2Member can be configured to redirect Members away from the <a href="'.esc_attr(admin_url("/profile.php")).'" target="_blank" rel="external">default Profile Editing Panel</a> that is built into WordPress. When/if a Member attempts to access the default Profile Editing Panel, they\'ll instead, be redirected to the Login Welcome Page that you\'ve configured through s2Member. <strong>Why would I redirect?</strong> Unless you\'ve made some drastic modifications to your WordPress installation, the default Profile Editing Panel that ships with WordPress, is NOT really suited for public access, even by a Member.</p>'."\n";
|
1391 |
+
echo '<p>So instead of using this default Profile Editing Panel; s2Member creates an added layer of functionality, on top of WordPress. It does this by providing you <em>(as the site owner)</em>, with a special Shortcode: <code>[s2Member-Profile /]</code> that you can place into your Login Welcome Page, or any Post/Page for that matter <em>(even into a Text Widget)</em>. This Shortcode produces an Inline Profile Editing Form that supports all aspects of s2Member, including Password changes; and any Custom Registration/Profile Fields that you\'ve configured with s2Member.</p>'."\n";
|
1392 |
+
echo '<p>Alternatively, s2Member also gives you the ability to send your Members to a <a href="'.esc_attr(site_url("/?s2member_profile=1")).'" target="_blank" rel="external">special Stand-Alone version</a>. This Stand-Alone version has been designed <em>(with a bare-bones format)</em>, intentionally. This makes it possible for you to <a href="#" onclick="if(!window.open(\''.site_url("/?s2member_profile=1").'\', \'_popup\', \'width=600,height=400,left=100,screenX=100,top=100,screenY=100,location=0,menubar=0,toolbar=0,status=0,scrollbars=1,resizable=1\')) alert(\'Please disable popup blockers and try again!\'); return false;" rel="external">open it up in a popup window</a>, or embed it into your Login Welcome Page using an IFRAME. Code samples are provided below.</p>'."\n";
|
1393 |
+
echo (c_ws_plugin__s2member_utils_conds::bp_is_installed()) ? '<p><em><strong>BuddyPress:</strong> BuddyPress already provides Users/Members with a Profile Editing Panel, powered by your theme. If you\'ve configured Custom Registration/Profile Fields with s2Member, you can also enable s2Member\'s Profile Field integration with BuddyPress (recommended). For further details, see: <code>s2Member -› General Options -› Registration/Profile Fields</code>.</em></p>'."\n" : '';
|
1394 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_profile_modifications", get_defined_vars());
|
1395 |
+
|
1396 |
+
echo '<table class="form-table">'."\n";
|
1397 |
+
echo '<tbody>'."\n";
|
1398 |
+
echo '<tr>'."\n";
|
1399 |
+
|
1400 |
+
echo '<th>'."\n";
|
1401 |
+
echo '<label for="ws-plugin--s2member-force-admin-lockouts">'."\n";
|
1402 |
+
echo 'Redirect Members away from the Default Profile Panel?'."\n";
|
1403 |
+
echo '</label>'."\n";
|
1404 |
+
echo '</th>'."\n";
|
1405 |
+
|
1406 |
+
echo '</tr>'."\n";
|
1407 |
+
echo '<tr>'."\n";
|
1408 |
+
|
1409 |
+
echo '<td>'."\n";
|
1410 |
+
echo '<select name="ws_plugin__s2member_force_admin_lockouts" id="ws-plugin--s2member-force-admin-lockouts">'."\n";
|
1411 |
+
echo '<option value="0"'.((!$GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["force_admin_lockouts"]) ? ' selected="selected"' : '').'>No (I want to use the WordPress default methodologies)</option>'."\n";
|
1412 |
+
echo '<option value="1"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["force_admin_lockouts"]) ? ' selected="selected"' : '').'>Yes (redirect to Login Welcome Page; locking all /wp-admin/ areas)</option>'."\n";
|
1413 |
+
echo '</select><br />'."\n";
|
1414 |
+
echo 'Recommended setting (<code>Yes</code>). <em><strong>*Note*</strong> When this is set to (<code>Yes</code>), s2Member will take an initiative to further safeguard ALL <code>/wp-admin/</code> areas of your installation; not just the Default Profile Panel.</em>'."\n";
|
1415 |
+
echo '</td>'."\n";
|
1416 |
+
|
1417 |
+
echo '</tr>'."\n";
|
1418 |
+
echo '</tbody>'."\n";
|
1419 |
+
echo '</table>'."\n";
|
1420 |
|
1421 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
1422 |
+
|
1423 |
+
echo '<p><strong>Shortcode (copy/paste)</strong>, for an Inline Profile Modification Form:<br />'."\n";
|
1424 |
+
echo '<p><input type="text" autocomplete="off" value="'.format_to_edit('[s2Member-Profile /]').'" class="monospace" onclick="this.select ();" /></p>'."\n";
|
1425 |
|
1426 |
+
echo '<p style="margin-top:20px;"><strong>Stand-Alone (copy/paste)</strong>, for popup window:</p>'."\n";
|
1427 |
+
echo '<p><input type="text" autocomplete="off" value="'.format_to_edit(preg_replace("/\<\?php echo S2MEMBER_CURRENT_USER_PROFILE_MODIFICATION_PAGE_URL; \?\>/", c_ws_plugin__s2member_utils_strings::esc_ds(site_url("/?s2member_profile=1")), file_get_contents(dirname(__FILE__)."/code-samples/current-user-profile-modification-page-url-2-ops.x-php"))).'" class="monospace" onclick="this.select ();" /></p>'."\n";
|
1428 |
+
echo '</div>'."\n";
|
1429 |
|
1430 |
+
echo '</div>'."\n";
|
|
|
1431 |
|
1432 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_profile_modifications", get_defined_vars());
|
1433 |
+
}
|
|
|
1434 |
|
1435 |
+
if(apply_filters("ws_plugin__s2member_during_gen_ops_page_during_left_sections_display_url_shortening", TRUE, get_defined_vars()))
|
1436 |
+
{
|
1437 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_before_url_shortening", get_defined_vars());
|
1438 |
|
1439 |
+
echo '<div class="ws-menu-page-group" title="URL Shortening Service Preference">'."\n";
|
|
|
1440 |
|
1441 |
+
echo '<div class="ws-menu-page-section ws-plugin--s2member-url-shortening-section">'."\n";
|
1442 |
+
echo '<h3>URL Shortening Service API (Preference)</h3>'."\n";
|
1443 |
+
echo '<p>In a few special cases, long URLs generated by s2Member, containing encrypted authentication details, will be shortened; using one of the URL Shortening APIs <em>(listed below)</em>. A shortened URL prevents issues with VERY long links becoming corrupted by a Customer\'s email application. For instance, the Signup Confirmation Email that s2Member sends out to a new paying Customer, may contain a link which is shortened to prevent corruption by email applications. By default, s2Member uses the tinyURL API, which has proven itself to be the most reliable. However, in cases where an API service call fails, s2Member will automatically use one or more of its other APIs as a backup. The option below, allows you to configure which URL Shortening API s2Member should try first <em>(i.e. the one you prefer)</em>.</p>'."\n";
|
1444 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_during_url_shortening", get_defined_vars());
|
1445 |
|
1446 |
+
echo '<table class="form-table">'."\n";
|
1447 |
+
echo '<tbody>'."\n";
|
1448 |
+
echo '<tr>'."\n";
|
1449 |
|
1450 |
+
echo '<th>'."\n";
|
1451 |
+
echo '<label for="ws-plugin--s2member-default-url-shortener">'."\n";
|
1452 |
+
echo 'URL Shortening Service API (Preference):'."\n";
|
1453 |
+
echo '</label>'."\n";
|
1454 |
+
echo '</th>'."\n";
|
1455 |
|
1456 |
+
echo '</tr>'."\n";
|
1457 |
+
echo '<tr>'."\n";
|
|
|
1458 |
|
1459 |
+
echo '<td>'."\n";
|
1460 |
+
echo '<select name="ws_plugin__s2member_default_url_shortener" id="ws-plugin--s2member-default-url-shortener">'."\n";
|
1461 |
+
echo '<option value="tiny_url"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["default_url_shortener"] === "tiny_url") ? ' selected="selected"' : '').'>tinyurl.com (free tinyURL API service)</option>'."\n";
|
1462 |
+
echo '<option value="goo_gl"'.(($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["default_url_shortener"] === "goo_gl") ? ' selected="selected"' : '').'>goo.gl (free Google URL Shortening API service)</option>'."\n";
|
1463 |
+
echo '</select>'."\n";
|
1464 |
+
echo '</td>'."\n";
|
1465 |
|
1466 |
+
echo '</tr>'."\n";
|
1467 |
+
echo '<tr>'."\n";
|
1468 |
|
1469 |
+
echo '<th>'."\n";
|
1470 |
+
echo '<label for="ws-plugin--s2member-default-custom-str-url-shortener">'."\n";
|
1471 |
+
echo 'Custom URL Shortening Service API (Optional/Advanced):'."\n";
|
1472 |
+
echo '</label>'."\n";
|
1473 |
+
echo '</th>'."\n";
|
|
|
1474 |
|
1475 |
+
echo '</tr>'."\n";
|
1476 |
+
echo '<tr>'."\n";
|
1477 |
|
1478 |
+
echo '<td>'."\n";
|
1479 |
+
echo '<input type="text" autocomplete="off" name="ws_plugin__s2member_default_custom_str_url_shortener" id="ws-plugin--s2member-default-custom-str-url-shortener" value="'.format_to_edit($GLOBALS["WS_PLUGIN__"]["s2member"]["o"]["default_custom_str_url_shortener"]).'" /><br />'."\n";
|
1480 |
+
echo 'Your own custom URL <code>(i.e. GET request)</code>, with <code>%%s2_long_url%%</code> Replacement Code. [ <a href="#" onclick="alert(\'s2Member makes it possible for advanced site owners to use a custom URL shortening service they prefer, over the ones currently pre-integrated with s2Member. In order for this to work, your URL shortening service MUST support basic GET requests through its API (sometimes referred to as a REST or NVP API). In addition, your URL shortening service MUST be capable of returning a simple URL in the response that s2Member receives, as a result of s2Member processing the GET request you formulate. See example below.\\n\\nBitly example GET request with format=txt:\nhttp://api.bitly.com/v3/shorten?login=demo&apiKey=2d71bf07&format=txt&longUrl=%%s2_long_url%%\\n(s2Member expects a shortened URL in the response from Bitly)\\n\\n* If you configure s2Member to use your own custom URL shortening service, s2Member will try your configuration first, and if anything fails, it will fall back on its own pre-integrated backups. When configuring your URL for the GET request, s2Member makes two Replacement Codes available:\\n\\n%%s2_long_url%% = The full URL that needs to be shortened (raw URL-encoded).\\n%%s2_long_url_md5%% = An MD5 hash of the full URL (might be useful in some APIs).\\n\\n* If you have any trouble getting your URL shortening service integrated with s2Member in this way, you might take a look at this WordPress Filter ( `ws_plugin__s2member_url_shorten` ), which s2Member makes available for advanced circumstances. Search s2Member\\\'s source code for `ws_plugin__s2member_url_shorten`.\'); return false;" tabindex="-1">click for details</a> ]<br />'."\n";
|
1481 |
+
echo '</td>'."\n";
|
|
|
1482 |
|
1483 |
+
echo '</tr>'."\n";
|
1484 |
+
echo '</tbody>'."\n";
|
1485 |
+
echo '</table>'."\n";
|
1486 |
+
echo '</div>'."\n";
|
1487 |
|
1488 |
+
echo '</div>'."\n";
|
|
|
|
|
|
|
1489 |
|
1490 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_during_left_sections_after_url_shortening", get_defined_vars());
|
1491 |
+
}
|
|
|
|
|
1492 |
|
1493 |
+
do_action("ws_plugin__s2member_during_gen_ops_page_after_left_sections", get_defined_vars());
|
1494 |
|
1495 |
+
echo '<div class="ws-menu-page-hr"></div>'."\n";
|
|
|
1496 |
|
1497 |
+
echo '<p class="submit"><input type="submit" value="Save All Changes" /></p>'."\n";
|
1498 |
|
1499 |
+
echo '</form>'."\n";
|
1500 |
|
1501 |
+
echo '</td>'."\n";
|
1502 |
|
1503 |
+
echo '<td class="ws-menu-page-table-r">'."\n";
|
1504 |
+
c_ws_plugin__s2member_menu_pages_rs::display();
|
1505 |
+
echo '</td>'."\n";
|
1506 |
|
1507 |
+
echo '</tr>'."\n";
|
1508 |
+
echo '</tbody>'."\n";
|
1509 |
+
echo '</table>'."\n";
|
1510 |
|
1511 |
+
echo '</div>'."\n";
|
1512 |
+
}
|
1513 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1514 |
}
|
1515 |
|
1516 |
new c_ws_plugin__s2member_menu_page_gen_ops ();
|
includes/menu-pages/scripting.inc.php
CHANGED
@@ -1075,29 +1075,35 @@ if (!class_exists ("c_ws_plugin__s2member_menu_page_scripting"))
|
|
1075 |
echo '<div class="ws-menu-page-section ws-plugin--s2member-api-mop-vars-section">' . "\n";
|
1076 |
echo '<h3>Membership Options Page Variables (some scripting required)</h3>' . "\n";
|
1077 |
echo '<p>At the core of s2Member, is it\'s ability to protect content <em>(i.e. Posts, Pages, Tags, Categories, URI word fragments, etc)</em>. Whenever a public User, or even an existing Member attempts to access an area of your site that is unavailable to them; either because they are not logged-in, not a paying Member at all; or maybe they are logged-in, but they don\'t have access to content you\'ve protected at a higher Membership Level; s2Member will always redirect these unauthenticated requests to your Membership Options Page.</p>' . "\n";
|
1078 |
-
echo '<p>So your Membership Options Page is a key element of your site. It serves as the focal point of your s2Member installation. Understanding this, you can see it becomes important for s2Member to provide information about what the User/Member was attempting to access <em>(
|
1079 |
do_action ("ws_plugin__s2member_during_scripting_page_during_left_sections_during_api_mop_vars", get_defined_vars ());
|
1080 |
|
1081 |
echo '<div class="ws-menu-page-hr"></div>' . "\n";
|
1082 |
|
1083 |
-
echo '<p><strong>TIP:</strong>
|
1084 |
-
echo '<strong>See Also:</strong> <a href="http://www.s2member.com/codex/stable/s2member/api_constants/package-summary/" target="_blank" rel="external">s2Member Codex -› API Constants</a>, and <a href="http://www.s2member.com/codex/stable/s2member/api_functions/package-summary/" target="_blank" rel="external">s2Member Codex -› API Functions</a>.</p>' . "\n";
|
1085 |
|
1086 |
echo '<div class="ws-menu-page-hr"></div>' . "\n";
|
1087 |
|
1088 |
-
echo '<p>
|
|
|
1089 |
|
1090 |
echo '<div class="ws-menu-page-hr"></div>' . "\n";
|
1091 |
|
1092 |
-
echo '<p><strong>
|
1093 |
-
echo '<p
|
1094 |
|
1095 |
echo '<div class="ws-menu-page-hr"></div>' . "\n";
|
1096 |
|
1097 |
-
echo '<p><strong>Backward compatibility:</strong> The structure of s2Member\'s MOP Vars changed
|
1098 |
echo '<p id="ws-plugin--s2member-old-api-mop-vars-details" style="display:none;">' . c_ws_plugin__s2member_utils_strings::highlight_php (file_get_contents (dirname (__FILE__) . "/code-samples/api-mop-vars-o.x-php")) . '</p>' . "\n";
|
1099 |
echo '</div>' . "\n";
|
1100 |
|
|
|
|
|
|
|
|
|
|
|
|
|
1101 |
echo '</div>' . "\n";
|
1102 |
|
1103 |
do_action ("ws_plugin__s2member_during_scripting_page_during_left_sections_after_api_mop_vars", get_defined_vars ());
|
1075 |
echo '<div class="ws-menu-page-section ws-plugin--s2member-api-mop-vars-section">' . "\n";
|
1076 |
echo '<h3>Membership Options Page Variables (some scripting required)</h3>' . "\n";
|
1077 |
echo '<p>At the core of s2Member, is it\'s ability to protect content <em>(i.e. Posts, Pages, Tags, Categories, URI word fragments, etc)</em>. Whenever a public User, or even an existing Member attempts to access an area of your site that is unavailable to them; either because they are not logged-in, not a paying Member at all; or maybe they are logged-in, but they don\'t have access to content you\'ve protected at a higher Membership Level; s2Member will always redirect these unauthenticated requests to your Membership Options Page.</p>' . "\n";
|
1078 |
+
echo '<p>So your Membership Options Page is a key element of your site. It serves as the focal point of your s2Member installation. Understanding this, you can see it becomes important for s2Member to provide information about what the User/Member was attempting to access <em>(before they were redirected to the Membership Options Page)</em>. This is where s2Member\'s MOP Vars come in <em>(i.e. Membership Options Page Variables)</em>. Whenever s2Member redirects a User/Member to your Membership Options Page, it will include these important MOP Variables in the query string of the URL. These Variables can be used to provide more informative messages; or even to provide a different set of Membership Options <em>(e.g. Payment Buttons)</em>, based on what a User/Member was attempting to access.</p>' . "\n";
|
1079 |
do_action ("ws_plugin__s2member_during_scripting_page_during_left_sections_during_api_mop_vars", get_defined_vars ());
|
1080 |
|
1081 |
echo '<div class="ws-menu-page-hr"></div>' . "\n";
|
1082 |
|
1083 |
+
echo '<p><strong>TIP:</strong> If you\'re running s2Member Pro, there is a NEW simplified way to deal with MOP Vars using the <a href="http://www.s2member.com/kb/s2mop-shortcode/" target="_blank" rel="external"><code>[s2MOP]</code> Shortcode</a>.<br />' . "\n";
|
|
|
1084 |
|
1085 |
echo '<div class="ws-menu-page-hr"></div>' . "\n";
|
1086 |
|
1087 |
+
echo '<p><strong>PHP Code Sample:</strong> This may give you some other ideas [<a href="#" onclick="jQuery(\'p#ws-plugin--s2member-api-mop-vars-code-samples\').toggle(); return false;" class="ws-dotted-link">click here</a>].</p>' . "\n";
|
1088 |
+
echo '<p id="ws-plugin--s2member-api-mop-vars-code-samples" style="display:none;">' . c_ws_plugin__s2member_utils_strings::highlight_php (file_get_contents (dirname (__FILE__) . "/code-samples/api-mop-vars-e.x-php")) . '</p>' . "\n";
|
1089 |
|
1090 |
echo '<div class="ws-menu-page-hr"></div>' . "\n";
|
1091 |
|
1092 |
+
echo '<p><strong>s2Member MOP Vars (Explained) ...</strong></p>' . "\n";
|
1093 |
+
echo '<p>' . c_ws_plugin__s2member_utils_strings::highlight_php (file_get_contents (dirname (__FILE__) . "/code-samples/api-mop-vars.x-php")) . '</p>' . "\n";
|
1094 |
|
1095 |
echo '<div class="ws-menu-page-hr"></div>' . "\n";
|
1096 |
|
1097 |
+
echo '<p><strong>Backward compatibility (the old way):</strong> The structure of s2Member\'s MOP Vars changed again in Apr, 2014. However, s2Member still provides the same MOP Vars that it used in previous versions, for backward compatibility. These <a href="#" onclick="jQuery(\'p#ws-plugin--s2member-old-api-mop-vars-details\').toggle(); return false;" class="ws-dotted-link">old MOP Variables</a> were more difficult to use; they are now deprecated <em>(i.e. they WILL eventually be removed)</em>. Going foward, please go by the new documentation above.</p>' . "\n";
|
1098 |
echo '<p id="ws-plugin--s2member-old-api-mop-vars-details" style="display:none;">' . c_ws_plugin__s2member_utils_strings::highlight_php (file_get_contents (dirname (__FILE__) . "/code-samples/api-mop-vars-o.x-php")) . '</p>' . "\n";
|
1099 |
echo '</div>' . "\n";
|
1100 |
|
1101 |
+
echo '<div class="ws-menu-page-hr"></div>' . "\n";
|
1102 |
+
|
1103 |
+
echo '<p><strong>Backward compatibility (the really old way):</strong> The structure of s2Member\'s MOP Vars changed a bit in Nov, 2011. However, s2Member still provides the same MOP Vars that it used in previous versions, for backward compatibility. These <a href="#" onclick="jQuery(\'p#ws-plugin--s2member-really-old-api-mop-vars-details\').toggle(); return false;" class="ws-dotted-link">old MOP Variables</a> were more difficult to use; they are now deprecated <em>(i.e. they WILL eventually be removed)</em>. Going foward, please go by the new documentation above.</p>' . "\n";
|
1104 |
+
echo '<p id="ws-plugin--s2member-really-old-api-mop-vars-details" style="display:none;">' . c_ws_plugin__s2member_utils_strings::highlight_php (file_get_contents (dirname (__FILE__) . "/code-samples/api-mop-vars-ro.x-php")) . '</p>' . "\n";
|
1105 |
+
echo '</div>' . "\n";
|
1106 |
+
|
1107 |
echo '</div>' . "\n";
|
1108 |
|
1109 |
do_action ("ws_plugin__s2member_during_scripting_page_during_left_sections_after_api_mop_vars", get_defined_vars ());
|
includes/syscon.inc.php
CHANGED
@@ -175,6 +175,7 @@ if(!function_exists("ws_plugin__s2member_configure_options_and_their_defaults"))
|
|
175 |
$default_options["login_redirection_override"] = "";
|
176 |
$default_options["login_redirection_always_http"] = "1";
|
177 |
$default_options["membership_options_page"] = "";
|
|
|
178 |
|
179 |
$default_options["login_reg_design_enabled"] = "1";
|
180 |
|
@@ -450,6 +451,9 @@ if(!function_exists("ws_plugin__s2member_configure_options_and_their_defaults"))
|
|
450 |
else if($key === "membership_options_page" && (!is_string($value) || !is_numeric($value)))
|
451 |
$value = $default_options[$key];
|
452 |
|
|
|
|
|
|
|
453 |
else if($key === "login_reg_design_enabled" && (!is_string($value) || !is_numeric($value)))
|
454 |
$value = $default_options[$key];
|
455 |
|
175 |
$default_options["login_redirection_override"] = "";
|
176 |
$default_options["login_redirection_always_http"] = "1";
|
177 |
$default_options["membership_options_page"] = "";
|
178 |
+
$default_options["membership_options_page_vars_enable"] = "1";
|
179 |
|
180 |
$default_options["login_reg_design_enabled"] = "1";
|
181 |
|
451 |
else if($key === "membership_options_page" && (!is_string($value) || !is_numeric($value)))
|
452 |
$value = $default_options[$key];
|
453 |
|
454 |
+
else if($key === "membership_options_page_vars_enable" && (!is_string($value) || !is_numeric($value)))
|
455 |
+
$value = $default_options[$key];
|
456 |
+
|
457 |
else if($key === "login_reg_design_enabled" && (!is_string($value) || !is_numeric($value)))
|
458 |
$value = $default_options[$key];
|
459 |
|
includes/translations/s2member.pot
CHANGED
@@ -1,10 +1,10 @@
|
|
1 |
-
# Copyright (C) 2014
|
2 |
# This file is distributed under the same license as the package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
-
"Project-Id-Version:
|
6 |
"Report-Msgid-Bugs-To: http://wordpress.org/tag/s2member\n"
|
7 |
-
"POT-Creation-Date: 2014-
|
8 |
"MIME-Version: 1.0\n"
|
9 |
"Content-Type: text/plain; charset=UTF-8\n"
|
10 |
"Content-Transfer-Encoding: 8bit\n"
|
@@ -1419,12 +1419,12 @@ msgctxt "s2member-front"
|
|
1419 |
msgid "Yes, I want to receive updates via email."
|
1420 |
msgstr ""
|
1421 |
|
1422 |
-
#: s2member/includes/syscon.inc.php:
|
1423 |
msgctxt "s2member-front"
|
1424 |
msgid "[%s] Username/Password"
|
1425 |
msgstr ""
|
1426 |
|
1427 |
-
#: s2member/includes/syscon.inc.php:
|
1428 |
msgctxt "s2member-front"
|
1429 |
msgid ""
|
1430 |
"Your Username/Password for:\n"
|
@@ -1435,12 +1435,12 @@ msgid ""
|
|
1435 |
"%%%%wp_login_url%%%%"
|
1436 |
msgstr ""
|
1437 |
|
1438 |
-
#: s2member/includes/syscon.inc.php:
|
1439 |
msgctxt "s2member-front"
|
1440 |
msgid "[%s] New User Registration"
|
1441 |
msgstr ""
|
1442 |
|
1443 |
-
#: s2member/includes/syscon.inc.php:
|
1444 |
msgctxt "s2member-front"
|
1445 |
msgid ""
|
1446 |
"New User Registration on your site:\n"
|
@@ -1452,13 +1452,13 @@ msgid ""
|
|
1452 |
"IP Address: %%%%user_ip%%%%"
|
1453 |
msgstr ""
|
1454 |
|
1455 |
-
#: s2member/includes/syscon.inc.php:
|
1456 |
#: s2member-pro/includes/syscon.inc.php:94
|
1457 |
msgctxt "s2member-front"
|
1458 |
msgid "Congratulations! (your membership has been approved)"
|
1459 |
msgstr ""
|
1460 |
|
1461 |
-
#: s2member/includes/syscon.inc.php:
|
1462 |
msgctxt "s2member-front"
|
1463 |
msgid ""
|
1464 |
"Thanks %%%%first_name%%%%! Your membership has been approved.\n"
|
@@ -1474,12 +1474,12 @@ msgid ""
|
|
1474 |
"%s"
|
1475 |
msgstr ""
|
1476 |
|
1477 |
-
#: s2member/includes/syscon.inc.php:
|
1478 |
msgctxt "s2member-front"
|
1479 |
msgid "Thank you! Your account has been updated."
|
1480 |
msgstr ""
|
1481 |
|
1482 |
-
#: s2member/includes/syscon.inc.php:
|
1483 |
msgctxt "s2member-front"
|
1484 |
msgid ""
|
1485 |
"Thanks %%%%first_name%%%%! Your account now has access to: %%%%item_name%%%%.\n"
|
@@ -1490,13 +1490,13 @@ msgid ""
|
|
1490 |
"%s"
|
1491 |
msgstr ""
|
1492 |
|
1493 |
-
#: s2member/includes/syscon.inc.php:
|
1494 |
#: s2member-pro/includes/syscon.inc.php:98
|
1495 |
msgctxt "s2member-front"
|
1496 |
msgid "Thank You! (instructions for access)"
|
1497 |
msgstr ""
|
1498 |
|
1499 |
-
#: s2member/includes/syscon.inc.php:
|
1500 |
msgctxt "s2member-front"
|
1501 |
msgid ""
|
1502 |
"Thanks %%%%first_name%%%%!\n"
|
@@ -1513,32 +1513,32 @@ msgid ""
|
|
1513 |
"%s"
|
1514 |
msgstr ""
|
1515 |
|
1516 |
-
#: s2member/includes/syscon.inc.php:
|
1517 |
msgctxt "s2member-front"
|
1518 |
msgid "Free Subscriber"
|
1519 |
msgstr ""
|
1520 |
|
1521 |
-
#: s2member/includes/syscon.inc.php:
|
1522 |
msgctxt "s2member-front"
|
1523 |
msgid "Bronze Member"
|
1524 |
msgstr ""
|
1525 |
|
1526 |
-
#: s2member/includes/syscon.inc.php:
|
1527 |
msgctxt "s2member-front"
|
1528 |
msgid "Silver Member"
|
1529 |
msgstr ""
|
1530 |
|
1531 |
-
#: s2member/includes/syscon.inc.php:
|
1532 |
msgctxt "s2member-front"
|
1533 |
msgid "Gold Member"
|
1534 |
msgstr ""
|
1535 |
|
1536 |
-
#: s2member/includes/syscon.inc.php:
|
1537 |
msgctxt "s2member-front"
|
1538 |
msgid "Platinum Member"
|
1539 |
msgstr ""
|
1540 |
|
1541 |
-
#: s2member/includes/syscon.inc.php:
|
1542 |
msgctxt "s2member-front"
|
1543 |
msgid "Level %s Member"
|
1544 |
msgstr ""
|
1 |
+
# Copyright (C) 2014
|
2 |
# This file is distributed under the same license as the package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
+
"Project-Id-Version: 140409\n"
|
6 |
"Report-Msgid-Bugs-To: http://wordpress.org/tag/s2member\n"
|
7 |
+
"POT-Creation-Date: 2014-04-10 02:25:41+00:00\n"
|
8 |
"MIME-Version: 1.0\n"
|
9 |
"Content-Type: text/plain; charset=UTF-8\n"
|
10 |
"Content-Transfer-Encoding: 8bit\n"
|
1419 |
msgid "Yes, I want to receive updates via email."
|
1420 |
msgstr ""
|
1421 |
|
1422 |
+
#: s2member/includes/syscon.inc.php:209
|
1423 |
msgctxt "s2member-front"
|
1424 |
msgid "[%s] Username/Password"
|
1425 |
msgstr ""
|
1426 |
|
1427 |
+
#: s2member/includes/syscon.inc.php:210
|
1428 |
msgctxt "s2member-front"
|
1429 |
msgid ""
|
1430 |
"Your Username/Password for:\n"
|
1435 |
"%%%%wp_login_url%%%%"
|
1436 |
msgstr ""
|
1437 |
|
1438 |
+
#: s2member/includes/syscon.inc.php:213
|
1439 |
msgctxt "s2member-front"
|
1440 |
msgid "[%s] New User Registration"
|
1441 |
msgstr ""
|
1442 |
|
1443 |
+
#: s2member/includes/syscon.inc.php:214
|
1444 |
msgctxt "s2member-front"
|
1445 |
msgid ""
|
1446 |
"New User Registration on your site:\n"
|
1452 |
"IP Address: %%%%user_ip%%%%"
|
1453 |
msgstr ""
|
1454 |
|
1455 |
+
#: s2member/includes/syscon.inc.php:236
|
1456 |
#: s2member-pro/includes/syscon.inc.php:94
|
1457 |
msgctxt "s2member-front"
|
1458 |
msgid "Congratulations! (your membership has been approved)"
|
1459 |
msgstr ""
|
1460 |
|
1461 |
+
#: s2member/includes/syscon.inc.php:237
|
1462 |
msgctxt "s2member-front"
|
1463 |
msgid ""
|
1464 |
"Thanks %%%%first_name%%%%! Your membership has been approved.\n"
|
1474 |
"%s"
|
1475 |
msgstr ""
|
1476 |
|
1477 |
+
#: s2member/includes/syscon.inc.php:240 s2member/includes/syscon.inc.php:244
|
1478 |
msgctxt "s2member-front"
|
1479 |
msgid "Thank you! Your account has been updated."
|
1480 |
msgstr ""
|
1481 |
|
1482 |
+
#: s2member/includes/syscon.inc.php:241 s2member/includes/syscon.inc.php:245
|
1483 |
msgctxt "s2member-front"
|
1484 |
msgid ""
|
1485 |
"Thanks %%%%first_name%%%%! Your account now has access to: %%%%item_name%%%%.\n"
|
1490 |
"%s"
|
1491 |
msgstr ""
|
1492 |
|
1493 |
+
#: s2member/includes/syscon.inc.php:248
|
1494 |
#: s2member-pro/includes/syscon.inc.php:98
|
1495 |
msgctxt "s2member-front"
|
1496 |
msgid "Thank You! (instructions for access)"
|
1497 |
msgstr ""
|
1498 |
|
1499 |
+
#: s2member/includes/syscon.inc.php:249
|
1500 |
msgctxt "s2member-front"
|
1501 |
msgid ""
|
1502 |
"Thanks %%%%first_name%%%%!\n"
|
1513 |
"%s"
|
1514 |
msgstr ""
|
1515 |
|
1516 |
+
#: s2member/includes/syscon.inc.php:283
|
1517 |
msgctxt "s2member-front"
|
1518 |
msgid "Free Subscriber"
|
1519 |
msgstr ""
|
1520 |
|
1521 |
+
#: s2member/includes/syscon.inc.php:283
|
1522 |
msgctxt "s2member-front"
|
1523 |
msgid "Bronze Member"
|
1524 |
msgstr ""
|
1525 |
|
1526 |
+
#: s2member/includes/syscon.inc.php:283
|
1527 |
msgctxt "s2member-front"
|
1528 |
msgid "Silver Member"
|
1529 |
msgstr ""
|
1530 |
|
1531 |
+
#: s2member/includes/syscon.inc.php:283
|
1532 |
msgctxt "s2member-front"
|
1533 |
msgid "Gold Member"
|
1534 |
msgstr ""
|
1535 |
|
1536 |
+
#: s2member/includes/syscon.inc.php:283
|
1537 |
msgctxt "s2member-front"
|
1538 |
msgid "Platinum Member"
|
1539 |
msgstr ""
|
1540 |
|
1541 |
+
#: s2member/includes/syscon.inc.php:283
|
1542 |
msgctxt "s2member-front"
|
1543 |
msgid "Level %s Member"
|
1544 |
msgstr ""
|
readme.txt
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
=== s2Member Framework (Member Roles, Capabilities, Membership, PayPal Members) ===
|
2 |
|
3 |
-
Version:
|
4 |
-
Stable tag:
|
5 |
|
6 |
SSL Compatible: yes
|
7 |
bbPress® Compatible: yes
|
@@ -142,12 +142,22 @@ Released under the terms of the [GNU General Public License](http://www.gnu.org/
|
|
142 |
|
143 |
== Upgrade Notice ==
|
144 |
|
145 |
-
=
|
146 |
|
147 |
(Maintenance Release) Upgrade immediately.
|
148 |
|
149 |
== Changelog ==
|
150 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
151 |
= v140328 =
|
152 |
|
153 |
* (s2Member/s2Member Pro) **Compatibility**. Updated to support WordPress v3.9. Nothing significant, just minor UI tweaks to make s2Member fully compatible with WP v3.9.
|
1 |
=== s2Member Framework (Member Roles, Capabilities, Membership, PayPal Members) ===
|
2 |
|
3 |
+
Version: 140409
|
4 |
+
Stable tag: 140409
|
5 |
|
6 |
SSL Compatible: yes
|
7 |
bbPress® Compatible: yes
|
142 |
|
143 |
== Upgrade Notice ==
|
144 |
|
145 |
+
= v140409 =
|
146 |
|
147 |
(Maintenance Release) Upgrade immediately.
|
148 |
|
149 |
== Changelog ==
|
150 |
|
151 |
+
= v140409 =
|
152 |
+
|
153 |
+
* (s2Member Pro) **s2MOP Shortcode**. A new shortcode is now available for site owners running s2Member Pro: `[s2MOP]`. For further details, please check your Dashboard under: `s2Member ⥱ API / Scripting ⥱ Membership Options Page / Variables`. See also: [this KB article]( http://www.s2member.com/kb/s2mop-shortcode/).
|
154 |
+
* (s2Member/s2Member Pro) **Compatibility**. Reviewed by Lead Developer Jason Caldwell for full compatibility against WordPress v3.9. s2Member also remains backward compatible with WP v3.3 - 3.8.
|
155 |
+
* (s2Member/s2Member Pro) **Security Review**. Reviewed by Lead Developer Jason Caldwell to look closer at any portions of s2Member which might be impacted by the [OpenSSL Heartbleed bug](http://heartbleed.com/). Please note, the Heartbleed bug is NOT an s2Member bug. It is a bug in the OpenSSL library used by many services across the web. Please see this [GitHub issue](https://github.com/WebSharks/s2Member/issues/90) where Jason posted a few tips for site owners running the s2Member software.
|
156 |
+
* (s2Member/s2Member Pro) **s2 MOP Vars**. The format of s2Member's MOP Vars has been updated in this release. Backward compatibility remains for the older formats, so this should not cause any problems for site owners using the older formats provided by previous versions of s2Member. For further details, please check your Dashboard under: `s2Member ⥱ API / Scripting ⥱ Membership Options Page / Variables`.
|
157 |
+
* (s2Member/s2Member Pro) **s2 MOP Vars**. s2Member MOP Vars are now an optional feature. It is now possible to disable the additional variables that s2Member appends to the end of your Membership Options Page URL when it redirects a visitor without access to something you've restricted. To configure this new option, please check your Dashboard under: `s2Member ⥱ General Options ⥱ Membership Options Page`.
|
158 |
+
* (s2Member/s2Member Pro) **Bug Fix**. Updating core IPN handler to correct a PHP warning `array to string conversion`. A symptom was to see warnings in your PHP error log when using a custom Thank-You page. Fixed in this release.
|
159 |
+
* (s2Member/s2Member Pro) **Bug Fix**. Updating the new EOT Time column in the list of WP Users so it displays a human readable date and time; as opposed to a UNIX timestamp. Fixed in this release.
|
160 |
+
|
161 |
= v140328 =
|
162 |
|
163 |
* (s2Member/s2Member Pro) **Compatibility**. Updated to support WordPress v3.9. Nothing significant, just minor UI tweaks to make s2Member fully compatible with WP v3.9.
|
s2member.php
CHANGED
@@ -19,8 +19,8 @@
|
|
19 |
*/
|
20 |
/* -- This section for WordPress parsing. ------------------------------------------------------------------------------
|
21 |
|
22 |
-
Version:
|
23 |
-
Stable tag:
|
24 |
|
25 |
SSL Compatible: yes
|
26 |
bbPress Compatible: yes
|
@@ -75,7 +75,7 @@ if(realpath(__FILE__) === realpath($_SERVER["SCRIPT_FILENAME"]))
|
|
75 |
* @var str
|
76 |
*/
|
77 |
if(!defined("WS_PLUGIN__S2MEMBER_VERSION"))
|
78 |
-
define("WS_PLUGIN__S2MEMBER_VERSION", "
|
79 |
/**
|
80 |
* Minimum PHP version required to run s2Member.
|
81 |
*
|
@@ -105,7 +105,7 @@ if(!defined("WS_PLUGIN__S2MEMBER_MIN_WP_VERSION"))
|
|
105 |
* @var str
|
106 |
*/
|
107 |
if(!defined("WS_PLUGIN__S2MEMBER_MIN_PRO_VERSION"))
|
108 |
-
define("WS_PLUGIN__S2MEMBER_MIN_PRO_VERSION", "
|
109 |
/*
|
110 |
Several compatibility checks.
|
111 |
If all pass, load the s2Member plugin.
|
19 |
*/
|
20 |
/* -- This section for WordPress parsing. ------------------------------------------------------------------------------
|
21 |
|
22 |
+
Version: 140409
|
23 |
+
Stable tag: 140409
|
24 |
|
25 |
SSL Compatible: yes
|
26 |
bbPress Compatible: yes
|
75 |
* @var str
|
76 |
*/
|
77 |
if(!defined("WS_PLUGIN__S2MEMBER_VERSION"))
|
78 |
+
define("WS_PLUGIN__S2MEMBER_VERSION", "140409" /* !#distro-version#! */);
|
79 |
/**
|
80 |
* Minimum PHP version required to run s2Member.
|
81 |
*
|
105 |
* @var str
|
106 |
*/
|
107 |
if(!defined("WS_PLUGIN__S2MEMBER_MIN_PRO_VERSION"))
|
108 |
+
define("WS_PLUGIN__S2MEMBER_MIN_PRO_VERSION", "140409" /* !#distro-version#! */);
|
109 |
/*
|
110 |
Several compatibility checks.
|
111 |
If all pass, load the s2Member plugin.
|