Answer the question
In order to leave comments, you need to log in
Why does the browser make a random redirect?
When entering a password in the login form, a redirect occurs using JS to the admin page.
After that, sometimes (not always) an inexplicable thing happens. When you visit some page of the site (not just the admin panel), the browser "redirects" to the same admin page, although there is no redirect code.
Those. for example, going to /123 will redirect to the admin panel /admin/index.php
But if you go to some other page of the site /cat/1, then there is no redirect.
In general, how will it turn out ..
Why is the redirect in quotation marks? Because it's not really a redirect. There are no HTTP headers associated with it. The browser just opens another page: prnt.sc/m6w639
This happens until I do one of the following:
1) Clear the browser cache
2) I turn off JS (but I repeat that there is no js code on the page)
The problem appeared unexpectedly. Appears in Chrome and Mozilla. It appears on different machines. What could be the problem? Browser bug?
Answer the question
In order to leave comments, you need to log in
No, this is not a browser bug. The problem is in your code, but we can't see it, so we can't say anything more precisely.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question