Add this to the frontend and you should be able to adjust it to display whatever field you’ve added.
$user_info = get_userdata(get_current_user_id());
echo 'Username: ' . $user_info->user_login . "<br>";
echo 'User roles: ' . implode(', ', $user_info->roles) . "<br>";
echo 'User ID: ' . $user_info->ID . "<br>";
echo 'User Agent Department: ' . $user_info->agentdept . "<br>";
echo 'User Agent Mobile: ' . $user_info->agentmobile . "<br>";
Related Posts:
- How to automatically apply woocommerce product title to all product images alt tags?
- Change the footer text on the login page
- How to remove a metabox from menu editor page?
- WooCommerce: How to display item meta data in email confirmation using woocommerce_order_item_meta_end
- Check if page parent has certain template
- Add custom field to attachments in a specific category
- How can update custom meta for all posts
- Hooking new functions to actions + passing parameters
- Is $hook a global variable in WordPress
- Insert all post IDs in new database table
- Randomise upload filenames (or another solution to hide the original image URL from theft?)
- Handling Body class based on Template
- Passing the custom field values in the wp_get_current_user array function
- Woocommerce: hook action/filter I could use to add variation id and price with each attribute opt on WooCommerce Rest api
- Firing schema via code in functions.php doesn’t work
- Why ajax doesn’t work on certain wordpress hooks?
- Is it possible to intercept all ajax requests and get the parameters and the returns?
- WordPress Gravatar filter is removing my custom attributes
- Error in custom php function doesn’t exist
- Generating an nonce for Content Security Policy and all scripts – How to make it match/persist for each page load?
- Return a numerical function value in Customizer controls
- 3 Slashes appear after Apostrophe in custom fields after updating product-site
- Modify custom field input data before creating a new post
- how to make custom ajax handler?
- Trying to retrieve post meta
- Which PHP page is the Default Posts Page
- Omit custom post type from wp-sitemap.xml based on meta key using wp_sitemaps_posts_query_args
- Run a code only on theme activation only during first activation
- How to check if a PHP string is different than meta field?
- Can’t save php string to a custom field
- Why does this update_post_meta function not delete the custom field itself?
- How to show/hide php table rows based on the content of custom fields
- Theme not calling Jquery properly
- WordPress redirect redirecting too many times or not at all
- Custom meta box values are not getting saved for my custom post type
- Why does the post_type_link hook everything twice?
- Show ACF field with link to ultimate member profile/WordPress user profile below the post (single post layout)
- How to have different site identity logos on each page on Astra Theme [closed]
- How can I hook into the wp_mail function used by BackWPup?
- Get user custom field value on function.php
- WP All Import / Update stock quantity from multiple XML files
- Changing the order of custom fields in the dashboard for Woocommerce variable products [closed]
- Adding function to child theme’s function.php
- How to add data to a custom field at the wp_users table?
- Problem with adding custom CSS class to image in ACF Photo Gallery plugin [closed]
- Add a custom class to the body tag using custom fields
- Must filter functions receive all arguments passed to them?
- Creating customized php files in theme folder
- Hide a div when a custom field is empty
- Dynamically Generate Functions and Hooks
- Conditional On custom field plugin metabox
- How to pass hook variable to function?
- Delete images from media library when user deletes an image from ACF Gallery
- Updating Metadata with Shortcode
- How do I add a function to parent theme
- Display custom field value in woocommerce variable product via jQurey
- Products listing check if meta checkbox is checked
- Trying to update Woocommerce meta values
- Is it possible to update the dataset using update_post_meta
- Contain multiple page templates in one PHP custom template file in WordPress?
- Block error message in foreach loop when looping through ACF field
- Wp_Schedule_Event every few minutes doesn’t work
- Hide a div if the fiels is empty
- Adding custom field to product category and show it to shop/category shop page
- Custom meta box is not displaying value showing tag as empty
- Discount in the specific product title using keyword ( Woocoommerce )
- Hook into all password resets in WordPress and get password before hashing?
- Store custom field’s multiple values in one user meta key
- Get field in readable word
- Getting page / post URL on publish and / or update
- Fatal error when using array_diff() function inside of wp_update_nav_menu hook?
- Why transition_post_type hook is called twice for the same post?
- WordPress HTML Helper
- Display custom meta box in my template file
- ACF Date fileds to Age Convert [closed]
- Appending an ACF custom field to the page title
- Assign new post author IF another user in custom field on post transition
- Create and publish a new post every Monday, listing the post titles and links to the posts published during the previous week
- transition_post_status hook, works – but not if the post is new
- How to pass value to add_filter wpcf7_form_tag from another function?
- Custom Admin Menu Report for Specific User ID
- ACF number less than comparison not working
- Is there a hook that I can use when a fatal error occurs?
- Check php version before theme activation
- How to make an meta_query optional?
- How do I fetch all comments per post via WP REST API?
- When using the_author hook, how can I determine the PHP file that generates each call to `the_author()`?
- Pass php dynamic variable to shortcode
- How to make jquery count down timer function manually editable
- Hierarchical taxonomy list with modificated term links
- Strip from or something better?
- Add “alt” Attribute to GD Star Rating Tags
- how to replace h1 entry title with h2 in category pages only
- post_exists stops working in a scheduled event
- Access to “My Site” is missing from the admin bar
- Styling admin page rows in order of importance (checkboxes)
- Pagenav Not appearing on custom Template
- PHP Puzzle: Unique Styles with PHP loop
- Adding multiple conditional tags in a function?
- How to initialise WP_Query on the basis of a specific meta_value and continue iterating rest?