htaccess redirect throws an error: PHP Catchable fatal error: Object of class WP_Error could not be converted to string

They aren’t really connected. It’s just a redirect after all. The error means that some code in your website wrongly passes a WP_Error object to wp_kses_no_null(). In your position I’d put something like this into this function for debugging: if ( is_wp_error( $string ) ) { var_dump( $string ); debug_print_backtrace(); } This way you can … Read more

main-domain of wordpress keep redirecting to subdomain

According to the Codex instructions: https://codex.wordpress.org/Changing_The_Site_URL If you add these defines to your wp-config.php define( ‘WP_HOME’, ‘http://example.com’ ); define( ‘WP_SITEURL’, ‘http://example.com’ ); These will override the options saved in your wp_options table, you should then remove the /NewSite suffix from your General Settings page. (Or if wp-admin is accessible now you may be able to … Read more

fix 302 redirection error on https

First, you should not customize anything between # BEGIN WordPress and # END WordPress, it’s just not a good practice. You should add your own rules above WP rules. And you should also make use of some flags, like “L”. # BEGIN Custom <IfModule mod_rewrite.c> Options All -Indexes RewriteEngine On RewriteBase / RewriteCond %{HTTPS} !on … Read more