Plugin is not working with Kinsta hosting
-
Hey,
I installed the plugin on Kinsta hosting and I get error page when trying to reach to the adminer page
-
Hello. I have use it in kinsta hosting at the past without problem whar error do you get? Can you provide a screenshot?
Are you trying to open it via clicking the WP Adminer link in the topbar?
Thank you for your reply, yes, click on the top bar “WP Adminer”. I’m trying to upload screenshot but its keep loading.
My site is secure with http auth, maybe its related to this?
This page isn’t working
mysitename.kinsta.cloud is currently unable to handle this request.
HTTP ERROR 500
Is there any php related error log?
You ccould use also Plugin Debug Log Manager to enable and view php error logs
[14-Jan-2025 07:59:37 UTC] PHP Fatal error: Uncaught Error: Undefined constant "SECURE_AUTH_COOKIE" in /www/payoneerchina_288/public/wp-includes/pluggable.php:929
Stack trace:
#0 /www/payoneerchina_288/public/wp-includes/pluggable.php(694): wp_parse_auth_cookie(false, '')
#1 /www/payoneerchina_288/public/wp-includes/class-wp-hook.php(324): wp_validate_auth_cookie(false)
#2 /www/payoneerchina_288/public/wp-includes/plugin.php(205): WP_Hook->apply_filters(false, Array)
#3 /www/payoneerchina_288/public/wp-includes/user.php(3688): apply_filters('determine_curre...', false)
#4 /www/payoneerchina_288/public/wp-includes/pluggable.php(70): _wp_get_current_user()
#5 /www/payoneerchina_288/public/wp-includes/capabilities.php(911): wp_get_current_user()
#6 /www/payoneerchina_288/public/wp-content/plugins/pexlechris-adminer/pluggable-functions.php(59): current_user_can('manage_options')
#7 /www/payoneerchina_288/public/wp-content/mu-plugins/pexlechris_adminer_avoid_conflicts_with_other_plugins.php(27): have_current_user_access_to_pexlechris_adminer()
#8 /www/payoneerchina_288/public/wp-includes/class-wp-hook.php(326): {closure}(Array)
#9 /www/payoneerchina_288/public/wp-includes/plugin.php(205): WP_Hook->apply_filters(Array, Array)
#10 /www/payoneerchina_288/public/wp-includes/option.php(247): apply_filters('option_active_p...', Array, 'active_plugins')
#11 /www/payoneerchina_288/public/wp-content/mu-plugins/wpacu-plugins-filter.php(24): get_option('active_plugins', Array)
#12 /www/payoneerchina_288/public/wp-settings.php(451): include_once('/www/payoneerch...')
#13 /www/payoneerchina_288/public/wp-config.php(113): require_once('/www/payoneerch...')
#14 /www/payoneerchina_288/public/wp-load.php(50): require_once('/www/payoneerch...')
#15 /www/payoneerchina_288/public/wp-blog-header.php(13): require_once('/www/payoneerch...')
#16 /www/payoneerchina_288/public/index.php(17): require('/www/payoneerch...')
#17 {main}
thrown in /www/payoneerchina_288/public/wp-includes/pluggable.php on line 929I think I have found a solution that will work for you! If yes I will release a new version of plugin to update it!
I will post it below:
I think that in order to fix the problem, you need to follow above steps:
- Edit file
wp-content/plugins/pexlechris-adminer/pluggable-functions.php - In function
have_current_user_access_to_pexlechris_adminerdefinition before line 58 (that I require pluggable.php) add these lines:
if ( ! defined( 'COOKIEHASH' ) ) {
$siteurl = get_site_option( 'siteurl' );
if ( $siteurl ) {
define( 'COOKIEHASH', md5( $siteurl ) );
} else {
define( 'COOKIEHASH', '' );
}
}
if ( ! defined( 'SECURE_AUTH_COOKIE' ) ) {
define( 'SECURE_AUTH_COOKIE', 'wordpress_sec_' . COOKIEHASH );
}If this does not work, could you please send an email to info[at]pexlechris[dot]dev with your FTP credentials so I can further investigate?
I am waiting for your answer.
Thanks!
like this? if yes, so its still not working.
if( !function_exists('have_current_user_access_to_pexlechris_adminer') ){
function have_current_user_access_to_pexlechris_adminer()
{
foreach (pexlechris_adminer_access_capabilities() as $capability) {
if ( ! defined( 'COOKIEHASH' ) ) {
$siteurl = get_site_option( 'siteurl' );
if ( $siteurl ) {
define( 'COOKIEHASH', md5( $siteurl ) );
} else {
define( 'COOKIEHASH', '' );
}
}
if ( ! defined( 'SECURE_AUTH_COOKIE' ) ) {
define( 'SECURE_AUTH_COOKIE', 'wordpress_sec_' . COOKIEHASH );
}
require_once ABSPATH . WPINC . '/pluggable.php';
if( current_user_can($capability) ) return true;
}
return false;
}
}Unfortunately I cant share access to FTP
Yes, like this! Do you get the same error?
As next step can you please deactivate all your plugins except WP Adminer, also must use plugins and revert to default theme in order to find out if a plugin or theme causes the problem?
Also what WP version do you use and what PHP ?
So there is not chance to kinsta-create a dev enveroment to give me only for this the FTP in order to investigate further?
I deactivate my theme and activated the twentytwentyfive
I tried to deactivate all plugins except WP Adminer
WP Versiosn – 6.7.1
I can check about the dev env. btw, plugin version 2.2.2 does works for me
No result tho?
In order to disable for ever the must-use plugin creation you an delete the file
wp-content/mu-plugins/pexlechris_adminer_avoid_conflicts_with_other_plugins.phpand set optionpexlechris_adminer_mu_plugin_versionto 0The plugin works without the mu-plugin, the mu-plugin is to avoid possible conflicts with other plugins!
But I would like to help me in order to solve the problem permanently, maybe in a dev env? Because in my end and in other websites this mu-plugin works well!
So, have you created the DEV environment in order to replicate the issue there? In order to fix it globally, for all users of WP Adminer?
Thanks in advanced.
This issue has been fixed in version
3.1.2Thanks!
- Edit file
The topic ‘Plugin is not working with Kinsta hosting’ is closed to new replies.