473,320 Members | 1,949 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

submitting a form without action parameter

Hi,
Is there a trick for submitting an HTML form without action parameter
pointing to the target file?

I am trying to reverse engineer an html form inside a jsp page. and
this is what I come across

<form method="POST" name="Userpasshidden" onsubmit='return true'><!--
action="../../login.jsp" -->
.....
<input id="bok" class="buttonAction" type="button" value="OK"
onclick="doLogin()">

--------

this is the doLogin function

function doLogin() {
document.forms.Userpasshidden.user.value =
doEncode(document.forms.Userpass.duser.value);
document.forms.Userpasshidden.pass.value =
doEncode(document.forms.Userpass.dpass.value);
if (document.all) document.all["bok"].disabled = true;
else document.getElementById("bok").disabled = true;
document.forms.Userpasshidden.submit();
}

Aug 4 '05 #1
4 11365

You have to be more specific on what you need. Forms, submit to action=
file, that's what submit is for, if you don't have an action, then,
there's nothing to submit, so, the absence of action= defeats by itself
any submission of any kind, I gather you mean, use form elements for other
processing, not making a server call with parameters.
Danny
--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/
Aug 4 '05 #2
Danny said the following on 8/2/2005 1:09 AM:

You have to be more specific on what you need. Forms, submit to
action= file, that's what submit is for, if you don't have an action,
then, there's nothing to submit, so, the absence of action= defeats by
itself any submission of any kind, I gather you mean, use form elements
for other processing, not making a server call with parameters.


Ok, so, if I have no action then the form won't submit? In WHAT browser?
If no action is present, the form submits to itself. Had you tested that
before you posted, you would know that. But testing is beyond your
abilities evidently.

--
Randy
comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
Aug 4 '05 #3
Tauqir wrote:
Is there a trick for submitting an HTML form without action parameter
pointing to the target file?


Depend on browser error correction? Most submit to the current URL, some
submit to action="./".

Leaving the action attribute off is very bad form (and it is *required* by
the spec).
--
David Dorward <http://blog.dorward.me.uk/> <http://dorward.me.uk/>
Home is where the ~/.bashrc is
Aug 4 '05 #4
Guys, Thanks very much for your help. It was the case that the action=
nothing was posting to itself.

Aug 5 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: Dave Martin | last post by:
I've successfully used CURL to maneuver around and through sites but a new site I've been trying to work with has got me stumped. To retrieve the data I'm trying to get a login is required. If...
1
by: Michael Brennan-White | last post by:
If I submit my for using a get action the resulting page loads . If I use a post action I get an error page saying "The page cannot be found". I am calling the originating page!!! This happens...
5
by: Bjorn | last post by:
Hi, I need to submit in the same page two forms to two different ASP-pages. I created two forms, each with hidden input and a submit button. But it doesn't work. Nothing happens with the second...
2
by: Greg T | last post by:
Hi, I have a rather long form that I don't want people submitting unless they are absolutely sure they are ready. I figured the easiest way to prevent an accidental form submission by way of...
5
by: Don | last post by:
I have a need to submit a form, but don't need the user to click on a button. How do I do this? Is there some way, using JavaScript, to setup a <form> tag to do this? Thanks, Don ----==...
4
by: Rick | last post by:
Hello, I'm having trouble with submitting my form when checking to see if data is present in the user-inputted fields. What I want to happen is for the user to input various pieces of data,...
3
by: veronicab | last post by:
Hi all, I have a page with a very large form. When user clicks on the button to submit the form, page "freezes" for several seconds, and then finally you notice it was not frozen but just...
1
by: philguenet | last post by:
I have left my Web site out at my provider for a long while. Yesterday I tried changing quite a few things on it but it all ended in tears. None of the form submit button submit anymore. I am...
6
by: phpnewbie26 | last post by:
This has been confusing me for a while. I don't understand why it isn't working. In my original coding, I have an action called submitted.php and this is what is looks like: <?php ...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.