HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Disscussions dissapears after user loged in. only admin can see the articles
if the user moderator logged in, discussions dissapear.
Database Structure Upgrades
The following structure changes are required for your database.
update `GDN_User` `User` set `Permissions` = '' where `Permissions` <> ''; update `GDN_User` `User` set `Permissions` = '{\"0\":\"Garden.Email.View\",\"1\":\"Garden.Settings.Manage\",\"2\":\"Garden.Settings.View\",\"3\":\"Garden.SignIn.Allow\",\"4\":\"Garden.Users.Add\",\"5\":\"Garden.Users.Edit\",\"6\":\"Garden.Users.Delete\",\"7\":\"Garden.Users.Approve\",\"8\":\"Garden.Activity.Delete\",\"9\":\"Garden.Activity.View\",\"10\":\"Garden.Profiles.View\",\"11\":\"Garden.Profiles.Edit\",\"12\":\"Garden.Curation.Manage\",\"13\":\"Garden.Moderation.Manage\",\"14\":\"Garden.PersonalInfo.View\",\"15\":\"Garden.AdvancedNotifications.Allow\",\"16\":\"Garden.Community.Manage\",\"17\":\"Garden.Uploads.Add\",\"18\":\"Conversations.Conversations.Add\",\"19\":\"Vanilla.Discussions.View\",\"20\":\"Vanilla.Discussions.Add\",\"21\":\"Vanilla.Discussions.Edit\",\"22\":\"Vanilla.Discussions.Announce\",\"23\":\"Vanilla.Discussions.Sink\",\"24\":\"Vanilla.Discussions.Close\",\"25\":\"Vanilla.Discussions.Delete\",\"26\":\"Vanilla.Comments.Add\",\"27\":\"Vanilla.Comments.Edit\",\"28\":\"Vanilla.Comments.Delete\",\"29\":\"Plugins.Pockets.Manage\",\"30\":\"Plugins.Attachments.Upload.Allow\",\"31\":\"Yaga.Reactions.View\",\"32\":\"Yaga.Badges.View\",\"33\":\"Yaga.Ranks.View\",\"34\":\"Plugins.Signatures.Edit\",\"35\":\"Reactions.Positive.Add\",\"36\":\"Reactions.Negative.Add\",\"37\":\"Reactions.Flag.Add\",\"Vanilla.Discussions.View\":[\"-1\"],\"Vanilla.Discussions.Add\":[\"-1\"],\"Vanilla.Discussions.Edit\":[\"-1\"],\"Vanilla.Discussions.Announce\":[\"-1\"],\"Vanilla.Discussions.Sink\":[\"-1\"],\"Vanilla.Discussions.Close\":[\"-1\"],\"Vanilla.Discussions.Delete\":[\"-1\"],\"Vanilla.Comments.Add\":[\"-1\"],\"Vanilla.Comments.Edit\":[\"-1\"],\"Vanilla.Comments.Delete\":[\"-1\"]}' where `UserID` = '1'; update `GDN_User` `User` set `Permissions` = '' where `Permissions` <> ''; update `GDN_User` `User` set `Permissions` = '' where `Permissions` <> ''; update `GDN_User` `User` set `Permissions` = '' where `Permissions` <> ''; update `GDN_User` `User` set `Permissions` = '' where `Permissions` <> ''; update `GDN_User` `User` set `Permissions` = '' where `Permissions` <> ''; update `GDN_User` `User` set `Permissions` = '' where `Permissions` <> ''; update `GDN_User` `User` set `Permissions` = '' where `Permissions` <> ''; update `GDN_User` `User` set `Permissions` = '' where `Permissions` <> ''; update `GDN_User` `User` set `Permissions` = '' where `Permissions` <> '';
When runs the /dba/counts
"You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'select count(uc.ConversationID) from GDN_UserConversation uc where uc.Convers...' at line 2"
Version 2021.011
Tagged:
0
Answers
after doing this forum working fine.
but if I change the user roles from the dashboard, again discussions not showing. please help me @R_J
Are your Categories set up correctly?
Sounds like the problem that has been solved here
https://open.vanillaforums.com/discussion/38722/vanilla-2021-009-no-categories-found#latest
No its also not showing
Can you mention the exact solution. There is too many solutions
can you help me @MrCaspan
Okay so the issue we found is that an older version of MySQL has INT values stored in the database but when they are returned they are string values which Vanilla has issues with when doing an absolute comparison.
So first thing to do is this to see if this is the same issue you are having
Changing line 888 in the file
/applications/dashboard/models/class.permissionmodel.php
and addvar_dump($permissions);exit;
to itOriginal
To This
This will then dump the array $permissions to your screen. Copy the text that gets dumped and paste it here in a code block.
It will either contain INT values or STRING values
@MrCaspan Thank you for your reply.
now I added it.
okay once you add that code hit your site and post back here the text that dumps to your screen. Once you have posted that text to here you can remove that code and its just used to dump that permissions array to the screen
Yeah so it looks like you are having the same issue as others were having. So your hosting do you have access to cPanel or how does your hosting work?
@MrCaspan yes it's cpanel hosting. I have access to the cpanel.
Okay so you will need to do the following. Go into cPanel and go to "Select PHP Version"
After you are done that refresh your site and see if it works now
It looks like you have the right ones enabled. Were these already enabled?
yes.
I did it yesterday after reading other discussion.
okay so the right ones are enabled that's great. We are going to do a phpinfo(); to see what PHP is actually running. Can you go back to that line 888 and put phpinfo();exit; instead of that other line that you added before. then search for mySQL and take a screen show of the MySQL
@MrCaspan