Solved

return values from achckbox

Posted on 2015-01-18
2
39 Views
Last Modified: 2015-01-19
I ha ve a form with 5 input checkboxes
<form name="forma" method="post" acrion="cotiza.asp">
<input type="checkbox" name="product" value="prod01">
<input type="checkbox" name="product" value="prod02">
<input type="checkbox" name="product" value="prod03">
<input type="checkbox" name="product" value="prod04">
<input type="checkbox" name="product" value="prod05">

Open in new window


When I send the form how can I determine which elements were checked without making specific reference to the values?

The form is dynamic and has many possible values. So it is impractical (or impossible) to check each value.

I am thinking of a array

Thx
0
Comment
Question by:robrodp
  • 2
2 Comments
 
LVL 76

Accepted Solution

by:
arnold earned 500 total points
ID: 40557131
Each checked checkbox will be sent as check_box_name=value_of_check_box
When you parse/process the response, you have to make sure you process checkbox cummulatively versus ......

in your case, if I checked product Values prod01 prod03 and prod05 the data stream will include the following:
product=prod01&product=prod03&product=prod05
0
 
LVL 76

Expert Comment

by:arnold
ID: 40557148
Advise if I might, the simplest thing is to have your dynamic pages have a DEBUG feature.
in this case, outputing the data stream your ASP gets will help identify an approach to do what you need.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Deprecated and Headed for the Dustbin By now, you have probably heard that some PHP features, while convenient, can also cause PHP security problems.  This article discusses one of those, called register_globals.  It is a thing you do not want.  …
Use these top 10 tips to master the art of email signature design. Create an email signature design that will easily wow recipients, promote your brand and highlight your professionalism.
In this tutorial viewers will learn how add a scalable full-width header using CSS3. Create a new HTML document with an internal stylesheet. Set a tiled background.:  Create a new div and name it Header. Position it with position:absolute at the top…
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now