Answer the question
In order to leave comments, you need to log in
Why sometimes trying to localize a bug fixes it?
Sorry for the somewhat philosophical question, but I'm very interested in this pattern. Already 5 times I noticed that sometimes a systematic error occurs on the site, under which there are no grounds, and which disappears when you try to localize it. Let me take the last case as an example.
Sessions are no longer saved on the site when switching between pages, that is, the sessions have ceased to fulfill their function. The error was repeated on different browsers and different computers. I tried for three hours to find out the cause of the error, strained the technical support of the hosting. But in the end this error was fixed by this, after which the sessions began to be saved again:
if (!($_SESSION["test1"])) {
$_SESSION["test1"] = "1";
} else{
echo '<script>console.log("Точка 3 - '.$_SESSION["test1"].'");</script>';
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question