Ah! It was so simple 😛
Just using WP built in function
get_current_user_id( )
and all done. Thanks a lot.
Related Posts:
- Change Comment Author Display Name
- Check If comment author is registered
- Comment Author Name In Reply Form
- Display all comments or recent comments per user on author page
- how to make author to write comment on only his own posts?
- How to check if commenter is the_author?
- Let user edit his own comment
- edit comments capability for authors
- Why are authors allowed to approve comments on their posts? How to revoke privilege?
- Hide notifications regarding new comments
- List user comments in author page
- Author can only see own post comment and can moderate
- WordPress comments on users profile
- Comment displaying full name even after setting another display name?
- Same email for all comments
- Notify post author for a new comment on his post?
- How many members have made comments approved for an article?
- Commentlist: bypostauthor problem with children list
- Only Allow post author and “Premium” Role user to comment
- get_comment_author_link not working properly
- How can I hide comment of the authors from their published posts?
- WordPress Custom Local Avatar not showing in comments
- Attaching author tag to the comment
- How to prevent users/authors from seing IP/email of new commentators?
- Author name length character limit?
- Comments counter only for Authors Posts
- Comments pagination on author page
- Change author, disable comments, enable trackbacks for all items in library
- Prevent author from editing comments from others in their post
- URLs to user page is broken
- How to ‘If Author’ Comments Check
- Auto approve all comments (editor)
- How do I comment out a block of tags in XML?
- How to enable comments for pending and draft posts?
- Reverse comment pagination numbers
- get recent comments of a particular category
- Whitelisting Commenters
- WP_Comment_Query() displays “password protected” comments?
- Add a custom class to awating comments
- How to add custom comment fields but *only on the comment reply form*?
- Is it possible to move a comment that should be a reply to another comment?
- Can I seperate comments from post?
- What should I hook to add extra fields to comments?
- Get a variable field of all comments of current post
- Don’t send notification if author comments his own post plugin help?
- Average Score of all ratings in comments
- Making a Comment on a page without being on that page?
- How do I display the commentor’s first name and last name in the comments?
- Warning: call_user_func_array() expects parameter 1 to be a valid callback, func
- How To Disable Comments On New Page
- What is the server IP comment hack
- How to add consent checkbox in comment section
- Do I have to have a nonce for a custom comment field?
- Get last seen date/time in wordpress get_comments() [closed]
- WP 4.4.1 allow empty comments via add_action ‘pre_comment_on_post’
- Change username to nickname in comment section
- Are there any “YouTube-styled” commenting systems for WordPress?
- Add class to comment form div when comment-reply button is clicked
- Add filter to comments loop?
- Pagination Comments Doesn’t Show
- Show comments to unregistered users
- WordPress comments – how to check if comment still needs to be approved?
- PAIN. Comments Pagination
- How to retain comment text on comment form after login/registration?
- Adding character count and limit in comments, modifying labels and fields – jetpack
- Change id=”respond” to the comments container
- Comments on Author page
- Why could my comment_form variable not be working?
- How to block comments and pings?
- Woocommerce comments subscription [closed]
- How to remove the number of a comment in the url slug?
- Use of comment_reply_link_args filter
- Advanced Custom Fields comments [closed]
- How are readers authenticated for leaving comments?
- How to wrap comment_form $fields in one div?
- Two textareas showing up in comments.php
- How can I grab and show the reader comments of my site
- ask and edit an extra comment field
- Modify links in user comments
- How indicate when a functions was upgraded in relationship to the entire program [closed]
- How to filter comments by comment_meta
- Prevent users to delete comments from trash
- How to customize ‘children comments’ in WordPress?
- How to display replies to his comments in user profile of current user
- Top rated posts Average rating issue
- stop url changing when user comments
- Keep comment author’s name on their comment even when their account is deleted
- How to add a class to comment submit button?
- WordPress Commenting System User access and Security
- Comments.php is not getting called on main blog page
- WordPress Comments – Only show part of user name
- Broken comments section – WordPress 2014 Theme
- Need an advice about comments
- same comment list for two posts
- Replace do_action() with a normal submit form in comments.php
- edit-comments.php in Admin – how to change ‘Comments’ title?
- Comments on pages not appearing, even though I enabled them
- Stop future commenting on specific post
- How to disable comments on new blog post, but allow on new products?
- Query comments with non-empty ‘author_url’ value on Admin Comments Screen