The last paragraph contains my clear question, the rest is an explaination of my problem and how my question would fix it
I have a problem. I have a script set up to list for example 3 items in a drop down menu. When the user picks an item other then the first one, it changes a code in my database and then swaps the 1st one before with the new one they pick. This all works fine until they have 2 or 3 items with the same name, if this is the case, no matter what they do, even when they don't change the 1st item, it changes the items in my database because my script states
if($name==$name2){change this.
if($name==$name3){change this.
But since name = name 2 or 3, when they don't change the item, it changes it anyway. This is a problem because each name, althought the same name, carries specific properities with each one, so it changes the item to the same name as the other item but it also swaps its properties. Also, the proerities are carried with each name in the same line, 010501100150 == name05name10name50. I change everything by using substr().
****What I really want to know is if I can determine the line of a drop down menu, this will eliminate my problem by doing
if($dropdownline==2) blabla, because it wont confuse same names.
If anyone knows how to do this, or can think of a different way around my problem,lease let me know. Thanks A lot in advance.