SuuKool / suukool.github.io

SuuKool's Portfolio
0 stars 0 forks source link

405 Not Allowed Error on email/index.php #1

Open SuuKool opened 9 years ago

SuuKool commented 9 years ago

Does github run on a windows web hosting server? Am I not allowed PHP script permission? What....I'm stumped.

SuuKool commented 9 years ago

https://admin-serv.net/blog/669/nginx-fixer-les-erreurs-405-not-allowed-lors-des-posts-sur-fichiers-statiques/ If you get the usual nginx error "405 Not Allowed" when you or another site performs a POST request on static content (file .html, .js, .css, for example) this is quite normal and is due to the normal configuration nginx. FaceBook for example, if you post an advertisement in html via an iframe conduct POSTs, and so, your ads will not be displayed. Example: curl -d "blah = 3" http: // website 405 Not Allowed 405 Not Allowed nginx / 0.8.32 The solution is simple: nano / etc / nginx / sites-enabled / default location / { root / home / users / www /; index index.html index.htm;

Simply add this:

    error_page uri = $ 405;

}

Then restart Nginx:

/etc/init.d/nginx restart

SuuKool commented 9 years ago

AH! 405 Method Not Allowed means that github.io has disallowed the POST protocol, or maybe mail() function which is understandable since Github doesn't want malicious scripts running spam-scripts. They may have disallowed the execution of PHP scripts entirely (which is the most likely reason.) Find a webserver to test this particular code.