Charles E Campbell Jr
2007-Nov-20 22:09 UTC
[CentOS] html/form newbie: trying to upload a little data to a server
Hello! I've been trying for several hours to upload a few bits of data (not a file) from an html form to a server, and none of my variants have worked thus far. I've done some web searching, too. Anyway, here's the form: <form method="POST" action="mmsrequest"> <pre> UserID: <input type="text" NAME="userid"> Date : <input type="text" NAME="date" value="mm/dd/yy"> Time : <input type="text" NAME="time" value="hh:mm:ss"> <input type="submit"> <input type="reset"> </pre> </form> I've tried mmsrequest as a script and as an executable. Full path, etc. In and out of cgi-bin. Variants tried: method="GET" I end up with a copy of the script (well, I told the browser not to bother trying to display the executable), instead of having the script run. method="POST" I either end up with a "Not Found" or "Method Not Allowed". I've always insured that permissions were rwxrwxrwx, just to avoid any permissions problem, expecting to tighten that up after I got the basic thing working. I don't particularly care if the script or executable gets the information from the command line separated by ampersands and whatnot, environment variable (QUERY_STRING, or so I understand), or from standard input. However, I do care that the script/program gets run and does get the information somehow, on the server side. Any suggestions? Thank you, Chip Campbell
Kenneth Porter
2007-Nov-21 01:26 UTC
[CentOS] html/form newbie: trying to upload a little data to a server
--On Tuesday, November 20, 2007 5:09 PM -0500 Charles E Campbell Jr <charles.e.campbell at nasa.gov> wrote:> Anyway, here's the form: > > <form method="POST" action="mmsrequest">That says the script is in the same directory as the form. Is your web server set up to allow scripts to be executed from the content directory? This will be restricted by both httpd.conf (and includes) and by SELinux, if enabled. Which distro? Which version of Apache? What language is the script in? Can you execute the script from the command line? (Many web script systems allow you to debug from the command line with some suitable setup, allowing you to test without an actual web server.)
Travis Fraser
2007-Nov-21 22:58 UTC
[CentOS] html/form newbie: trying to upload a little data to a server
On Tue, 2007-11-20 at 17:09 -0500, Charles E Campbell Jr wrote:> Hello! > > I've been trying for several hours to upload a few bits of data (not a > file) from an html form to a server, and none of my variants have worked > thus far. I've done some web searching, too. > > Anyway, here's the form: > > <form method="POST" action="mmsrequest"> > <pre> > UserID: <input type="text" NAME="userid"> > Date : <input type="text" NAME="date" value="mm/dd/yy"> > Time : <input type="text" NAME="time" value="hh:mm:ss"> > <input type="submit"> <input type="reset">^^^^^ How about changing type to "submit"?> </pre> > </form> > > I've tried mmsrequest as a script and as an executable. Full path, > etc. In and out of cgi-bin. > > Variants tried: > method="GET" > > I end up with a copy of the script (well, I told the browser not to > bother trying to display the executable), instead of having the script run. > > method="POST" > > I either end up with a "Not Found" or "Method Not Allowed". I've > always insured that permissions were rwxrwxrwx, just to avoid any > permissions problem, expecting to tighten that up after I got the basic > thing working. > > I don't particularly care if the script or executable gets the > information from the command line separated by ampersands and whatnot, > environment variable (QUERY_STRING, or so I understand), or from > standard input. However, I do care that the script/program gets run and > does get the information somehow, on the server side. > > Any suggestions? > > Thank you, > Chip Campbell > > _______________________________________________ > CentOS mailing list > CentOS at centos.org > lists.centos.org/mailman/listinfo/centos >-- Travis Fraser <travis at snowpatch.net>