473,654 Members | 3,308 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

can submit text links pass form fields?

M
i am using submit buttons to send the user to different parts of a wizard.
i am using if (if attribute.step1 exists) statements to send them to the
appropriate section based on which submit button they pressed.

well i would like to change these submit buttons into text links instead.
however they do not pass form parameters like the submit button. any simple
ways to accomplish this?

this is what i have so far:

<form name="movwizfor m">

<script language="javas cript" type="text/javascript">
<!--
function getmovWiz ( selectedtype )
{
document.movwiz form.supporttyp e.value = selectedtype ;
document.movwiz form.submit() ;
}
-->
</script>

<a href="javascrip t:getmovWiz('st ep1')">step 1 - details</a>
<a href="javascrip t:getmovWiz('st ep2')">step 2 - cast</a>

</form>
THANKS!!
Jul 23 '05 #1
3 1916
In article <bd************ ********@comcas t.com>, "M" <m@m.com> wrote:
i am using submit buttons to send the user to different parts of a wizard.
i am using if (if attribute.step1 exists) statements to send them to the
appropriate section based on which submit button they pressed.


What's wrong with buttons? They work.

Folks uses other pages than yours. They know that to complete a form
that they need to press a buttons. To use a link, would confuse them.
Use the submit() function to submit the form.

document.movwiz form.submit()
Jul 23 '05 #2
M
actually i answered my own question in the post. i just wasnt thinking
clearly, a hidden form field with the name 'supporttype' passes the data i
need.

i dont want buttons, becuase using tabs instead is more user friendly and it
looks a WHOLE lot better. a submit button will be used when the data is
actually submited for entry. thanks for your input though.

"Robert" <rc*******@my-deja.com> wrote in message
news:rc******** *************** ******@individu al.net...
In article <bd************ ********@comcas t.com>, "M" <m@m.com> wrote:
i am using submit buttons to send the user to different parts of a
wizard.
i am using if (if attribute.step1 exists) statements to send them to the
appropriate section based on which submit button they pressed.


What's wrong with buttons? They work.

Folks uses other pages than yours. They know that to complete a form
that they need to press a buttons. To use a link, would confuse them.
Use the submit() function to submit the form.

document.movwiz form.submit()

Jul 23 '05 #3
M wrote:
i am using submit buttons to send the user to different parts of a wizard.
i am using if (if attribute.step1 exists) statements to send them to the
appropriate section based on which submit button they pressed.
Why use a form? Why not use anchors and plain URLs? No
javascript needed (or even a form).

[...] <form name="movwizfor m">
An action is required, even if it's action="" - though I think
your use of a form is completely unnecessary.

<script language="javas cript" type="text/javascript">
The language attribute is depreciated and replaced by type.
<!--
No need to hide scripts.
function getmovWiz ( selectedtype )
{
document.movwiz form.supporttyp e.value = selectedtype ;
document.movwiz form.submit() ;
}
-->
</script>

<a href="javascrip t:getmovWiz('st ep1')">step 1 - details</a>


No need for "javascript:... ". This "link" will be totally
inoperative for anyone with JavaScript disabled. Consider:

<a href="help.html #step1_details" onclick="
getmovWiz('step 1'); return false;">step 1 - details</a>

At least then someone without JavaScript will still be sent
somewhere useful - return false will cancel the navigation if JS
is enabled.

[...]

You could also consider using frames, with your links in a left
pane and document contents in the main part of the window.
--
Rob
Jul 23 '05 #4

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

Similar topics

4
4291
by: Eric | last post by:
Hey Everyone.. I have a form that has approximately 7 text fields and 1 checkbox. Generally when this form is submitted(to itself BTW) it works fine, however, when the checkbox is only field that has been modified/clicked the form doesn't always submit. When it does work, a Stored procedure is passed form variables and updates to the db are made. When it doesn't, its as if the form wasn't submitted, it reloads and resets the page, but...
10
17171
by: bnmm | last post by:
Hello, I'd like to style a submit button as regular text link. demo: www.byteshift.de/msg/div/input-as-link-by-css (XHTML strict) I applied "display:inline; margin:0; padding:0;" to both the form and the input and "background:none; border:none;" to the input only, which should do the trick, but it doesn't.
5
7699
by: sams | last post by:
I've seen this covered before, but I just don't understand Java very well. I apologize if this is a repeat. Basically, I need a text/java style submit form with multiple hidden fields. It would take the place of the following standard submit button: <form action="ProductQuery.cfm" name="LineCode" method="post"> <input type="hidden" name="Year" value="#GetProducts.Year#"> <input type="hidden" name="Make" value="#GetProducts.Make#">
4
9899
by: karenmiddleol | last post by:
I have the following form the user enters the From and to period and presses the Submit button and the form fields are cleared once the submit button is pressed. Is there a way I can keep the Form fields visible and not cleared. Also when I display the message I want the original form cleared in a different version of this page how can I clear the form completely when I display the data entered from the Response statements I do not...
5
5894
by: Codeman II | last post by:
Hi there, I am building a form where the user must upload a picture and fill in his details. Now I have a problem as all of this is on the same form. How will I be able to have the Browse button to open the "file browse" dialog and the Submit button to submit the form data.
5
20010
by: Alex Maghen | last post by:
In ASPX 2.0 with MasterPages and all that, my entire page only has one actual <FORM>. But there are several different sections of the page that provide what are functionally separate forms with separate Submit buttons. In basic HTML, I can have multiple forms on a page and the browser knows that if any of the fields for Form A have the focus, then pressing ENTER will send a Click to the submit button for Form A. Same for Form B, etc. ...
26
2901
by: Mica Cooper | last post by:
Hi, I need to pass some info in a javascript submit. <a href="javascript:document.formName.submit();">Submit Form</a> Normally a link would do page.jsp?x1=1&x2=2&x3=3 and you would pull x1, x2, x3. I have no clue how to do this with a link submit. Thanks,
1
10800
by: gbezas | last post by:
Hi All, I have added an event handler to redirect form.submit() to a newSubmit() method that I have defined (which does some additional processing before submitting the form). Additionally I have defined the relavant function method in the code for details) The issue is that when Icall targetForm._submit() method from the newSubmit() function the page I get an 'Object doesn't support this property or method' error I am using IE...
11
5289
by: V S Rawat | last post by:
using Javascript, I am opening a web-based url in a popup window. MyWin1=Window.Open(url, "mywindow") There is a form (form1) in the url in that popup window, I need to submit that form. How do I submit that form1 from the javascript from my current window? Thanks.
0
8294
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8709
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8494
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
6162
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5627
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4150
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4297
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2719
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1597
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.