Solved

Using Spry Validation Select to submit choices for shopping

Posted on 2008-10-29
2
520 Views
Last Modified: 2015-01-05
I am working on creating a form that allows you to choose options from multiple SPRY generated drop down menus. I need to figure out how to make it so that when the Submit button is hit it initializes the correct string to link to depending on the selections made on the drop down menus.
0
Comment
Question by:nearrealtime
2 Comments
 
LVL 70

Accepted Solution

by:
Jason C. Levine earned 500 total points
ID: 22846668
Hi nearrealtime,

Once Spry generates the menus, you are submitting normal HTML form data.  So all you need to do is combine the variables in whichever server side language you are using.  

For example, if I sumbit a form that has three menus in it to a PHP script via the POST method and the menus are named menu1, menu2, menu3 with selected values of "green", "small", "gift" respectively:

<?php

$var1 = $_POST['menu1'];
$var2 = $_POST['menu2'];
$var3 = $_POST['menu3'];

$thenewvar = $var1." ".$var2." ".$var3;

print $thenewvar;
?>

Would output:

green small gift


0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
Read about how to choose the best possible content marketing agency to suit your needs. Content marketing has become an integral part of running a successful tech business, so it is wise to be informed.
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.

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

12 Experts available now in Live!

Get 1:1 Help Now