Open site by Google gives error 500

Asked

Viewed 97 times

0

When I open my site by Google search, it accesses the page and gives the error 500, however, when accessing the URL directly (the same url in another tab), the site opens normal. What is going on?

Website: royalechinelos.com.br

Google Search: Royale slippers

  • If you put http:// in front it creates a link automatically

  • Have you seen the log? More information about this error may be available in the server error log. ; I think it might have something to do with some header in the unexpected request that Google redirect sends

  • 2

    Surely it is something in your framework or script on the back-end side of the site that is running something when it has the header Referer, without code there is no way to deduce anything else. Please provide details.

  • @Jeffersonquesado I don’t have access to the log file at the moment, so I’m switching hosts. But while I can’t make the migration, I’d like to find a solution.

  • @Guilhermenascimento does not use any framework and nowhere in the code do I use the Referer header, only the Location, but not specifically on the home page (index.php) but on another one

  • I believe it should be shitted on the provider this, because it was working normally and I think since yesterday or hj happened this.. and I haven’t touched the code since February..

  • 1

    Error 500 is inside the server, you tried to exchange index.php for an empty script like <?php echo 'olá mundo'; ?>, if the problem still occurs then it is because the problem may be in Apache. Please take the test.

  • @Guilhermenascimento is, I made the test and gives the same error 500. Sure it is shit from the provider..

  • For conscience sake, download the error log of Apache and PHP, if you can only take the last minute and then send it via Pastebin.com

  • @Guilhermenascimento as said before, in this provider I do not have access to log files, so I am making the migration :/

  • 1

    What lodging do you use? It is possible to use PHP to download by Let’s log the PHP itself, even in the hosting that I use which I do not have access was possible to download using PHP, the phpinfo informs the location of the PHP log and you can try to read with file_get_contents

  • @Guilhermenascimento seems that the problem was in the same provider, yesterday I made the migration to the new and the problem disappeared. Thank you all for your attention

  • It may be that yes, or else the problem was a module that was not active in the first provider and in the second is already active, so the first caused the failure precisely because of the need for the module, which could perhaps be activated.

Show 8 more comments

1 answer

2

The difference between a direct request and one via Google is that in the second case the header Referer is added:

inserir a descrição da imagem aqui

Without further information, I would investigate the processing of this entry in the header.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.