how to capture dynamic drop down list in PHP5, mySql?

I inherited an online store that I need some help with.

The store has a form that emails what products the customer has been looking at - a wish list. On the rendered page, there are product attributes that are pulled from the database. What I need to do is capture whichever attribute has been selected when the submit the form. I know how to do this if it's set, but when it's pulling it from the database I'm lost.

Is there a way to pull that info when I don't know in advance what is going to be showing on the page?

Here are two examples of attributes as rendered on the page:


<div class="wrapperAttribsOptions">
<h4 class="optionName back"><label class="attribsSelect" for="attrib-14">SPK Model</label></h4>

<div class="back">
<select name="id[14]" id="attrib-14">
  <option value="43">SPK-4</option>
  <option value="44">SPK-8</option>
</select>


------------------------------------------------

<div class="wrapperAttribsOptions">
<h4 class="optionName back"><label class="attribsSelect" for="attrib-1">Model</label></h4>
<div class="back">
<select name="id[1]" id="attrib-1">
  <option value="45">VC3-4C</option>
  <option value="1">VC3-4PG</option>
  <option value="3">VC3-4SG</option>
</select>


Best,
MH





LVL 7
MHenryAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
MHenryAuthor Commented:
I just glanced at the links above and will look more later, but I don't think they will work.

The page has already been rendered. I don't need to do any database functions. I just need to collect the information from the field when the submit is done.

Basically, this is just like any other form where I'm gathering the user input. The problem is, the field changes.

I'm thinking I'm going to need to do something like:
$attribute= $_REQUEST['SOMETHING GOES HERE'];  where the Something would be similar to a LIKE in sql. So maybe the something would be -->  find element where IS LIKE "select name="id[*]"

I don't know how to do the something part.
Best,
MH
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
PHP

From novice to tech pro — start learning today.