This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
get_header(); | |
if ( wpum_can_access_restricted_content() ) : ?> | |
Some extra content in the template that is restricted as per the restriction settings of the page | |
<?php endif; ?> | |
<div> | |
<?php the_content(); ?> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( 'submit_wpum_form_validate_fields', function ( $check, $fields, $values, $form_name ) { | |
if ( ! isset( $values['register']['user_firstname'] ) || empty( $values['register']['user_firstname'] ) ) { | |
return $check; | |
} | |
if ( ! isset( $values['register']['user_lastname'] ) || empty( $values['register']['user_lastname'] ) ) { | |
return $check; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function my_wpum_rearrange_account_tabs( $tabs ) { | |
// Find the correct slug used in the URL, alter the priority | |
$tabs['email-subscriptions'] ['priority'] = 5; | |
return $tabs; | |
} | |
add_filter( 'wpum_get_account_page_tabs', 'my_wpum_rearrange_account_tabs', 100 ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( 'wpum_field_datepicker_date_format', function (){ | |
return 'd-m-Y'; | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* The Template for displaying the profile cover. | |
*/ | |
// Exit if accessed directly | |
if ( ! defined( 'ABSPATH' ) ) { | |
exit; | |
} | |
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* The Template for displaying the profile cover. | |
*/ | |
// Exit if accessed directly | |
if ( ! defined( 'ABSPATH' ) ) exit; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( 'submit_wpum_form_validate_fields', function ( $check, $fields, $values, $form_name ) { | |
foreach ( $fields as $group_key => $group_fields ) { | |
$field_key = 'wpum_field_33'; // Change this to be your unique field ID with wpum_ prefix | |
if ( ! isset( $values[ $group_key ][ $field_key ] ) ) { | |
return $check; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( 'wpumcr_global_restriction_message', 'my_wpum_global_restriction_message' ); | |
function my_wpum_global_restriction_message( $restricted_global_message ) { | |
return 'This is message show for all restricted content unless the content has a specific restriction message.'; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( 'account_page_form_fields', function ( $fields ) { | |
if ( ! wp_verify_nonce( $_POST['account_update_nonce'], 'verify_account_form' ) ) { | |
return $fields; | |
} | |
/** | |
* Changed this array to the field keys (wpum_ is the prefix) | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( 'wpum_get_registration_fields', function ( $fields ) { | |
if ( isset( $fields['privacy'] ) ) { | |
unset( $fields['privacy'] ); | |
} | |
return $fields; | |
} ); |
NewerOlder