<?php
$currentUser = get_current_user_id(); //get currently logged user ID
$user = get_user_by( 'id', $currentUser ); // Get the user Object by id
$userUrl = get_bloginfo('home').'/author/'.$user->user_login; //Formulate the outout
echo $userUrl; //echo the output
?>
Related Posts:
- Custom WordPress+PHP+MYSQL+AJAX form, submit event not captured by Javascript, but does POST data to the DB
- Submitting a form, using Ajax, to run a SQL Select query based on user input from the form
- Change Query Arguments (filter) with jQuery/Ajax or PHP?
- Testing a Form’s Zipcode Field with Regular Expressions to Determine WordPress Page Behaviour
- Using Ajax to submit a form, and run a SQL Select query based on user input from the form
- Cascading dropdown select search based on Parent Page & Child Page
- WordPress Custom Form – Getting Query Vars, Weird Glitch?
- Javascript / PHP – closing the loop
- Metabox repeating fields – radio buttons not saving correctly
- Gutenberg Blocks doesn’t render correctly when using do_blocks
- How to handle a custom form in wordpress to submit to another page?
- Calling a method from functions.php on a click of a button
- Get post meta in enqueued js file
- How to order posts by modified date without using ‘query_posts’?
- How to use WordPress (PHP) functions in AngularJS partials files?
- How to create a custom config file and get data using inline JS in a wordpress page
- Specific Loop For 2 Within Each
- Archive dropdown styling not applied
- Getting the dropdown menu to redirect to different pages?
- using woocommerce_template_single_add_to_cart in shop-loop – javascript issues [closed]
- Use WordPress’s Media Uploader/ Manager in non WordPress php application
- Get/Set wp.customize.previewer.previewUrl
- How to make custom total price reactive in navigation
- Adding tawk.to code just before body tag on functions.php file
- How can I output a php value into a JS file within WordPress?
- How do I let users upload files to a chosen location?
- How to test nonce with AJAX – Plugin development
- Slider loading issue
- Creating a Multi-Level Associative Object Using AJAX
- Create WP_Query to search for posts by their categories or their parent/child categories
- ACF: how do I get the fields and its values of a specific group?
- search and replace preword from author
- How to complete two other input fields, completed the first
- Modify HTML structure of fields in woocommerce checkout form
- Set WP_query ‘order’ option by another tables value
- Need Help Fixing My Iframes [closed]
- WordPress default Search function inconsistent in WooCommerce Product Titles
- Passing UTM Parameters To Modify Page In WordPress
- Open post-content in archive page in a Modal box with bootstrap
- Creating own shortcode – echoeing php variable based on JS variable
- How to add a do_action on refreshing of WP customizer?
- Two queries for a WP_User_Query search work perfectly apart, but not together
- Media Upload , file name changed automatically
- Generate sidebar depending on height of post
- How to add specific meta tags to head of cart and checkout pages in woocommerce?
- Error – ‘create_function is deprecated’ [closed]
- How to execute html code inside php?
- How to overwrite orderby with add_query_var
- trouble with page_id & highlighting current page
- wordpress admin plugin menu custom css
- Load Posts on Click via Ajax into a DIV
- What is the alternative code to if (isset ($_POST) && !empty ($_POST) to avoid warnings?
- After adding my website to a new server, I keep getting a unexpected end of file error, but the file is identitcal to it’s original source
- Why i can’t get custom fields value or post ID via Ajax?
- Cannot access $wpdb, comes back NULL
- How to reference PHP in Javascript
- get db values for external js file
- Adding Additional Variables on Menus Page
- Querying for specific tags
- Limit tags shown in post
- form $_post action value gets truncated after it passes through two forms
- Ajaxurl suddenly not defined
- What should I write in the post action of this front end post form?
- Contact form – problem with displaying message about sent mail
- html form: redirect page after form completes submit function and posts data
- Creating a brand attribute as a variable
- Build A Custom SQL Query for WordPress Search
- Cannot find the php_ini configuration file to find my error log to see why my code is not working
- Add other class content with reference class value
- Display articles with a different template in the home page | Solved |
- Reading URL Parameters
- Form from within a page
- Category Page Displaying all Pages
- How do I integrate vanilla Javascript to a wordpress website?
- I want to retrieve the email or username data entered for password reset, but failed. how can I do it?
- WordPress Slider is not working
- form submission reverts to index.php template
- Filtering markers on google map by WordPress category[SOLVED]
- Call jQuery function from PHP?
- How to call a function from functions.php with ajax?
- How to do a MySql query in WordPress?
- scroll scrpit to particular button position to next id when click button
- Adding action item to admin users table and sending email
- Unserializeing multiple column values that are stored in one database results variable
- How do I convince this button to do something when it is clicked?
- Why this plugin is not working?
- Trying to fix multiple category drop down
- Display default WordPress login/registration form into a modal window
- How can I add more code to this?
- Does wp_query and query_posts affect website performance? [duplicate]
- Facebook share button only share the_permalink(), without thumbnail, tilte, excerpt, etc
- ajax form function error
- get_option(‘admin_email’) not working in wordpress when using ajax call
- Send foreach $_post method to contact form 7 [closed]
- Use HTML Form Data in PHP Function – WordPress Admin Page
- Disable Typed Parameters for JavaScript in PhpStorm? [closed]
- how to show selected options drop down menu values in attributes field in after saving post.php
- Redirect loop upon installation of my plugin
- Facing Problem While Running WordPress Hook For Archive, Categories, Author, Date Pages Only
- Can’t insert into a database wordpress