Wordpress site - too many redirects when selecting link - wordpress

I have looked at similar questions but still receive the redirect error.When landing on a homepage URL the site resolves and displays for example http://www.test.co.uk . When selecting any link ie. http://www.test.co.uk/products the browser throws a "Too many redirects" error and the site become unusable. The only way I can get it back up is by clearing cookies and cache and trying again. What I find really confusing is that copying the http://www.test.co.uk/products link or manually typing the URL in resolves the URL correctly and I don't get "too many redirects" error. It only happens when I select a link.
I have tried the following:
Renamed the "plugins" directory to "plugins1" to disable the plugins
Reverted to the default wordpress ".htaccess" file
Ensure the site settings URLS matched in wp-admin area
SSL is enabled on the site but not configured to be used anywhere, all links (that I'm aware of reference http://)
Checked any redirects on the hosting via CPANEL (none exist)
Added these to the wp-config file
define ('WP_HOME','http://www.test.co.uk');
define('WP_SITEURL','http://www.test.co.uk);
I'm not sure whats changed in the last couple of days but we think a plugin got updated. Would disabling the plugins prove that its nothing to do with plugins?I'm new to WordPress so apologies if I got some terms wrong.
Any suggestions I could try looking at would be helpful.
Thanks

try to set Home url and site url to http://www.test.co.uk from your WP admin panel

Related

Wordpress 404 error on domain.com/wp-admin

My WordPress site having issue so not able to reach out to the domain.com/wp-admin, it's redirect to 404 error. I have been tried out for delete ".htaccess" file however it's not working.Cache and cookies of the browser also have been clear out. Would need some advise how can I reach out to my domain.com/wp-admin.
I have been tried for using domain.com/wp-admin.php. Disable plugin however it's also not working from my end to redirect on my side
Usually, a 404 error on /wp-admin/ is caused due to missing .htaccess in your website's root directory, so first thing first, make sure that you have a valid WordPress .htaccess ( https://wordpress.org/support/article/htaccess/ ).
After that, make sure that you do not have a plugin for a custom admin login as it might also cause this behavior. If the issue still persists after that, try accessing the admin login page at: yourdomain.com/wp-login.php
If none of the above work, you should ask your hosting provider for further help.

Mixed Content: The page at 'https://example.com' was loaded over HTTPS, but requested an insecure stylesheet error in Wordpress site

Instead of genuine Mixed Content issue this seemed like more of a Wordpress issue hence posting here to find a resolution.
I have everything setup to work with https, though there is no valid certificate yet. here is the home page url https://tourpoule.nl. The home page loads but with Mixed content errors which seem to be generated by core Wordpress or theme functions. Attaching image:
Database does not have any url which would start with http://. I already have replaced them using search and replace script.
There is nothing in htaccess file except basic Wordpress setup code. I tried renaming it as well. I cleared all types of cache but still it does not work. The site is using twentytwenty theme and if I comment out css and javascript enque lines, some of the errors disappear but styles and scripts do not load(that is normal I know).
In the view source of page it shows mixed urls, some with https and style and javascript urls without https. see below:
Interestingly if I click a stylesheet url i.e. http://new.tourpoules.nl/wp-content/themes/twentytwenty/style.css?ver=1.0 it redirects to https://new.tourpoules.nl/wp-content/themes/twentytwenty/style.css?ver=1.0
I am not sure what is going on and have got struck. I am not able to reach the client so that we can discuss turning ssl redirection off in nginx for this domain where it is redirecting everything to https if it is not https. Not sure if that is causing issue (I believe it is not as it has nothing to do with Wordpress mechanism to generate urls). Any help or direction is greatly appreciated.
I can see your website is still unsecured, for what it's worth, get yourself letsencrypt ssl.
Back to you question, go to your database, open the wp_options table, change the siteurl item to https://tourpoules.nl and also change the home item to https://tourpoules.nl.
If you have used search and replace DB master script or plugin it will not update inside meta files as well as and check for the function file have you Enqueue with https://
So will be better if you download SQL file and replace with below:
From:
http://new.tourpoules.nl
To
https://new.tourpoules.nl
and re-upload again

Changed name of subdirectory - creating pages doesn't work

I tried to change my WP subdirectory from www.example.com/test to www.example.com/live, and frontpage and login works as it should. But when I try to access former articles or pages, or create new I just get a 404 error.
E.g www.example.com/live/my-first-article gives 404, then redirects to frontpage (www.example.com).
I've defined the site URL and home URL in wp-config, changed the name of the folder, and changed "test" to "live" everywhere in the database.
Anyone have an idea or encountered this problem before?
It is most likely your .htaccess file which isnt updated. You can update it by going to
Settings > Permalinks > Save Changes

getting 404 error on wordpress pages

I've seen some other people with the same issue on net,
but the solution that worked for them (updating the .htacess file), didn't go very well for me!
I used buddypress to migrate my wordpress site to my local pc, but after everything is setup, only the home page is working, other posts or pages are getting 404 errors, I also tried to deactivate plugins and changing the theme, but nothing worked.
I'm on windows 10 and i'm using wampserver 2.5.
I think that the issue is caused by Apache, but I don't know how to fix it!
my Apache version is 2.4.9
Thanks in advance guys :)
Your site’s permalink (WordPress Admin > Settings > Permalink) is set as Default, please change it to any of the other option available below. e.g: Day and name, Post name etc.
Then you’ll be able to access the board instead of the 404 error.
Another way is troubleshooting:
WordPress sites can complicate the 404 troubleshooting process. Why? WordPress is a content management system that processes its own internal rewrite array as a part of its permalinks feature.
The first step to troubleshooting 404s is to figure out whether the 404 is being caused by the web server or by WordPress.
Static file
If your file is static (e.g. a jpg image) open your FTP client and verify that the file exists.
As an example, let’s say that the URL http://example.com/wp-content/uploads/picture.jpg is producing a 404 error. You will want to:
Open FTP Client and connect to your server (if you don’t know how to do so, read this.)
Navigate to the file’s location
Verify that the file exists
If it is does not exist, you have found the source of your 404.
However, it it does exist, yet pulling the URL up in a browser results in a 404 error, continue on to find out whether the issue is web server-based or WordPress-based.
Reference Link: http://websynthesis.com/fixing-wordpress-404-errors/

One page won't show on wordpress after moving from live to localhost

I moved my website from live to localhost to make some modifications to it and I have encountered a problem, one page will not show up: "Oops! That page can’t be found.".
I have tried the following
1. activated rewrite_module
2. deactivated each plugin to see if anyone is causing the problem
3. recopied the database and files in case of failure during the first transfer
4. read that resetting permalinks might solve the problem. Changed permalinks to default - the page now works, but when I changed back to custom the problem is still there.
This is weird because only one page does not seem to show, every other page works fine and also there is no problem on the live version.
I ran out of solutions can any one please help?
This may be caused by the permalink or .htaccess
check the url of your page if no issues on URL then
Follow this steps once:
Go to settings-> permalink-> set it as default ->Reload or refresh
Then again now Go to settings-> permalink->postname
Your .htaccess will get update with the permalink.
This could be a problem with htaccess. When using the query string urls in wordpress, no htaccess is required, but for anything else Wordpress uses mod_rewrite.
Is htaccess turned on your localhost Apache server? In httpd.conf, AllowOverride All should be turned on in your active directory.
Is Wordpress able to create new files? Insufficient permissions might prevent it from creating the htaccess file.
Finally, check that your links are pointing to the right place. Sometimes the problem is as simple as a misspelling in your link ;) Good luck.

Resources