View Full Version : Method not allowed with POST
spectre73
12-06-2006, 08:44 PM
I get "Method not allowed" when i try a POST method in a web form that is made with Coffeecup form builder 5.5
I compiled the PHP 4/5 Universal Module 2.3 with PHP 5.2.0 and everything is installed ok but i did not change anything in the litespeed configuration to handle php scripts or the POST method
Anyone can guide me to make it work ?
Thanks
Are you getting this as an php error or litespeed error?
Most likely your form html is invalid. Please post your html form.
spectre73
12-06-2006, 09:09 PM
A litespeed error....
Well if you can tell me how to enable the POST method in litespeed it would be appreciated....
POST method is enabled. There is no way to disable it.
You need to enable "debug logging", via "Service Manager", test the broken url, and send us the relevant log entries.
I don't think it was a POST method that broke.
Make sure your form html contains "action" attribute pointing to the php file.
From the error log, it looks like your have broken html causing the web browser to submit a POST request to a static file which for security reasons is not allowed in litespeed.
spectre73
12-07-2006, 03:11 AM
Well the coffeecup software is rather odd on making forms....is there an email that i can send you the 4 files so you can check them ?
Thanks
Make sure your form html contains "action" attribute pointing to the php file.
From the error log, it looks like your have broken html causing the web browser to submit a POST request to a static file which for security reasons is not allowed in litespeed.
If you post the relevant, <form>*</form>, entries someone in the forum can check it out and point out your error.
To be honest, this is really not the correct place for html coding help. I would first highly recommend you to go a google check for "html form tag syntax" and pay attention to the "action" attribute.
mistwang
12-07-2006, 08:38 AM
I think your PHP configuration is not right, *.php is treated as static file, so POST is not allowed, check your lsphp external app and script handler configuration, pay attention to the error/warning message when LSWS starts.
spectre73
12-07-2006, 10:17 AM
Can you give me a step by step list that i can check with the most details possible ?
Thanks
I think your PHP configuration is not right, *.php is treated as static file, so POST is not allowed, check your lsphp external app and script handler configuration, pay attention to the error/warning message when LSWS starts.
mistwang
12-07-2006, 10:54 AM
try to access any PHP script, see if it works. If not, reinstall you server with php support enabled during installation. check you PHP script again. Replace lsws/fcgi-bin/lsphp with your own PHP binary, restart server, check PHP script again.
If everything works, try your POST test, if not, check error.log, stderr.log see if there is any clue.
spectre73
12-07-2006, 11:09 AM
How do i enable php support during installation ?
try to access any PHP script, see if it works. If not, reinstall you server with php support enabled during installation. check you PHP script again. Replace lsws/fcgi-bin/lsphp with your own PHP binary, restart server, check PHP script again.
If everything works, try your POST test, if not, check error.log, stderr.log see if there is any clue.
mistwang
12-07-2006, 03:31 PM
run install.sh, you will know.
spectre73
12-07-2006, 05:59 PM
I got it working....i have gone to your online demo and copied the 2 sections concerning php and restarted litespeed and it worked.
run install.sh, you will know.
spectre73
12-07-2006, 06:02 PM
I got it working....i have gone to your online demo and copied the 2 sections concerning php and restarted litespeed and it worked.
By default this configuration should be included in the default install....
mistwang
12-08-2006, 10:34 AM
By default this configuration should be included in the default install....
Yes, they are. You probably did not enable PHP support during the installation.
spectre73
12-09-2006, 12:25 AM
Yes, they are. You probably did not enable PHP support during the installation.
Well i tried reinstalling it and the only option it gave me was to enable php acceleration or not....it did not ask me to put php support....maybe it's because it is the free version....
mistwang
12-09-2006, 12:30 PM
The install script should prompt:
Setup up PHP [Y/n]:
Default is yes. It should be enabled unless you select "n".
Please make sure to select "Reinstall" when you run the install.sh, "Upgrade" will not show that option.
spectre73
06-11-2007, 11:26 PM
Could you please delete this Thread it has been resolved a long time ago.... ?
The install script should prompt:
Setup up PHP [Y/n]:
Default is yes. It should be enabled unless you select "n".
Please make sure to select "Reinstall" when you run the install.sh, "Upgrade" will not show that option.
mistwang
06-12-2007, 10:26 AM
We will leave it as it might be helpful for others who have the similar issue.