V
V
Veronika Stepanovna2017-05-18 19:34:56
Laravel
Veronika Stepanovna, 2017-05-18 19:34:56

Why is the POST request not going through, although GET is sent (Laravel)?

I have Laravel installed on shared hosting with ssl. Through https://hurl.it/ I send a GET request - passes. When I send POST - 500 Internal Server Error.
Here is the htaccess at the
root of the site:

Options +FollowSymlinks
IndexIgnore */*
RewriteEngine On
RewriteCond %{REQUEST_URI} ^!/(public)*
RewriteRule (.*)$ public/$1 [L]
RewriteRule (.*) public/$1
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /public/index.php

And the public folder:
<IfModule mod_rewrite.c>
    <IfModule mod_negotiation.c>
        Options -MultiViews
    </IfModule>

    RewriteEngine On

    # Redirect Trailing Slashes If Not A Folder...
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)/$ /$1 [L,R=301]

    # Handle Front Controller...
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^ index.php [L]

    # Handle Authorization Header
    RewriteCond %{HTTP:Authorization} .
    RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
</IfModule>


UPD. Laravel logs are clean. Alas, I can’t see the server logs, the virtual hosting is the same (
UPD2. Everything is fine in the receptions too.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
V
Veronika Stepanovna, 2017-05-19
@sargss

Forgot to disable csrftoken verification)

A
Alexander Aksentiev, 2017-05-18
@Sanasol

Perhaps you should look into the laravel logs?
Enable debug in laravel?
Look in php logs?
Look in the webserver logs?
At least find a mistake, and then ask questions

P
Puma Thailand, 2017-05-19
@opium

Server logs, see them, you can probably see them on any Wirth hosting

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question