ERROR! No user data was found.
-
I have tried every option however always get the error “No user data found”. I have checked with the setting but did not find any problem there.
-
I think this may be related to database type. I ma using mysqli but there is no option to select the same. It would be good to have that option. I have one Moodle installation where I used same config to connect with the same external database which worked absolutely fine.
Hey @kumarsmishra,
I’m more than happy to look into this for you. I’m just reading up on this now.
I presume you don’t have an example database that I can demo this with?
Thanks,
Tom
Small update. I’ve modified one file in the plugin to use the mysqli db connection for the “test” button in the settings page.
Before rolling this out, I would like confirmation that this was the issue.
I can either give you some code snippets to replace in the plugin, to help test it on your site, or if you can give me a copy of your database I can test it my end.
Let me know if you are able to do either of these.
Thanks,
Tom
I can paste the code if you let me know the exact place and files.
Post that I can also give you the login credentials of WP where you can check the plugin working.
Thanks,
SantoshDo let me know your personal mail id in case you require crediantials
-
This reply was modified 8 years, 3 months ago by
kumarsmishra.
Hey Santosh,
I’ve just tried to be hacky to test this out live on the site by changing the test code in the wp-admin area. Unfortunately I’m getting the error when I try to save the code:
“Unable to communicate back with site to check for fatal errors, so the PHP change was reverted. You will need to upload your PHP file change by some other means, such as by using SFTP.”
Can I have a copy of your DB and codebase so that I can test locally?
Alternatively, to test if your theory is correct here is the code blocks that need changing so that the query is using mysqli.
In the the plugin root, go to the login directory and open dp.php. There are two blocks that need changing.
— 1) Changing from this:$data = array( "db_instance" => new wpdb( exlog_get_option("external_login_option_db_username"), exlog_get_option("external_login_option_db_password"), exlog_get_option("external_login_option_db_name"), exlog_get_option("external_login_option_db_host") ), "dbstructure_table" => exlog_get_option('exlog_dbstructure_table'), "dbstructure_username" => exlog_get_option('exlog_dbstructure_username'), "dbstructure_password" => exlog_get_option('exlog_dbstructure_password'), "dbstructure_first_name" => exlog_get_option('exlog_dbstructure_first_name'), "dbstructure_last_name" => exlog_get_option('exlog_dbstructure_last_name'), "dbstructure_role" => exlog_get_option('exlog_dbstructure_role'), "dbstructure_email" => exlog_get_option('exlog_dbstructure_email'), );— 1) to this:
$data = array( "db_instance" => new mysqli( exlog_get_option("external_login_option_db_host"), exlog_get_option("external_login_option_db_username"), exlog_get_option("external_login_option_db_password"), exlog_get_option("external_login_option_db_name") ), "dbstructure_table" => exlog_get_option('exlog_dbstructure_table'), "dbstructure_username" => exlog_get_option('exlog_dbstructure_username'), "dbstructure_password" => exlog_get_option('exlog_dbstructure_password'), "dbstructure_first_name" => exlog_get_option('exlog_dbstructure_first_name'), "dbstructure_last_name" => exlog_get_option('exlog_dbstructure_last_name'), "dbstructure_role" => exlog_get_option('exlog_dbstructure_role'), "dbstructure_email" => exlog_get_option('exlog_dbstructure_email'), );— 2) From this:
$users = array(); if (sizeof($rows) > 0) { foreach ($rows as $user_data) { array_push($users, exlog_build_wp_user_data($db_data, $user_data)); }; return $users; }— 2) To this:
$rows = $db_data["db_instance"]->query($query_string); $users = array(); while ($user = $rows->fetch_assoc()) { array_push($users, $user); } return $users;Thanks,
Tom
No @kumarsmishra, do not share login credentials. If @tbenyon then he’d risk getting into real trouble here. I’ve removed the offer and the plugin author’s email. I’ll also review all of the author’s replies. It’s a big deal.
Here’s the stock reply to authors who ask that. Yes, the plugin author did not ask you, you offered. But don’t do that here.
I’ve deleted your offer to login to your user’s site. I’m am 100% sure you mean well but please never ask for credentials on these forums.
https://ww.wp.xz.cn/support/guidelines/#the-bad-stuff
Now for the why: The internet is a wonderful place full of very nice people and a few very bad ones. I’m sure everyone here is very nice however, by giving some ones keys to your house you are trusting they wont steal anything. Likewise the person who takes the keys is now responsible for the house FOREVER.
If something was to go wrong, then you the author may well legally become liable for damages, which they would not normally have been as their software is provided without warranty.
Please be aware that repeatedly asking for credentials will result in us asking you to repeatedly stop before escalating up to the plugins team.
Here’s why.
There are many ways to get information you need and accessing the user’s site is not one of them. That’s going too far.
- Ask for a link to the http://pastebin.com/ log of the user’s web server error log.
- Ask the user to create and post a link to their
phpinfo();output. - Ask the user to install the Health Check plugin and get the data that way.
- Walk the user through enabling WP_DEBUG and how to log that output to a file and how to share that file.
- Walk the user through basic troubleshooting steps such and disabling all other plugins, clear their cache and cookies and try again.
- Ask the user for the step-by-step on how they can reproduce the problem.
You get the idea.
Volunteer support is not easy. But these forums need to a safe place for all users, experienced or new. Accessing their system that way is a short cut that will get you into real trouble in these forums.
-
This reply was modified 8 years, 2 months ago by
Jan Dembowski.
Hey Santosh,
I completely understand what Jan is saying so I’m going to spend some time tomorrow adding in some additional error logging to help me diagnose your problem. Will get back to you in here once I’ve made an updated version of the plugin with the extra error logs and will instruct you on the info I need then.
Thanks for your patience and apologies for not being more aware of the ww.wp.xz.cn rules. I should have thought to read up on this stuff.
Will get back to you soon.
Tom
Hey Santosh,
Just checking to see if you still need support. If you do there are some thing you can do to help me check things out for you.
As always I recommend you take a databse and code backup before continuing with these steps, but to help me help you, can you please do the following.
– Download the Health Check plugin.
– Go to the admin area
– Click on Dashboard (near the top left)
– Click the “Debug Information” tab
– Click “Show copy and paste field in English”
– Copy and paste the details here so I can have a look at your setupOnce that is done it’d be nice to see if the plugin is clashing with other plugins you have installed.
This same plugin has a “Troubleshooting” tab. Try clicking that and work your way through there, activating one plugin at a time till you see the issue.
Lastly, we could look at any browser errors you’re getting. You can open the developer tools in your browser, go to the “Console” tab and refresh your page. I’d be interested to see if you got any error outputted.
Let me know if you need any further help with any of these steps.
Thanks,
Tom
I haven’t heard from you so I’m marking this as resolved. Let me know if you have any more questions as I’m more than happy to help.
-
This reply was modified 8 years, 3 months ago by
The topic ‘ERROR! No user data was found.’ is closed to new replies.