The effects of alcohol on sustanon 250 leucine for – real weight loss & bodybuilding benefits?
"You are logged in ...
 
Share:
Notifications
Clear all

Question [Solved] "You are logged in as" always displayed

28 Posts
2 Users
0 Reactions
830 Views
Posts: 15
Topic starter
(@tjbett)
Active Member
Joined: 1 year ago

At the top of the comments section, there is a message that reads ...

"You are logged in as xyzUserName | Log out"

This message is always there along with the username regardless of whether anyone is actually logged in or not. I've cleared all cookies and storage but this messaging doesn't change.

I have both wpDiscuz - Comments and wpDiscuz - Subscription add-ons installed.

Thanks!

 

27 Replies
Asti
Posts: 7571
 Asti
Support
(@asti)
Illustrious Member
Joined: 7 years ago

Please let us know do you have a cache plugin or server-side cache. 

 

Posts: 15
Topic starter
(@tjbett)
Active Member
Joined: 1 year ago

Yes, I do.  Both server and browser-side cache have been cleared but the 'logged in' message persists.

1 Reply
Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7571

@tjbett,

Could you please deactivate the cache plugin and check again? If it works fine, you should exclude the wpDiscuz from the cache plugin settings. 

Posts: 15
Topic starter
(@tjbett)
Active Member
Joined: 1 year ago

Asti,

I have deactivated the cache and manually cleared the files. This didn't solve the problem so I did some debugging within the discuz plugin...

On line 10 of page [.../wpdiscuz/themes/default/comment-form.php] $currentUser ($wpdiscuz->helper->getCurrentUser()) is being loaded.  This is the same user that is used in the wpd-auth block beginning on line 162 and generating the 'Log out' messaging. The getCurrentUser() method is returning the post author, not the active user. I would assume this should be the active user.

Am I misunderstanding something?

Thanks

23 Replies
Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7571

@tjbett,

We don't find such an issue on our test websites. Could you please send the admin login details to info[at]gvectors.com email address? I'll ask the developers to check the issue for you.

(@tjbett)
Joined: 1 year ago

Active Member
Posts: 15

@asti I have reached out to the info[at]gvectors.com team via email. 

 

Also, in addition to the above issue. We are also getting 'fault' and 'Some of field value is invalid' when attempting to post a new comment to an existing post.

Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7571

@tjbett,

Please deactivate the Password Protected plugin, delete all caches and check again. 

Also, in addition to the above issue. We are also getting 'fault' and 'Some of field value is invalid' when attempting to post a new comment to an existing post. 

We don't see the issue while we've checked your website. See the testing comment here: https://csblog-202306.lyjo.com/hello-world-2/#comment-71781

Could you please record a video where we can see the issue? 

(@tjbett)
Joined: 1 year ago

Active Member
Posts: 15

@asti See attached screen capture.  The steps to reproduce were to add text to the comment field and click 'Post Comment'.  I then receive the red 'Som of field value is invalid' notification.

screencapture csblog 202306 lyjo study terms 2023 06 19 07 46 12

 See also that I am not logged in but the comment block still has me logged in as 'Wendell Odom'

Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7571

@tjbett

Let us know the user role of the user that have such an issue. 

(@tjbett)
Joined: 1 year ago

Active Member
Posts: 15

@asti Anyone, it seems.  Without logging in I can generate the 'loggin' issue.  The red notification also appears when I'm not logged in.  Additionally, it can appear with the lyjo account when logged in.  This user is one of the administrators.

The screenshot was captured without anyone being logged in.

Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7571

@tjbett,

Posted by: @asti

Please deactivate the Password Protected plugin, delete all caches and check again. 

Have you checked this step? 

 

(@tjbett)
Joined: 1 year ago

Active Member
Posts: 15

@asti I have done this and the issues still persist.  Have you been able to login to the admin site with the provided information?

(@tjbett)
Joined: 1 year ago

Active Member
Posts: 15

@asti The issues don't appear to be related to the cache or the password protection. Has your team been able to review the issue with the 'You are logged in as {user} | Log out' messaging? This is consistent no matter what is happening with the site. The plugin is always displaying the author, not the logged in user.  As I suggested earlier, according to the plugin code it is grabbing the author not the authenticated user. Interestingly, when I am able to successfully post a comment, the plugin picks up the correct authenticated user while still displaying the incorrect messaging 'You are logged in as Wendell Odom"

This other 'notification' issue doesn't appear to be related to cache or the site's password protection but the behavior is very inconsistent. Many times I don't get an error but other times, I do.

Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7571

@tjbett,

Please confirm us to login again to your website. Also, confirm us to deactivate the plugins if it's necessary. 

This is a plugin conflict for sure. 

(@tjbett)
Joined: 1 year ago

Active Member
Posts: 15

@asti I have reforwarded the login credentials to info[at]gvectors.com. The provided user has admin privileges. Yes, you may deactivate any of the plugins as necessary.  Thank you.

Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7571

Thank you @tjbett,

I've already asked the developers to check the issue. The following three plugins are currently deactivated: 

  • Password Protected
  • WP Subscribe
  • WP Super Cache

Please keep those deactivated. I'll update this topic once the developers finish checking. 

(@tjbett)
Joined: 1 year ago

Active Member
Posts: 15

@asti Thank you!

Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7571

@tjbett,

We've made some changes, but can't see those due to the server-side cache. Please delete it and check again. Let us know if you still see the issue. 

(@tjbett)
Joined: 1 year ago

Active Member
Posts: 15

@asti I have deleted all cache and have done what you have suggested.  Both issues still exist.

  1. The 'You are logged in as [username]' persists at the top of the comments area.  This message appears to be linked to the post's author not the authenticated user.  
  2. When posting a comment I get one of two notification errors - 'Some of field value is invalid', or 'fault'. The first error message appears to be related to whether the user is logged in or not. The second, ('fault') message is hard to pin down.

Thank you

Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7571

ok @tjbett,

We'll continue checking. Can you disable a server-side cache while we're checking the issue? 

(@tjbett)
Joined: 1 year ago

Active Member
Posts: 15

@asti Have you been able to determine anything further regarding our open issues?

Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7571

@tjbett,

Can you disable a server-side cache while we're checking the issue?

Please let us know if you can disable the cache system. 

(@tjbett)
Joined: 1 year ago

Active Member
Posts: 15

@asti The cache system is and continues to be disabled. You also have the ability to enable/disable any installed plugin cache. I'm not aware of any other caching system that could be interfering with your plugin. Please provide further information, if possible.

(@tjbett)
Joined: 1 year ago

Active Member
Posts: 15

Currently, when you visit any post and scroll to the comment section you'll see a number directly above the 'subscribe' section of the comment form. This output value is the 'CurrentUser()->id' value (/wp-content/plugins/wpdiscuz/themes/default/comment-form.php, added line #13). This value always corresponds with the author's id, never does it match the logged-in user. It does change as you navigate through different posts with different authors. This doesn't appear to be related to cache.

Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7571

@tjbett,

The main issue you described in the main post is fixed. The changes will be included in the next version of the wpDiscuz plugin. 

Currently, when you visit any post and scroll to the comment section you'll see a number directly above the 'subscribe' section of the comment form. This output value is the 'CurrentUser()->id' value (/wp-content/plugins/wpdiscuz/themes/default/comment-form.php, added line #13).

We don't follow you well. Please clarify a bit. 

(@tjbett)
Joined: 1 year ago

Active Member
Posts: 15

@asti Yes, I was trying to give you more debugging details on my end.  I added the output on line 13, as described above. This detail will show how the Discuz CurrentUser() method is actually retrieving the post's author, not the authenticated user.

Can explain which of the issues have been fixed?

Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7571

The function for getting the current user is fixed, so you won't have any issues anymore.  

Share: