Something went wrong with that
-
This error message isnt very helpful. Could it be more descriptive please. Also they plugin catches the error and dies the code exection. Instead could you let it go to the logs so we can track it
function somfrp_wp_error( $message, $args = array() ) {
// Log error to WordPress debug log if debug logging is enabled
if ( defined( 'WP_DEBUG_LOG' ) && WP_DEBUG_LOG ) {
$log_message = 'Frontend Reset Password Error: ' . strip_tags( $message );
// Add additional context information
$context = array(
'user_agent' => isset( $_SERVER['HTTP_USER_AGENT'] ) ? $_SERVER['HTTP_USER_AGENT'] : 'Unknown',
'ip_address' => isset( $_SERVER['REMOTE_ADDR'] ) ? $_SERVER['REMOTE_ADDR'] : 'Unknown',
'request_uri' => isset( $_SERVER['REQUEST_URI'] ) ? $_SERVER['REQUEST_URI'] : 'Unknown',
'referer' => isset( $_SERVER['HTTP_REFERER'] ) ? $_SERVER['HTTP_REFERER'] : 'Unknown'
);
$log_message .= ' | Context: ' . wp_json_encode( $context );
error_log( $log_message );
}
$error = new WP_Error( 'somfrp_error', $message );
$site_title = get_bloginfo( 'name' );
wp_die( $error, $site_title . ' - Error', $args );
}Thanks. sorry i added it to the other ticket with the same title with more words but i think the “dont reply to the ticket ” bot zapped it.
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
You must be logged in to reply to this topic.