Code to get the users subscription pack
-
Dear,
Can you tell me how to get the subscription pack name of a logged in user please. I need to customize the profile page following the pack of the customer. So in function of this pack I display the related shortcode. This to avoid to have to buid as many profile pages as subscription packs. I tried following code but it gives an error.if ( is_user_logged_in() ) { $user_id = isset( $_GET['user_id'] ); $userdata = get_userdata( $user_id ); global $userdata, $wp_http_referer; get_currentuserinfo(); if ( !$user_id ) { $current_user = wp_get_current_user(); $user_id = $user_ID = $current_user->ID; } $profileuser = get_user_to_edit( $user_id ); $pack = $wpuf_subscription->get_subscription( $profileuser->wpuf_sub_pack ); $pack = $pack->name; }
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Code to get the users subscription pack’ is closed to new replies.