• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 203
  • Last Modified:

Controls Without A <FORM> Tag

Hi All,

In HTML/ASP can we have controls say a textbox control without a container I mean without a form tag.
If yes then how can I refer to it  in the page, I mean the control or its value say suppose I need to pass its value in the form of a querystring to another html/asp page.

1 Solution

I you need to contain it in a <form> in order to pass it's value
Yes, it would be all JavaScript.

I don't recommend this, because lot more work than necessary, and non-standard.  But, it could be done without forms.
Yes, I agree with golfDoctor; you could do it, but it would be all javascript and wouldn't work if the user doesn't have javascript on.

I'd suspect you'd trigger off an onClick where you would take the values in the text fields and build a url with the parameters added to it and do a location.href update and the data would be passed to the new page as GET variables.
Cloud Class® Course: SQL Server Core 2016

This course will introduce you to SQL Server Core 2016, as well as teach you about SSMS, data tools, installation, server configuration, using Management Studio, and writing and executing queries.

aye...I stand corrected.

But as the others have said, it is javascript dependant, so if a user has turned off javascript in the browser, or has the security settings set high enough to block scripts from running, or if someone is sneaky and decides to download your page, and simply remove the javascript...it won't be possible to do without the <form> tags...
Why do you want to do this without <form> tags?
bonnseyeAuthor Commented:
sorry jasonbytes, I wanted to accept golfdoctor and yours as assisted, but unfortunately forgot to check and submitted, and realized when all was done. sorry once again

Thanks & Regards,
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now