add_filter( ‘wpcode_smart_tags’, function( $tags ) { $tags[‘custom’] = array( ‘label’ => ‘Custom’, ‘tags’ => array( ‘custom_field_tag’ => array( ‘label’ => ‘Custom Field Tag’, ‘function’ => ‘wpcode_custom_field_tag’, ), ), ); return $tags; } ); function wpcode_custom_field_tag() { // Replace custom_field_tag below…Continue reading
function custom_purchase_info_shortcode() { global $wpdb; // Get the current user ID $user_id = get_current_user_id(); // Get the latest MemberPress transaction for this user $latest_transaction = $wpdb->get_row( $wpdb->prepare( “SELECT * FROM {$wpdb->prefix}mepr_transactions WHERE user_id = %d ORDER BY id DESC LIMIT…Continue reading
add_action(‘wp_footer’, function() { ?>Continue reading
function my_custom_css() { echo ‘ ‘; } add_action(‘admin_head’, ‘my_custom_css’);Continue reading
function mepr_set_default_country_script() { ?>Continue reading
function replace_text_in_price_box() { ?>Continue reading
add_action( ‘wp_footer’, function() { ?>Continue reading
function exclude_protected_memberpress_posts( $query ) { // Ensure we are not in the admin area and it’s the main query if ( ! is_admin() && $query->is_main_query() ) { // Check if we are on the repeater field context if ( function_exists(…Continue reading
function mepr_load_mp_styles() { wp_enqueue_style( ‘mepr-moove_gdpr_frontend’, ‘https://your-domain.com/path/to/your/gdpr-stylesheet.css’, array(), ‘4.15.0’ ); } // Add the action to enqueue the GDPR stylesheet on the frontend add_action( ‘wp_enqueue_scripts’, ‘mepr_load_mp_styles’ );Continue reading
function trigger_flowmattic_action_on_landing() { // Check if the user is logged in if ( is_user_logged_in() ) { // Get the current user’s ID $user_id = get_current_user_id(); // Prepare the data to be passed to the workflow $data_to_pass = array( ‘user_id’ =>…Continue reading